mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-07-20 20:54:35 +01:00
Adds configuration to idle emotes
This commit is contained in:
committed by
Darlantan
parent
5c285eda7d
commit
85d99208f2
@@ -18,7 +18,6 @@
|
||||
var/vore_verb = "ingest" // Verb for eating with this in messages
|
||||
var/human_prey_swallow_time = 100 // Time in deciseconds to swallow /mob/living/carbon/human
|
||||
var/nonhuman_prey_swallow_time = 30 // Time in deciseconds to swallow anything else
|
||||
var/emote_time = 60 SECONDS // How long between stomach emotes at prey
|
||||
var/nutrition_percent = 100 // Nutritional percentage per tick in digestion mode
|
||||
var/digest_brute = 0.5 // Brute damage per tick in digestion mode
|
||||
var/digest_burn = 0.5 // Burn damage per tick in digestion mode
|
||||
@@ -41,6 +40,10 @@
|
||||
var/obj/item/weapon/storage/vore_egg/ownegg // Is this belly creating an egg?
|
||||
var/egg_type = "Egg" // Default egg type and path.
|
||||
var/egg_path = /obj/item/weapon/storage/vore_egg
|
||||
var/list/emote_lists = list() // Idle emotes that happen on their own, depending on the bellymode. Contains lists of strings indexed by bellymode
|
||||
var/emote_time = 60 // How long between stomach emotes at prey (in seconds)
|
||||
var/emote_active = TRUE // Are we even giving emotes out at all or not?
|
||||
var/next_emote = 0 // When we're supposed to print our next emote, as a world.time
|
||||
|
||||
//I don't think we've ever altered these lists. making them static until someone actually overrides them somewhere.
|
||||
//Actual full digest modes
|
||||
@@ -56,7 +59,6 @@
|
||||
var/tmp/mob/living/owner // The mob whose belly this is.
|
||||
var/tmp/digest_mode = DM_HOLD // Current mode the belly is set to from digest_modes (+transform_modes if human)
|
||||
var/tmp/list/items_preserved = list() // Stuff that wont digest so we shouldn't process it again.
|
||||
var/tmp/next_emote = 0 // When we're supposed to print our next emote, as a world.time
|
||||
var/tmp/recent_sound = FALSE // Prevent audio spam
|
||||
|
||||
// Don't forget to watch your commas at the end of each line if you change these.
|
||||
@@ -113,11 +115,6 @@
|
||||
var/contamination_flavor = "Generic" // Determines descriptions of contaminated items
|
||||
var/contamination_color = "green" // Color of contamination overlay
|
||||
|
||||
//Mostly for being overridden on precreated bellies on mobs. Could be VV'd into
|
||||
//a carbon's belly if someone really wanted. No UI for carbons to adjust this.
|
||||
//List has indexes that are the digestion mode strings, and keys that are lists of strings.
|
||||
var/tmp/list/emote_lists = list()
|
||||
|
||||
// Lets you do a fullscreen overlay. Set to an icon_state string.
|
||||
var/belly_fullscreen = ""
|
||||
var/disable_hud = FALSE
|
||||
@@ -152,6 +149,8 @@
|
||||
"digest_messages_prey",
|
||||
"examine_messages",
|
||||
"emote_lists",
|
||||
"emote_time",
|
||||
"emote_active",
|
||||
"mode_flags",
|
||||
"item_digest_mode",
|
||||
"contaminates",
|
||||
@@ -862,6 +861,8 @@
|
||||
dupe.belly_fullscreen = belly_fullscreen
|
||||
dupe.disable_hud = disable_hud
|
||||
dupe.egg_type = egg_type
|
||||
dupe.emote_time = emote_time
|
||||
dupe.emote_active = emote_active
|
||||
|
||||
//// Object-holding variables
|
||||
//struggle_messages_outside - strings
|
||||
|
||||
@@ -56,8 +56,8 @@
|
||||
|
||||
///////////////////// Early Non-Mode Handling /////////////////////
|
||||
var/list/EL = emote_lists[digest_mode]
|
||||
if(LAZYLEN(EL) && touchable_mobs && next_emote <= world.time)
|
||||
next_emote = world.time + emote_time
|
||||
if(LAZYLEN(EL) && touchable_mobs && next_emote <= world.time && emote_active)
|
||||
next_emote = world.time + (emote_time SECONDS)
|
||||
for(var/mob/living/M in contents)
|
||||
if(digest_mode == DM_DIGEST && !M.digestable)
|
||||
continue // don't give digesty messages to indigestible people
|
||||
|
||||
@@ -158,6 +158,8 @@
|
||||
"digest_burn" = selected.digest_burn,
|
||||
"bulge_size" = selected.bulge_size,
|
||||
"shrink_grow_size" = selected.shrink_grow_size,
|
||||
"emote_time" = selected.emote_time,
|
||||
"emote_active" = selected.emote_active,
|
||||
"belly_fullscreen" = selected.belly_fullscreen,
|
||||
"belly_fullscreen_color" = selected.belly_fullscreen_color, //CHOMPEdit
|
||||
"mapRef" = map_name, //CHOMPEdit
|
||||
@@ -902,6 +904,16 @@
|
||||
var/new_new_damage = CLAMP(new_damage, 0, 6)
|
||||
host.vore_selected.digest_brute = new_new_damage
|
||||
. = TRUE
|
||||
if("b_emoteactive")
|
||||
host.vore_selected.emote_active = !host.vore_selected.emote_active
|
||||
. = TRUE
|
||||
if("b_emotetime")
|
||||
var/new_time = input(user, "Choose the period it takes for idle belly emotes to be shown to prey. Measured in seconds, Minimum 1 minute, Maximum 10 minutes.", "Set Belly Emote Delay.", host.vore_selected.digest_brute)
|
||||
if(new_time == null)
|
||||
return FALSE
|
||||
var/new_new_time = CLAMP(new_time, 60, 600)
|
||||
host.vore_selected.emote_time = new_new_time
|
||||
. = TRUE
|
||||
if("b_escapable")
|
||||
if(host.vore_selected.escapable == 0) //Possibly escapable and special interactions.
|
||||
host.vore_selected.escapable = 1
|
||||
|
||||
@@ -289,6 +289,8 @@ const VoreSelectedBelly = (props, context) => {
|
||||
digest_burn,
|
||||
bulge_size,
|
||||
shrink_grow_size,
|
||||
emote_time,
|
||||
emote_active,
|
||||
addons,
|
||||
contaminates,
|
||||
contaminate_flavor,
|
||||
@@ -547,6 +549,7 @@ const VoreSelectedBelly = (props, context) => {
|
||||
onClick={() => act("set_attribute", { attribute: "b_grow_shrink" })}
|
||||
content={shrink_grow_size * 100 + "%"} />
|
||||
</LabeledList.Item>
|
||||
<<<<<<< HEAD
|
||||
<LabeledList.Item label="Vore Spawn Blacklist">
|
||||
<Button
|
||||
onClick={() => act("set_attribute", { attribute: "b_vorespawn_blacklist" })}
|
||||
@@ -554,6 +557,21 @@ const VoreSelectedBelly = (props, context) => {
|
||||
selected={vorespawn_blacklist}
|
||||
content={vorespawn_blacklist ? "Yes" : "No"} />
|
||||
</LabeledList.Item>
|
||||
||||||| parent of e62be0a1e6... Merge pull request #9914 from Heroman3003/emotiguration
|
||||
=======
|
||||
<LabeledList.Item label="Idle Emotes">
|
||||
<Button
|
||||
onClick={() => act("set_attribute", { attribute: "b_emoteactive" })}
|
||||
icon={emote_active ? "toggle-on" : "toggle-off"}
|
||||
selected={emote_active}
|
||||
content={emote_active ? "Active" : "Inactive"} />
|
||||
</LabeledList.Item>
|
||||
<LabeledList.Item label="Idle Emote Delay">
|
||||
<Button
|
||||
onClick={() => act("set_attribute", { attribute: "b_emotetime" })}
|
||||
content={emote_time + " seconds"} />
|
||||
</LabeledList.Item>
|
||||
>>>>>>> e62be0a1e6... Merge pull request #9914 from Heroman3003/emotiguration
|
||||
</LabeledList>
|
||||
</Flex.Item>
|
||||
<Flex.Item basis="100%" mt={1}>
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user