From 52a0183e8010c555126293c3828dd232fc677cc7 Mon Sep 17 00:00:00 2001 From: NightRed Date: Wed, 2 Sep 2020 17:48:50 -0500 Subject: [PATCH] Cleans up extinguish_mob and prevents perpetual fire (#53252) --- code/__DEFINES/dcs/signals.dm | 2 +- code/datums/diseases/advance/symptoms/heal.dm | 2 +- code/game/machinery/stasis.dm | 2 +- .../effects/effect_system/effects_foam.dm | 3 +- .../effects/effect_system/effects_smoke.dm | 2 +- .../blob/blobstrains/pressurized_slime.dm | 3 +- .../eldritch_cult/eldritch_magic.dm | 2 +- .../components/unary_devices/cryo.dm | 2 +- .../modules/clothing/spacesuits/chronosuit.dm | 2 +- code/modules/clothing/spacesuits/plasmamen.dm | 2 +- .../modules/clothing/suits/reactive_armour.dm | 4 +- .../under/jobs/Plasmaman/civilian_service.dm | 2 +- code/modules/clothing/under/miscellaneous.dm | 2 +- code/modules/flufftext/Hallucination.dm | 2 +- code/modules/mob/living/bloodcrawl.dm | 2 +- code/modules/mob/living/carbon/carbon.dm | 6 +- code/modules/mob/living/carbon/human/life.dm | 4 +- .../mob/living/carbon/human/species.dm | 2 +- code/modules/mob/living/life.dm | 8 +-- code/modules/mob/living/living.dm | 71 +++++++++++++------ code/modules/mob/living/silicon/robot/life.dm | 5 +- .../simple_animal/guardian/types/fire.dm | 4 +- .../mob/living/simple_animal/simple_animal.dm | 2 +- .../reagents/cat2_medicine_reagents.dm | 2 +- .../chemistry/reagents/other_reagents.dm | 5 +- .../reagents/pyrotechnic_reagents.dm | 3 +- .../nanites/nanite_programs/weapon.dm | 4 +- .../crossbreeding/_status_effects.dm | 2 +- .../xenobiology/crossbreeding/consuming.dm | 2 +- .../research/xenobiology/xenobiology.dm | 2 +- code/modules/spells/spell_types/devil.dm | 2 +- .../spells/spell_types/ethereal_jaunt.dm | 2 +- code/modules/vehicles/mecha/_mecha.dm | 2 +- 33 files changed, 92 insertions(+), 70 deletions(-) diff --git a/code/__DEFINES/dcs/signals.dm b/code/__DEFINES/dcs/signals.dm index 658d1082b8b..c535f2b9968 100644 --- a/code/__DEFINES/dcs/signals.dm +++ b/code/__DEFINES/dcs/signals.dm @@ -360,7 +360,7 @@ #define COMSIG_LIVING_RESIST "living_resist" ///from base of mob/living/IgniteMob() (/mob/living) #define COMSIG_LIVING_IGNITED "living_ignite" -///from base of mob/living/ExtinguishMob() (/mob/living) +///from base of mob/living/extinguish_mob() (/mob/living) #define COMSIG_LIVING_EXTINGUISHED "living_extinguished" ///from base of mob/living/electrocute_act(): (shock_damage, source, siemens_coeff, flags) #define COMSIG_LIVING_ELECTROCUTE_ACT "living_electrocute_act" diff --git a/code/datums/diseases/advance/symptoms/heal.dm b/code/datums/diseases/advance/symptoms/heal.dm index a049288947c..1f57d58d541 100644 --- a/code/datums/diseases/advance/symptoms/heal.dm +++ b/code/datums/diseases/advance/symptoms/heal.dm @@ -340,7 +340,7 @@ . = 0 var/mob/living/M = A.affected_mob if(M.fire_stacks < 0) - M.fire_stacks = min(M.fire_stacks + 1 * absorption_coeff, 0) + M.set_fire_stacks(min(M.fire_stacks + 1 * absorption_coeff, 0)) . += power if(M.reagents.has_reagent(/datum/reagent/water/holywater, needs_metabolizing = FALSE)) M.reagents.remove_reagent(/datum/reagent/water/holywater, 0.5 * absorption_coeff) diff --git a/code/game/machinery/stasis.dm b/code/game/machinery/stasis.dm index 028bbfe0aa3..91dc556fefb 100644 --- a/code/game/machinery/stasis.dm +++ b/code/game/machinery/stasis.dm @@ -111,7 +111,7 @@ playsound(src, 'sound/effects/spray.ogg', 5, TRUE, 2, frequency = freq) target.apply_status_effect(STATUS_EFFECT_STASIS, STASIS_MACHINE_EFFECT) ADD_TRAIT(target, TRAIT_TUMOR_SUPPRESSED, TRAIT_GENERIC) - target.ExtinguishMob() + target.extinguish_mob() use_power = ACTIVE_POWER_USE /obj/machinery/stasis/proc/thaw_them(mob/living/target) diff --git a/code/game/objects/effects/effect_system/effects_foam.dm b/code/game/objects/effects/effect_system/effects_foam.dm index 0431da86ca0..23e12d21786 100644 --- a/code/game/objects/effects/effect_system/effects_foam.dm +++ b/code/game/objects/effects/effect_system/effects_foam.dm @@ -64,7 +64,6 @@ if(!istype(L)) return L.adjust_fire_stacks(-2) - L.ExtinguishMob() /obj/effect/particle_effect/foam/firefighting/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) return @@ -327,7 +326,7 @@ U.update_icon() U.visible_message("[U] sealed shut!") for(var/mob/living/L in O) - L.ExtinguishMob() + L.extinguish_mob() for(var/obj/item/Item in O) Item.extinguish() diff --git a/code/game/objects/effects/effect_system/effects_smoke.dm b/code/game/objects/effects/effect_system/effects_smoke.dm index 438a80e3297..972c2130cb0 100644 --- a/code/game/objects/effects/effect_system/effects_smoke.dm +++ b/code/game/objects/effects/effect_system/effects_smoke.dm @@ -181,7 +181,7 @@ U.update_icon() U.visible_message("[U] is frozen shut!") for(var/mob/living/L in T) - L.ExtinguishMob() + L.extinguish_mob() for(var/obj/item/Item in T) Item.extinguish() diff --git a/code/modules/antagonists/blob/blobstrains/pressurized_slime.dm b/code/modules/antagonists/blob/blobstrains/pressurized_slime.dm index 7647d5ad958..2281e1b59be 100644 --- a/code/modules/antagonists/blob/blobstrains/pressurized_slime.dm +++ b/code/modules/antagonists/blob/blobstrains/pressurized_slime.dm @@ -32,7 +32,7 @@ O.extinguish() for(var/mob/living/L in T) L.adjust_fire_stacks(-2.5) - L.ExtinguishMob() + L.extinguish_mob() /datum/reagent/blob/pressurized_slime name = "Pressurized Slime" @@ -45,7 +45,6 @@ if(istype(T) && prob(reac_volume)) T.MakeSlippery(TURF_WET_LUBE, min_wet_time = 10 SECONDS, wet_time_to_add = 5 SECONDS) M.adjust_fire_stacks(-(reac_volume / 10)) - M.ExtinguishMob() M.apply_damage(0.4*reac_volume, BRUTE, wound_bonus=CANT_WOUND) if(M) M.apply_damage(0.4*reac_volume, OXY) diff --git a/code/modules/antagonists/eldritch_cult/eldritch_magic.dm b/code/modules/antagonists/eldritch_cult/eldritch_magic.dm index aeb3db18cbc..f83f4efbd08 100644 --- a/code/modules/antagonists/eldritch_cult/eldritch_magic.dm +++ b/code/modules/antagonists/eldritch_cult/eldritch_magic.dm @@ -515,7 +515,7 @@ target.death() target.adjustFireLoss(20) new /obj/effect/temp_visual/eldritch_smoke(target.drop_location()) - human_user.ExtinguishMob() + human_user.extinguish_mob() human_user.adjustBruteLoss(-10, FALSE) human_user.adjustFireLoss(-10, FALSE) human_user.adjustStaminaLoss(-10, FALSE) diff --git a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm index db4b1dc8fd7..c7717b9711d 100644 --- a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm +++ b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm @@ -207,7 +207,7 @@ var/mob/living/mob_occupant = occupant if(mob_occupant.on_fire) - mob_occupant.ExtinguishMob() + mob_occupant.extinguish_mob() if(!check_nap_violations()) return if(mob_occupant.stat == DEAD) // We don't bother with dead people. diff --git a/code/modules/clothing/spacesuits/chronosuit.dm b/code/modules/clothing/spacesuits/chronosuit.dm index 383957b531e..34b40dd797e 100644 --- a/code/modules/clothing/spacesuits/chronosuit.dm +++ b/code/modules/clothing/spacesuits/chronosuit.dm @@ -130,7 +130,7 @@ if(exposed_I && !(exposed_I.type in chronosafe_items) && user.dropItemToGround(exposed_I)) to_chat(user, "Your [exposed_I.name] got left behind.") - user.ExtinguishMob() + user.extinguish_mob() for(var/obj/item/I in user.held_items) ADD_TRAIT(I, TRAIT_NODROP, CHRONOSUIT_TRAIT) diff --git a/code/modules/clothing/spacesuits/plasmamen.dm b/code/modules/clothing/spacesuits/plasmamen.dm index a011611af42..1fceaa16941 100644 --- a/code/modules/clothing/spacesuits/plasmamen.dm +++ b/code/modules/clothing/spacesuits/plasmamen.dm @@ -30,7 +30,7 @@ next_extinguish = world.time + extinguish_cooldown extinguishes_left-- H.visible_message("[H]'s suit automatically extinguishes [H.p_them()]!","Your suit automatically extinguishes you.") - H.ExtinguishMob() + H.extinguish_mob() new /obj/effect/particle_effect/water(get_turf(H)) diff --git a/code/modules/clothing/suits/reactive_armour.dm b/code/modules/clothing/suits/reactive_armour.dm index 1a142c1045c..a1ab9559d35 100644 --- a/code/modules/clothing/suits/reactive_armour.dm +++ b/code/modules/clothing/suits/reactive_armour.dm @@ -115,9 +115,9 @@ playsound(get_turf(owner),'sound/magic/fireball.ogg', 100, TRUE) for(var/mob/living/carbon/C in range(6, owner)) if(C != owner) - C.fire_stacks += 8 + C.adjust_fire_stacks(8) C.IgniteMob() - owner.fire_stacks = -20 + owner.set_fire_stacks(-20) reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration return TRUE return FALSE diff --git a/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm b/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm index 04ee1dd5a8f..838957d3481 100644 --- a/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm +++ b/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm @@ -77,5 +77,5 @@ next_extinguish = world.time + extinguish_cooldown extinguishes_left-- H.visible_message("[H]'s suit spews space lube everywhere!","Your suit spews space lube everywhere!") - H.ExtinguishMob() + H.extinguish_mob() new /obj/effect/particle_effect/foam(loc) //Truely terrifying. diff --git a/code/modules/clothing/under/miscellaneous.dm b/code/modules/clothing/under/miscellaneous.dm index ca6f58a5ab5..7c6ad839250 100644 --- a/code/modules/clothing/under/miscellaneous.dm +++ b/code/modules/clothing/under/miscellaneous.dm @@ -112,7 +112,7 @@ next_extinguish = world.time + extinguish_cooldown extinguishes_left-- H.visible_message("[H]'s suit automatically extinguishes [H.p_them()]!","Your suit automatically extinguishes you.") - H.ExtinguishMob() + H.extinguish_mob() new /obj/effect/particle_effect/water(get_turf(H)) /obj/item/clothing/under/plasmaman/attackby(obj/item/E, mob/user, params) diff --git a/code/modules/flufftext/Hallucination.dm b/code/modules/flufftext/Hallucination.dm index 89611b8dd57..ad263c15703 100644 --- a/code/modules/flufftext/Hallucination.dm +++ b/code/modules/flufftext/Hallucination.dm @@ -1183,7 +1183,7 @@ GLOBAL_LIST_INIT(hallucination_list, list( /datum/hallucination/fire/New(mob/living/carbon/C, forced = TRUE) set waitfor = FALSE ..() - target.fire_stacks = max(target.fire_stacks, 0.1) //Placebo flammability + target.set_fire_stacks(max(target.fire_stacks, 0.1)) //Placebo flammability fire_overlay = image('icons/mob/OnFire.dmi', target, "Standing", ABOVE_MOB_LAYER) if(target.client) target.client.images += fire_overlay diff --git a/code/modules/mob/living/bloodcrawl.dm b/code/modules/mob/living/bloodcrawl.dm index c09fef670ad..f7451edba28 100644 --- a/code/modules/mob/living/bloodcrawl.dm +++ b/code/modules/mob/living/bloodcrawl.dm @@ -55,7 +55,7 @@ // Extinguish, unbuckle, stop being pulled, set our location into the // dummy object var/obj/effect/dummy/phased_mob/slaughter/holder = new /obj/effect/dummy/phased_mob/slaughter(mobloc) - ExtinguishMob() + extinguish_mob() // Keep a reference to whatever we're pulling, because forceMove() // makes us stop pulling diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 0823c844b0d..b35d690ef3f 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -289,7 +289,7 @@ buckled.user_unbuckle_mob(src,src) /mob/living/carbon/resist_fire() - fire_stacks -= 5 + adjust_fire_stacks(-5) Paralyze(60, TRUE, TRUE) spin(32,2) visible_message("[src] rolls on the floor, trying to put [p_them()]self out!", \ @@ -298,7 +298,7 @@ if(fire_stacks <= 0 && !QDELETED(src)) visible_message("[src] successfully extinguishes [p_them()]self!", \ "You extinguish yourself.") - ExtinguishMob() + extinguish_mob() return /mob/living/carbon/resist_restraints() @@ -924,7 +924,7 @@ if(organs_amt) to_chat(user, "You retrieve some of [src]\'s internal organs!") -/mob/living/carbon/ExtinguishMob() +/mob/living/carbon/extinguish_mob() for(var/X in get_equipped_items()) var/obj/item/I = X I.acid_level = 0 //washes off the acid on our clothes diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index bc9a69097ca..f23e6326bfe 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -162,8 +162,8 @@ return ..() . = FALSE //No ignition -/mob/living/carbon/human/ExtinguishMob() - if(!dna || !dna.species.ExtinguishMob(src)) +/mob/living/carbon/human/extinguish_mob() + if(!dna || !dna.species.extinguish_mob(src)) last_fire_update = null ..() //END FIRE CODE diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index cdd80117e92..7c15e50ed74 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1810,7 +1810,7 @@ GLOBAL_LIST_EMPTY(roundstart_races) return FALSE return TRUE -/datum/species/proc/ExtinguishMob(mob/living/carbon/human/H) +/datum/species/proc/extinguish_mob(mob/living/carbon/human/H) return diff --git a/code/modules/mob/living/life.dm b/code/modules/mob/living/life.dm index 7cce89593b4..ac7d6f3bd59 100644 --- a/code/modules/mob/living/life.dm +++ b/code/modules/mob/living/life.dm @@ -100,17 +100,17 @@ /mob/living/proc/handle_fire() if(fire_stacks < 0) //If we've doused ourselves in water to avoid fire, dry off slowly - fire_stacks = min(0, fire_stacks + 1)//So we dry ourselves back to default, nonflammable. + set_fire_stacks(min(0, fire_stacks + 1)) //So we dry ourselves back to default, nonflammable. if(!on_fire) return TRUE //the mob is no longer on fire, no need to do the rest. if(fire_stacks > 0) adjust_fire_stacks(-0.1) //the fire is slowly consumed else - ExtinguishMob() - return TRUE //mob was put out, on_fire = FALSE via ExtinguishMob(), no need to update everything down the chain. + extinguish_mob() + return TRUE //mob was put out, on_fire = FALSE via extinguish_mob(), no need to update everything down the chain. var/datum/gas_mixture/G = loc.return_air() // Check if we're standing in an oxygenless environment if(!G.gases[/datum/gas/oxygen] || G.gases[/datum/gas/oxygen][MOLES] < 1) - ExtinguishMob() //If there's no oxygen in the tile we're on, put out the fire + extinguish_mob() //If there's no oxygen in the tile we're on, put out the fire return TRUE var/turf/location = get_turf(src) location.hotspot_expose(700, 50, 1) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 644a6a6de44..607490e1b26 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -620,7 +620,7 @@ cure_husk() hallucination = 0 heal_overall_damage(INFINITY, INFINITY, INFINITY, null, TRUE) //heal brute and burn dmg on both organic and robotic limbs, and update health right away. - ExtinguishMob() + extinguish_mob() fire_stacks = 0 set_confusion(0) dizziness = 0 @@ -1120,7 +1120,7 @@ //Mobs on Fire /mob/living/proc/IgniteMob() if(fire_stacks > 0 && !on_fire) - on_fire = 1 + on_fire = TRUE src.visible_message("[src] catches fire!", \ "You're set on fire!") new/obj/effect/dummy/lighting_obj/moblight/fire(src) @@ -1130,21 +1130,48 @@ return TRUE return FALSE -/mob/living/proc/ExtinguishMob() - if(on_fire) - on_fire = FALSE - fire_stacks = 0 - for(var/obj/effect/dummy/lighting_obj/moblight/fire/F in src) - qdel(F) - clear_alert("fire") - SEND_SIGNAL(src, COMSIG_CLEAR_MOOD_EVENT, "on_fire") - SEND_SIGNAL(src, COMSIG_LIVING_EXTINGUISHED, src) - update_fire() +/** + * Extinguish all fire on the mob + * + * This removes all fire stacks, fire effects, alerts, and moods + * Signals the extinguishing. + */ +/mob/living/proc/extinguish_mob() + if(!on_fire) + return + on_fire = FALSE + fire_stacks = 0 //If it is not called from set_fire_stacks() + for(var/obj/effect/dummy/lighting_obj/moblight/fire/F in src) + qdel(F) + clear_alert("fire") + SEND_SIGNAL(src, COMSIG_CLEAR_MOOD_EVENT, "on_fire") + SEND_SIGNAL(src, COMSIG_LIVING_EXTINGUISHED, src) + update_fire() -/mob/living/proc/adjust_fire_stacks(add_fire_stacks) //Adjusting the amount of fire_stacks we have on person - fire_stacks = clamp(fire_stacks + add_fire_stacks, -20, 20) - if(on_fire && fire_stacks <= 0) - ExtinguishMob() +/** + * Adjust the amount of fire stacks on a mob + * + * This modifies the fire stacks on a mob. + * + * Vars: + * * add_fire_stacks: int The amount to modify the fire stacks + */ +/mob/living/proc/adjust_fire_stacks(add_fire_stacks) + set_fire_stacks(fire_stacks + add_fire_stacks) + +/** + * Set the fire stacks on a mob + * + * This sets the fire stacks on a mob, stacks are clamped between -20 and 20. + * If the fire stacks are reduced to 0 then we will extinguish the mob. + * + * Vars: + * * stacks: int The amount to set fire_stacks to + */ +/mob/living/proc/set_fire_stacks(stacks) + fire_stacks = clamp(stacks, -20, 20) + if(fire_stacks <= 0) + extinguish_mob() //Share fire evenly between the two mobs //Called in MobBump() and Crossed() @@ -1155,17 +1182,17 @@ if(on_fire) if(L.on_fire) // If they were also on fire var/firesplit = (fire_stacks + L.fire_stacks)/2 - fire_stacks = firesplit - L.fire_stacks = firesplit + set_fire_stacks(firesplit) + L.set_fire_stacks(firesplit) else // If they were not - fire_stacks /= 2 - L.fire_stacks += fire_stacks + set_fire_stacks(fire_stacks / 2) + L.adjust_fire_stacks(fire_stacks) if(L.IgniteMob()) // Ignite them log_game("[key_name(src)] bumped into [key_name(L)] and set them on fire") else if(L.on_fire) // If they were on fire and we were not - L.fire_stacks /= 2 - fire_stacks += L.fire_stacks + L.set_fire_stacks(L.fire_stacks / 2) + adjust_fire_stacks(L.fire_stacks) IgniteMob() // Ignite us //Mobs on Fire end diff --git a/code/modules/mob/living/silicon/robot/life.dm b/code/modules/mob/living/silicon/robot/life.dm index 8cf67247ba0..b9fb6e594e5 100644 --- a/code/modules/mob/living/silicon/robot/life.dm +++ b/code/modules/mob/living/silicon/robot/life.dm @@ -76,10 +76,9 @@ if(.) //if the mob isn't on fire anymore return if(fire_stacks > 0) - fire_stacks-- - fire_stacks = max(0, fire_stacks) + adjust_fire_stacks(-1) else - ExtinguishMob() + extinguish_mob() return TRUE //adjustFireLoss(3) diff --git a/code/modules/mob/living/simple_animal/guardian/types/fire.dm b/code/modules/mob/living/simple_animal/guardian/types/fire.dm index 1b50d1ad95c..8ccdd12e996 100644 --- a/code/modules/mob/living/simple_animal/guardian/types/fire.dm +++ b/code/modules/mob/living/simple_animal/guardian/types/fire.dm @@ -17,7 +17,7 @@ /mob/living/simple_animal/hostile/guardian/fire/Life() . = ..() if(summoner) - summoner.ExtinguishMob() + summoner.extinguish_mob() summoner.adjust_fire_stacks(-20) /mob/living/simple_animal/hostile/guardian/fire/AttackingTarget() @@ -41,5 +41,5 @@ if(isliving(AM)) var/mob/living/M = AM if(!hasmatchingsummoner(M) && M != summoner && M.fire_stacks < 7) - M.fire_stacks = 7 + M.set_fire_stacks(7) M.IgniteMob() diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm index 9bc311d65fd..5e2073bdda0 100644 --- a/code/modules/mob/living/simple_animal/simple_animal.dm +++ b/code/modules/mob/living/simple_animal/simple_animal.dm @@ -461,7 +461,7 @@ /mob/living/simple_animal/IgniteMob() return FALSE -/mob/living/simple_animal/ExtinguishMob() +/mob/living/simple_animal/extinguish_mob() return /mob/living/simple_animal/revive(full_heal = FALSE, admin_revive = FALSE) diff --git a/code/modules/reagents/chemistry/reagents/cat2_medicine_reagents.dm b/code/modules/reagents/chemistry/reagents/cat2_medicine_reagents.dm index 0beb2583796..622bd73c77e 100644 --- a/code/modules/reagents/chemistry/reagents/cat2_medicine_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/cat2_medicine_reagents.dm @@ -196,7 +196,7 @@ M.adjust_bodytemperature(-reac_volume * TEMPERATURE_DAMAGE_COEFFICIENT, 50) M.adjust_fire_stacks(-reac_volume / 2) if(reac_volume >= metabolization_rate) - M.ExtinguishMob() + M.extinguish_mob() ..() diff --git a/code/modules/reagents/chemistry/reagents/other_reagents.dm b/code/modules/reagents/chemistry/reagents/other_reagents.dm index e4331d4cdbd..f0817aac95f 100644 --- a/code/modules/reagents/chemistry/reagents/other_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/other_reagents.dm @@ -197,8 +197,7 @@ if(!istype(M)) return if(methods & TOUCH) - M.adjust_fire_stacks(-(reac_volume / 10)) - M.ExtinguishMob() + M.extinguish_mob() // extinguish removes all fire stacks ..() /datum/reagent/water/on_mob_life(mob/living/carbon/M) @@ -366,7 +365,7 @@ taste_description = "burning" /datum/reagent/hellwater/on_mob_life(mob/living/carbon/M) - M.fire_stacks = min(5,M.fire_stacks + 3) + M.set_fire_stacks(min(5, M.fire_stacks + 3)) M.IgniteMob() //Only problem with igniting people is currently the commonly available fire suits make you immune to being on fire M.adjustToxLoss(1, 0) M.adjustFireLoss(1, 0) //Hence the other damages... ain't I a bastard? diff --git a/code/modules/reagents/chemistry/reagents/pyrotechnic_reagents.dm b/code/modules/reagents/chemistry/reagents/pyrotechnic_reagents.dm index 3c3b9483cd4..f4125263d55 100644 --- a/code/modules/reagents/chemistry/reagents/pyrotechnic_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/pyrotechnic_reagents.dm @@ -312,6 +312,5 @@ /datum/reagent/firefighting_foam/expose_mob(mob/living/M, methods=TOUCH, reac_volume) if(methods & (TOUCH|VAPOR)) - M.adjust_fire_stacks(-reac_volume) - M.ExtinguishMob() + M.extinguish_mob() //All stacks are removed ..() diff --git a/code/modules/research/nanites/nanite_programs/weapon.dm b/code/modules/research/nanites/nanite_programs/weapon.dm index 16f87bc6bde..d9d2f418ae5 100644 --- a/code/modules/research/nanites/nanite_programs/weapon.dm +++ b/code/modules/research/nanites/nanite_programs/weapon.dm @@ -127,7 +127,7 @@ empulse(host_mob, 1, 2) /datum/nanite_program/pyro/active_effect() - host_mob.fire_stacks += 1 + host_mob.adjust_fire_stacks(1) host_mob.IgniteMob() /datum/nanite_program/pyro @@ -142,7 +142,7 @@ return ..() /datum/nanite_program/pyro/active_effect() - host_mob.fire_stacks += 1 + host_mob.adjust_fire_stacks(1) host_mob.IgniteMob() /datum/nanite_program/cryo diff --git a/code/modules/research/xenobiology/crossbreeding/_status_effects.dm b/code/modules/research/xenobiology/crossbreeding/_status_effects.dm index 3f072210a85..e7e1e04a414 100644 --- a/code/modules/research/xenobiology/crossbreeding/_status_effects.dm +++ b/code/modules/research/xenobiology/crossbreeding/_status_effects.dm @@ -591,7 +591,7 @@ /datum/status_effect/stabilized/darkblue/tick() if(owner.fire_stacks > 0 && prob(80)) - owner.fire_stacks-- + owner.adjust_fire_stacks(-1) if(owner.fire_stacks <= 0) to_chat(owner, "[linked_extract] coats you in a watery goo, extinguishing the flames.") var/obj/O = owner.get_active_held_item() diff --git a/code/modules/research/xenobiology/crossbreeding/consuming.dm b/code/modules/research/xenobiology/crossbreeding/consuming.dm index 8b0980bb7c7..6322ae98ac2 100644 --- a/code/modules/research/xenobiology/crossbreeding/consuming.dm +++ b/code/modules/research/xenobiology/crossbreeding/consuming.dm @@ -196,7 +196,7 @@ Consuming extracts: /obj/item/slime_cookie/darkblue/do_effect(mob/living/M, mob/user) M.adjust_bodytemperature(-110) - M.ExtinguishMob() + M.extinguish_mob() /obj/item/slimecross/consuming/silver colour = "silver" diff --git a/code/modules/research/xenobiology/xenobiology.dm b/code/modules/research/xenobiology/xenobiology.dm index 43ec37a5d4f..f0710f3b25c 100644 --- a/code/modules/research/xenobiology/xenobiology.dm +++ b/code/modules/research/xenobiology/xenobiology.dm @@ -337,7 +337,7 @@ switch(activation_type) if(SLIME_ACTIVATE_MINOR) to_chat(user, "You activate [src]. You start feeling colder!") - user.ExtinguishMob() + user.extinguish_mob() user.adjust_fire_stacks(-20) user.reagents.add_reagent(/datum/reagent/consumable/frostoil,4) user.reagents.add_reagent(/datum/reagent/medicine/cryoxadone,5) diff --git a/code/modules/spells/spell_types/devil.dm b/code/modules/spells/spell_types/devil.dm index eaa8eae9731..444edf43be3 100644 --- a/code/modules/spells/spell_types/devil.dm +++ b/code/modules/spells/spell_types/devil.dm @@ -146,7 +146,7 @@ visible_message("[src] disappears in a flashfire!") playsound(get_turf(src), 'sound/magic/enter_blood.ogg', 100, TRUE, -1) var/obj/effect/dummy/phased_mob/slaughter/holder = new /obj/effect/dummy/phased_mob/slaughter(loc) - ExtinguishMob() + extinguish_mob() forceMove(holder) holder = holder notransform = FALSE diff --git a/code/modules/spells/spell_types/ethereal_jaunt.dm b/code/modules/spells/spell_types/ethereal_jaunt.dm index 50b62640c37..1c890f1a0dc 100644 --- a/code/modules/spells/spell_types/ethereal_jaunt.dm +++ b/code/modules/spells/spell_types/ethereal_jaunt.dm @@ -27,7 +27,7 @@ var/turf/mobloc = get_turf(target) var/obj/effect/dummy/phased_mob/spell_jaunt/holder = new /obj/effect/dummy/phased_mob/spell_jaunt(mobloc) new jaunt_out_type(mobloc, target.dir) - target.ExtinguishMob() + target.extinguish_mob() target.forceMove(holder) target.reset_perspective(holder) target.notransform=0 //mob is safely inside holder now, no need for protection. diff --git a/code/modules/vehicles/mecha/_mecha.dm b/code/modules/vehicles/mecha/_mecha.dm index 34bebd2bb27..9fe8ceb9bc1 100644 --- a/code/modules/vehicles/mecha/_mecha.dm +++ b/code/modules/vehicles/mecha/_mecha.dm @@ -499,7 +499,7 @@ for(var/M in occupants) var/mob/living/cookedalive = M if(cookedalive.fire_stacks < 5) - cookedalive.fire_stacks += 1 + cookedalive.adjust_fire_stacks(1) cookedalive.IgniteMob() /obj/vehicle/sealed/mecha/proc/display_speech_bubble(datum/source, list/speech_args)