From 277722508aac4807bbeef93b2f7a320c1e123282 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Mon, 18 Mar 2019 20:06:15 -0400 Subject: [PATCH 01/12] [Goonchem] Reagent Temperature --- code/LINDA/LINDA_fire.dm | 4 ++ code/__HELPERS/unsorted.dm | 4 +- code/_onclick/item_attack.dm | 4 +- code/game/atoms.dm | 5 ++- code/game/gamemodes/blob/blobs/blob_mobs.dm | 2 +- code/game/gamemodes/blob/blobs/core.dm | 2 +- code/game/gamemodes/blob/blobs/node.dm | 2 +- code/game/gamemodes/blob/blobs/shield.dm | 10 ++--- code/game/gamemodes/blob/theblob.dm | 2 +- code/game/gamemodes/wizard/artefact.dm | 2 +- code/game/machinery/atmoalter/canister.dm | 1 + code/game/machinery/doors/airlock_types.dm | 1 + code/game/machinery/doors/windowdoor.dm | 2 +- code/game/machinery/firealarm.dm | 1 + code/game/mecha/mecha.dm | 1 + .../objects/effects/decals/Cleanable/misc.dm | 3 +- code/game/objects/effects/decals/cleanable.dm | 15 +------- .../effects/effect_system/effects_foam.dm | 5 ++- code/game/objects/effects/effects.dm | 3 -- code/game/objects/effects/glowshroom.dm | 1 + code/game/objects/effects/snowcloud.dm | 6 ++- code/game/objects/effects/spiders.dm | 1 + code/game/objects/items/candle.dm | 3 +- .../objects/items/devices/taperecorder.dm | 5 ++- code/game/objects/items/flag.dm | 2 +- code/game/objects/items/latexballoon.dm | 2 +- .../objects/items/stacks/sheets/mineral.dm | 3 +- code/game/objects/items/toys.dm | 5 ++- code/game/objects/items/weapons/cigs.dm | 3 +- code/game/objects/items/weapons/lighters.dm | 3 +- code/game/objects/obj_defense.dm | 7 ++-- code/game/objects/structures/aliens.dm | 2 + code/game/objects/structures/bedsheet_bin.dm | 2 +- code/game/objects/structures/false_walls.dm | 1 + code/game/objects/structures/girders.dm | 1 + code/game/objects/structures/grille.dm | 2 +- code/game/objects/structures/mineral_doors.dm | 1 + code/game/objects/structures/statues.dm | 4 +- code/game/objects/structures/window.dm | 2 +- code/game/turfs/simulated/floor/mineral.dm | 1 + code/game/turfs/simulated/walls_mineral.dm | 1 + code/modules/events/spacevine.dm | 1 + code/modules/food_and_drinks/drinks/drinks.dm | 11 ------ .../drinks/drinks/drinkingglass.dm | 2 +- .../drinks/drinks/shotglass.dm | 2 +- code/modules/hydroponics/grown/misc.dm | 3 +- code/modules/hydroponics/grown/towercap.dm | 3 +- code/modules/mining/ore.dm | 2 +- .../living/carbon/alien/special/facehugger.dm | 2 +- code/modules/mob/living/living_defense.dm | 3 +- code/modules/mob/living/silicon/robot/life.dm | 2 +- code/modules/paperwork/paper.dm | 2 +- code/modules/paperwork/paperbin.dm | 2 +- code/modules/power/lighting.dm | 1 + code/modules/reagents/chem_splash.dm | 3 +- code/modules/reagents/chemistry/holder.dm | 35 ++++++++++++++--- .../chemistry/machinery/chem_heater.dm | 38 +++++++------------ code/modules/reagents/chemistry/reagents.dm | 3 ++ .../chemistry/reagents/pyrotechnic.dm | 10 +++-- .../reagents/chemistry/recipes/drinks.dm | 4 +- .../reagents/chemistry/recipes/drugs.dm | 8 ++-- .../reagents/chemistry/recipes/food.dm | 10 ++--- .../reagents/chemistry/recipes/medicine.dm | 10 ++--- .../reagents/chemistry/recipes/others.dm | 20 +++++----- .../chemistry/recipes/pyrotechnics.dm | 14 +++---- .../reagents/chemistry/recipes/toxins.dm | 12 +++--- code/modules/reagents/reagent_containers.dm | 5 --- .../reagent_containers/glass_containers.dm | 10 +---- code/modules/reagents/reagent_dispenser.dm | 3 +- 69 files changed, 182 insertions(+), 166 deletions(-) diff --git a/code/LINDA/LINDA_fire.dm b/code/LINDA/LINDA_fire.dm index ada5e6a9e5f..13e20785d33 100644 --- a/code/LINDA/LINDA_fire.dm +++ b/code/LINDA/LINDA_fire.dm @@ -1,5 +1,7 @@ /atom/proc/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + if(reagents) + reagents.temperature_reagents(exposed_temperature) return null @@ -10,6 +12,8 @@ /turf/simulated/hotspot_expose(exposed_temperature, exposed_volume, soh) var/datum/gas_mixture/air_contents = return_air() + if(reagents) + reagents.temperature_reagents(exposed_temperature, 10, 300) if(!air_contents) return 0 if(active_hotspot) diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index d9039e8c004..a22c4cf3f99 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -1165,7 +1165,7 @@ var/global/list/common_tools = list( if(istype(W, /obj/item/weldingtool)) var/obj/item/weldingtool/O = W if(O.isOn()) - return 3800 + return 2500 else return 0 if(istype(W, /obj/item/lighter)) @@ -1207,7 +1207,7 @@ var/global/list/common_tools = list( else return 0 if(istype(W, /obj/item/assembly/igniter)) - return 1000 + return 20000 else return 0 diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index 76ef6bf5031..d47bc134774 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -123,7 +123,9 @@ // Proximity_flag is 1 if this afterattack was called on something adjacent, in your square, or on your person. // Click parameters is the params string from byond Click() code, see that documentation. /obj/item/proc/afterattack(atom/target, mob/user, proximity_flag, click_parameters) - return + if(is_hot(src) && target.reagents && !ismob(target) && proximity_flag) + to_chat(user, "You heat [target].") + target.reagents.temperature_reagents(is_hot(src)) /obj/item/proc/get_clamped_volume() if(w_class) diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 58197cbadf1..91132a5f9bd 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -311,8 +311,9 @@ /atom/proc/blob_act(obj/structure/blob/B) SEND_SIGNAL(src, COMSIG_ATOM_BLOB_ACT, B) -/atom/proc/fire_act() - return +/atom/proc/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + if(reagents) + reagents.temperature_reagents(exposed_temperature) /atom/proc/emag_act() return diff --git a/code/game/gamemodes/blob/blobs/blob_mobs.dm b/code/game/gamemodes/blob/blobs/blob_mobs.dm index e3b1d082623..8b4fae279a3 100644 --- a/code/game/gamemodes/blob/blobs/blob_mobs.dm +++ b/code/game/gamemodes/blob/blobs/blob_mobs.dm @@ -46,7 +46,7 @@ pressure_resistance = 100 //100 kPa difference required to push throw_pressure_limit = 120 //120 kPa difference required to throw -/mob/living/simple_animal/hostile/blob/blobspore/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/mob/living/simple_animal/hostile/blob/blobspore/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) ..() adjustBruteLoss(Clamp(0.01 * exposed_temperature, 1, 5)) diff --git a/code/game/gamemodes/blob/blobs/core.dm b/code/game/gamemodes/blob/blobs/core.dm index 644383f344d..4bdc2cafddd 100644 --- a/code/game/gamemodes/blob/blobs/core.dm +++ b/code/game/gamemodes/blob/blobs/core.dm @@ -45,7 +45,7 @@ GLOB.poi_list.Remove(src) return ..() -/obj/structure/blob/core/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/obj/structure/blob/core/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) return /obj/structure/blob/core/update_icon() diff --git a/code/game/gamemodes/blob/blobs/node.dm b/code/game/gamemodes/blob/blobs/node.dm index 19ac320287a..32b6ce1f408 100644 --- a/code/game/gamemodes/blob/blobs/node.dm +++ b/code/game/gamemodes/blob/blobs/node.dm @@ -20,7 +20,7 @@ var/image/C = new('icons/mob/blob.dmi', "blob_node_overlay") src.overlays += C -/obj/structure/blob/node/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/obj/structure/blob/node/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) return /obj/structure/blob/node/Destroy() diff --git a/code/game/gamemodes/blob/blobs/shield.dm b/code/game/gamemodes/blob/blobs/shield.dm index 1fb293be2cf..696a33d94b9 100644 --- a/code/game/gamemodes/blob/blobs/shield.dm +++ b/code/game/gamemodes/blob/blobs/shield.dm @@ -3,9 +3,9 @@ icon = 'icons/mob/blob.dmi' icon_state = "blob_idle" desc = "Some blob creature thingy" - health = 75 + health = 75 fire_resist = 2 - var/maxHealth = 75 + var/maxHealth = 75 /obj/structure/blob/shield/update_icon() if(health <= 0) @@ -13,7 +13,7 @@ return return -/obj/structure/blob/shield/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/obj/structure/blob/shield/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) return /obj/structure/blob/shield/CanPass(atom/movable/mover, turf/target, height=0) @@ -42,11 +42,11 @@ P.setAngle(new_angle_s) P.firer = src //so people who fired the lasers are not immune to them when it reflects visible_message("[P] reflects off [src]!") - return -1// complete projectile permutation + return -1// complete projectile permutation else playsound(src, P.hitsound, 50, 1) visible_message("[src] is hit by \a [P]!") take_damage(P.damage, P.damage_type) - + /obj/structure/blob/shield/reflective/bullet_act() return diff --git a/code/game/gamemodes/blob/theblob.dm b/code/game/gamemodes/blob/theblob.dm index 7d55f2fe1c9..ba3ad1dada8 100644 --- a/code/game/gamemodes/blob/theblob.dm +++ b/code/game/gamemodes/blob/theblob.dm @@ -45,7 +45,7 @@ Life() return -/obj/structure/blob/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/obj/structure/blob/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) ..() var/damage = Clamp(0.01 * exposed_temperature, 0, 4) take_damage(damage, BURN) diff --git a/code/game/gamemodes/wizard/artefact.dm b/code/game/gamemodes/wizard/artefact.dm index 5ed9af46fe1..dbe3146dd7f 100644 --- a/code/game/gamemodes/wizard/artefact.dm +++ b/code/game/gamemodes/wizard/artefact.dm @@ -868,7 +868,7 @@ var/global/list/multiverse = list() var/area/A = get_area(src) to_chat(victim, "You feel a dark presence from [A.name]") -/obj/item/voodoo/fire_act() +/obj/item/voodoo/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) if(target) target.adjust_fire_stacks(20) target.IgniteMob() diff --git a/code/game/machinery/atmoalter/canister.dm b/code/game/machinery/atmoalter/canister.dm index 1be5fa5e43a..95e609ee524 100644 --- a/code/game/machinery/atmoalter/canister.dm +++ b/code/game/machinery/atmoalter/canister.dm @@ -244,6 +244,7 @@ update_flag return 0 /obj/machinery/portable_atmospherics/canister/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > temperature_resistance) health -= 5 healthcheck() diff --git a/code/game/machinery/doors/airlock_types.dm b/code/game/machinery/doors/airlock_types.dm index 53fab536afd..8e3c7f76342 100644 --- a/code/game/machinery/doors/airlock_types.dm +++ b/code/game/machinery/doors/airlock_types.dm @@ -171,6 +171,7 @@ assemblytype = /obj/structure/door_assembly/door_assembly_plasma /obj/machinery/door/airlock/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) PlasmaBurn(exposed_temperature) diff --git a/code/game/machinery/doors/windowdoor.dm b/code/game/machinery/doors/windowdoor.dm index 1ab22f341b6..21ff909796f 100644 --- a/code/game/machinery/doors/windowdoor.dm +++ b/code/game/machinery/doors/windowdoor.dm @@ -205,9 +205,9 @@ qdel(src) /obj/machinery/door/window/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > T0C + (reinf ? 1600 : 800)) take_damage(round(exposed_volume / 200), BURN, 0, 0) - ..() /obj/machinery/door/window/attack_ai(mob/user) return attack_hand(user) diff --git a/code/game/machinery/firealarm.dm b/code/game/machinery/firealarm.dm index b949028c713..f1651d5bb99 100644 --- a/code/game/machinery/firealarm.dm +++ b/code/game/machinery/firealarm.dm @@ -52,6 +52,7 @@ FIRE ALARM playsound(loc, 'sound/effects/sparks4.ogg', 50, 1) /obj/machinery/firealarm/temperature_expose(datum/gas_mixture/air, temperature, volume) + ..() if(!emagged && detecting && temperature > T0C + 200) alarm() // added check of detector status here diff --git a/code/game/mecha/mecha.dm b/code/game/mecha/mecha.dm index e8e4ae6027b..6cfd1d63942 100644 --- a/code/game/mecha/mecha.dm +++ b/code/game/mecha/mecha.dm @@ -721,6 +721,7 @@ check_for_internal_damage(list(MECHA_INT_FIRE, MECHA_INT_TEMP_CONTROL, MECHA_INT_CONTROL_LOST, MECHA_INT_SHORT_CIRCUIT), 1) /obj/mecha/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > max_temperature) log_message("Exposed to dangerous temperature.", 1) take_damage(5, "fire") diff --git a/code/game/objects/effects/decals/Cleanable/misc.dm b/code/game/objects/effects/decals/Cleanable/misc.dm index aef1999ff69..d601283a703 100644 --- a/code/game/objects/effects/decals/Cleanable/misc.dm +++ b/code/game/objects/effects/decals/Cleanable/misc.dm @@ -90,7 +90,8 @@ icon_state = "cobweb1" burntime = 1 -/obj/effect/decal/cleanable/cobweb/fire_act() +/obj/effect/decal/cleanable/cobweb/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() qdel(src) /obj/effect/decal/cleanable/molten_object diff --git a/code/game/objects/effects/decals/cleanable.dm b/code/game/objects/effects/decals/cleanable.dm index 130a50cac89..52ec24df16c 100644 --- a/code/game/objects/effects/decals/cleanable.dm +++ b/code/game/objects/effects/decals/cleanable.dm @@ -35,22 +35,9 @@ if(!reagents.total_volume && !noclear) //scooped up all of it qdel(src) return - if(is_hot(W)) //todo: make heating a reagent holder proc - if(istype(W, /obj/item/clothing/mask/cigarette)) - return - else - src.reagents.chem_temp += 15 - src.reagents.handle_reactions() - to_chat(user, "You heat [src] with [W]!") /obj/effect/decal/cleanable/ex_act() if(reagents) for(var/datum/reagent/R in reagents.reagent_list) R.on_ex_act() - ..() - -/obj/effect/decal/cleanable/fire_act() - if(reagents) - reagents.chem_temp += 30 - reagents.handle_reactions() - ..() + ..() \ No newline at end of file diff --git a/code/game/objects/effects/effect_system/effects_foam.dm b/code/game/objects/effects/effect_system/effects_foam.dm index e765e59442d..4b07d2a2a98 100644 --- a/code/game/objects/effects/effect_system/effects_foam.dm +++ b/code/game/objects/effects/effect_system/effects_foam.dm @@ -84,7 +84,10 @@ // foam disolves when heated // except metal foams -/obj/effect/particle_effect/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) +/obj/effect/particle_effect/foam/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) //Don't heat the reagents inside + return + +/obj/effect/particle_effect/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) // overriden to prevent weird behaviors with heating reagents inside if(!metal && prob(max(0, exposed_temperature - 475))) flick("[icon_state]-disolve", src) diff --git a/code/game/objects/effects/effects.dm b/code/game/objects/effects/effects.dm index a08e7fac021..21b9759df62 100644 --- a/code/game/objects/effects/effects.dm +++ b/code/game/objects/effects/effects.dm @@ -12,8 +12,5 @@ /obj/effect/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir) return -/obj/effect/fire_act() - return - /obj/effect/attack_hulk(mob/living/carbon/human/user, does_attack_animation = FALSE) return FALSE \ No newline at end of file diff --git a/code/game/objects/effects/glowshroom.dm b/code/game/objects/effects/glowshroom.dm index 4cf5e79cc77..464d5c277fd 100644 --- a/code/game/objects/effects/glowshroom.dm +++ b/code/game/objects/effects/glowshroom.dm @@ -180,6 +180,7 @@ qdel(src) /obj/structure/glowshroom/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) endurance -= 5 CheckEndurance() diff --git a/code/game/objects/effects/snowcloud.dm b/code/game/objects/effects/snowcloud.dm index a67bbd3c5f7..08a64d62f17 100644 --- a/code/game/objects/effects/snowcloud.dm +++ b/code/game/objects/effects/snowcloud.dm @@ -113,7 +113,8 @@ else return ..() -/obj/effect/snow/fire_act() +/obj/effect/snow/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() qdel(src) /obj/effect/snow/ex_act(severity) @@ -133,7 +134,8 @@ ..() qdel(src) -/obj/item/snowball/fire_act() +/obj/item/snowball/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() qdel(src) /obj/item/snowball/ex_act(severity) diff --git a/code/game/objects/effects/spiders.dm b/code/game/objects/effects/spiders.dm index 7ea087eb8cb..f0233bb0f9e 100644 --- a/code/game/objects/effects/spiders.dm +++ b/code/game/objects/effects/spiders.dm @@ -69,6 +69,7 @@ qdel(src) /obj/structure/spider/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) health -= 5 healthcheck() diff --git a/code/game/objects/items/candle.dm b/code/game/objects/items/candle.dm index f4f527c1b7f..85780484264 100644 --- a/code/game/objects/items/candle.dm +++ b/code/game/objects/items/candle.dm @@ -51,7 +51,8 @@ light("[user] tilts [C] and lights [src] with it.") -/obj/item/candle/fire_act() +/obj/item/candle/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() if(!lit) light() //honk diff --git a/code/game/objects/items/devices/taperecorder.dm b/code/game/objects/items/devices/taperecorder.dm index 4eaf0e79dce..d3d0a2fe6bb 100644 --- a/code/game/objects/items/devices/taperecorder.dm +++ b/code/game/objects/items/devices/taperecorder.dm @@ -47,7 +47,7 @@ update_icon() -/obj/item/taperecorder/fire_act() +/obj/item/taperecorder/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) mytape.ruin() //Fires destroy the tape return ..() @@ -262,7 +262,8 @@ var/list/timestamp = list() var/ruined = 0 -/obj/item/tape/fire_act() +/obj/item/tape/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() ruin() /obj/item/tape/attack_self(mob/user) diff --git a/code/game/objects/items/flag.dm b/code/game/objects/items/flag.dm index 4f8abd4ac49..3ba466b7eec 100644 --- a/code/game/objects/items/flag.dm +++ b/code/game/objects/items/flag.dm @@ -21,7 +21,7 @@ user.visible_message("[user] [rolled ? "rolls up" : "unfurls"] [src].", "You [rolled ? "roll up" : "unfurl"] [src].", "You hear fabric rustling.") update_icon() -/obj/item/flag/fire_act(global_overlay = FALSE) +/obj/item/flag/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = FALSE) ..() update_icon() diff --git a/code/game/objects/items/latexballoon.dm b/code/game/objects/items/latexballoon.dm index d7585608ec7..771ccce0f6b 100644 --- a/code/game/objects/items/latexballoon.dm +++ b/code/game/objects/items/latexballoon.dm @@ -50,9 +50,9 @@ burst() /obj/item/latexballon/temperature_expose(datum/gas_mixture/air, temperature, volume) + ..() if(temperature > T0C+100) burst() - return /obj/item/latexballon/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/tank)) diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index 615882021b4..c7a27b5650e 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -179,7 +179,8 @@ var/global/list/datum/stack_recipe/adamantine_recipes = list( else return ..() -/obj/item/stack/sheet/mineral/plasma/fire_act() +/obj/item/stack/sheet/mineral/plasma/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() atmos_spawn_air(SPAWN_HEAT | SPAWN_TOXINS, amount*10) qdel(src) diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index b4405a9fbe5..67fcacbe91a 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -275,7 +275,8 @@ playsound(src, 'sound/effects/snap.ogg', 50, 1) qdel(src) -/obj/item/toy/snappop/fire_act() +/obj/item/toy/snappop/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() pop_burst() /obj/item/toy/snappop/throw_impact(atom/hit_atom) @@ -1689,5 +1690,5 @@ obj/item/toy/cards/deck/syndicate/black /obj/item/restraints/handcuffs/toy desc = "Toy handcuffs. Plastic and extremely cheaply made." throwforce = 0 - breakouttime = 0 + breakouttime = 0 ignoresClumsy = TRUE \ No newline at end of file diff --git a/code/game/objects/items/weapons/cigs.dm b/code/game/objects/items/weapons/cigs.dm index bfe91b5a81b..1378b5c004d 100644 --- a/code/game/objects/items/weapons/cigs.dm +++ b/code/game/objects/items/weapons/cigs.dm @@ -61,7 +61,8 @@ LIGHTERS ARE IN LIGHTERS.DM return ..() -/obj/item/clothing/mask/cigarette/fire_act() +/obj/item/clothing/mask/cigarette/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() light() /obj/item/clothing/mask/cigarette/attackby(obj/item/W as obj, mob/user as mob, params) diff --git a/code/game/objects/items/weapons/lighters.dm b/code/game/objects/items/weapons/lighters.dm index 0b348510b8e..a2d8b03da84 100644 --- a/code/game/objects/items/weapons/lighters.dm +++ b/code/game/objects/items/weapons/lighters.dm @@ -166,7 +166,8 @@ location.hotspot_expose(700, 5) return -/obj/item/match/fire_act() +/obj/item/match/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() matchignite() /obj/item/match/proc/matchignite() diff --git a/code/game/objects/obj_defense.dm b/code/game/objects/obj_defense.dm index 3ab8de69f7f..246fc5df75d 100644 --- a/code/game/objects/obj_defense.dm +++ b/code/game/objects/obj_defense.dm @@ -93,7 +93,7 @@ /obj/move_crushed(atom/movable/pusher, force = MOVE_FORCE_DEFAULT, direction) collision_damage(pusher, force, direction) return TRUE - + /obj/proc/collision_damage(atom/movable/pusher, force = MOVE_FORCE_DEFAULT, direction) var/amt = max(0, ((force - (move_resist * MOVE_FORCE_CRUSH_RATIO)) / (move_resist * MOVE_FORCE_CRUSH_RATIO)) * 10) take_damage(amt, BRUTE) @@ -163,14 +163,15 @@ //// FIRE -/obj/fire_act(global_overlay=1) +/obj/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() if(!burn_state) burn_state = ON_FIRE SSfires.processing[src] = src burn_world_time = world.time + burntime*rand(10,20) if(global_overlay) overlays += fire_overlay - return 1 + return TRUE /obj/proc/burn() empty_object_contents(1, loc) diff --git a/code/game/objects/structures/aliens.dm b/code/game/objects/structures/aliens.dm index 1738344ae60..c6359f7246e 100644 --- a/code/game/objects/structures/aliens.dm +++ b/code/game/objects/structures/aliens.dm @@ -157,6 +157,7 @@ new /obj/structure/alien/weeds(T, linked_node) /obj/structure/alien/weeds/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) take_damage(5, BURN, 0, 0) @@ -294,6 +295,7 @@ Burst(kill = TRUE) /obj/structure/alien/egg/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 500) take_damage(5, BURN, 0, 0) diff --git a/code/game/objects/structures/bedsheet_bin.dm b/code/game/objects/structures/bedsheet_bin.dm index 61113a4864a..8c4f40a7b62 100644 --- a/code/game/objects/structures/bedsheet_bin.dm +++ b/code/game/objects/structures/bedsheet_bin.dm @@ -245,7 +245,7 @@ LINEN BINS else icon_state = "linenbin-full" -/obj/structure/bedsheetbin/fire_act() +/obj/structure/bedsheetbin/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) if(!amount) return ..() diff --git a/code/game/objects/structures/false_walls.dm b/code/game/objects/structures/false_walls.dm index 6851cd3cfc5..9b777d45b58 100644 --- a/code/game/objects/structures/false_walls.dm +++ b/code/game/objects/structures/false_walls.dm @@ -249,6 +249,7 @@ qdel(src) /obj/structure/falsewall/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) burnbabyburn() diff --git a/code/game/objects/structures/girders.dm b/code/game/objects/structures/girders.dm index b46324a838c..b3468668f5a 100644 --- a/code/game/objects/structures/girders.dm +++ b/code/game/objects/structures/girders.dm @@ -48,6 +48,7 @@ qdel(src) /obj/structure/girder/temperature_expose(datum/gas_mixture/air, exposed_temperature) + ..() var/temp_check = exposed_temperature if(temp_check >= GIRDER_MELTING_TEMP) take_damage(10) diff --git a/code/game/objects/structures/grille.dm b/code/game/objects/structures/grille.dm index 8d3e178fe58..c06e5d82244 100644 --- a/code/game/objects/structures/grille.dm +++ b/code/game/objects/structures/grille.dm @@ -261,10 +261,10 @@ return 0 /obj/structure/grille/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(!broken) if(exposed_temperature > T0C + 1500) take_damage(1, BURN, 0, 0) - ..() /obj/structure/grille/hitby(atom/movable/AM) if(istype(AM, /obj)) diff --git a/code/game/objects/structures/mineral_doors.dm b/code/game/objects/structures/mineral_doors.dm index e0e9ba1b6a7..5e6e72929fe 100644 --- a/code/game/objects/structures/mineral_doors.dm +++ b/code/game/objects/structures/mineral_doors.dm @@ -229,6 +229,7 @@ return ..() /obj/structure/mineral_door/transparent/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) TemperatureAct(exposed_temperature) diff --git a/code/game/objects/structures/statues.dm b/code/game/objects/structures/statues.dm index 090327d1c7f..88adc9643ba 100644 --- a/code/game/objects/structures/statues.dm +++ b/code/game/objects/structures/statues.dm @@ -169,6 +169,7 @@ icon_state = "xeno" /obj/structure/statue/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) PlasmaBurn(exposed_temperature) @@ -359,7 +360,8 @@ else return ..() -/obj/structure/snowman/built/fire_act() +/obj/structure/snowman/built/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() qdel(src) diff --git a/code/game/objects/structures/window.dm b/code/game/objects/structures/window.dm index cf87454a97c..ad655a39b64 100644 --- a/code/game/objects/structures/window.dm +++ b/code/game/objects/structures/window.dm @@ -461,9 +461,9 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f overlays += crack_overlay /obj/structure/window/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > (T0C + heat_resistance)) take_damage(round(exposed_volume / 100), BURN, 0, 0) - ..() /obj/structure/window/GetExplosionBlock() return reinf && fulltile ? real_explosion_block : 0 diff --git a/code/game/turfs/simulated/floor/mineral.dm b/code/game/turfs/simulated/floor/mineral.dm index 38f1bdc14a1..d201a38d697 100644 --- a/code/game/turfs/simulated/floor/mineral.dm +++ b/code/game/turfs/simulated/floor/mineral.dm @@ -33,6 +33,7 @@ icons = list("plasma","plasma_dam") /turf/simulated/floor/mineral/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) PlasmaBurn() diff --git a/code/game/turfs/simulated/walls_mineral.dm b/code/game/turfs/simulated/walls_mineral.dm index 3049cb552df..609e5b782c0 100644 --- a/code/game/turfs/simulated/walls_mineral.dm +++ b/code/game/turfs/simulated/walls_mineral.dm @@ -107,6 +107,7 @@ atmos_spawn_air(SPAWN_HEAT | SPAWN_TOXINS, 400) /turf/simulated/wall/mineral/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)//Doesn't fucking work because walls don't interact with air :( + ..() if(exposed_temperature > 300) PlasmaBurn(exposed_temperature) diff --git a/code/modules/events/spacevine.dm b/code/modules/events/spacevine.dm index 55e87f575b0..7d52d7cd969 100644 --- a/code/modules/events/spacevine.dm +++ b/code/modules/events/spacevine.dm @@ -684,6 +684,7 @@ wither() /obj/structure/spacevine/temperature_expose(null, temp, volume) + ..() var/override = 0 for(var/datum/spacevine_mutation/SM in mutations) override += SM.process_temperature(src, temp, volume) diff --git a/code/modules/food_and_drinks/drinks/drinks.dm b/code/modules/food_and_drinks/drinks/drinks.dm index 2c9c2480a4b..52a4a9dcd35 100644 --- a/code/modules/food_and_drinks/drinks/drinks.dm +++ b/code/modules/food_and_drinks/drinks/drinks.dm @@ -106,17 +106,6 @@ return FALSE -/obj/item/reagent_containers/food/drinks/attackby(obj/item/I, mob/user, params) - if(istype(I, /obj/item/clothing/mask/cigarette)) //ciggies are weird - return FALSE - if(is_hot(I)) - if(reagents) - reagents.chem_temp += 15 - to_chat(user, "You heat [src] with [I].") - reagents.handle_reactions() - else - return ..() - /obj/item/reagent_containers/food/drinks/examine(mob/user) if(!..(user, 1)) return diff --git a/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm b/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm index f5bd0e8e4eb..bdc473d774e 100644 --- a/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm +++ b/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm @@ -27,7 +27,7 @@ else ..() -/obj/item/reagent_containers/food/drinks/drinkingglass/fire_act() +/obj/item/reagent_containers/food/drinks/drinkingglass/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) if(!reagents.total_volume) return ..() diff --git a/code/modules/food_and_drinks/drinks/drinks/shotglass.dm b/code/modules/food_and_drinks/drinks/drinks/shotglass.dm index 393543b093c..cd158c70e74 100644 --- a/code/modules/food_and_drinks/drinks/drinks/shotglass.dm +++ b/code/modules/food_and_drinks/drinks/drinks/shotglass.dm @@ -51,7 +51,7 @@ if(A.volume >= 5 && A.alcohol_perc >= 0.35) //Only an approximation to if something's flammable but it will do return TRUE -/obj/item/reagent_containers/food/drinks/drinkingglass/shotglass/fire_act(global_overlay = FALSE) +/obj/item/reagent_containers/food/drinks/drinkingglass/shotglass/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = FALSE) if(!isShotFlammable() || burn_state == ON_FIRE) //You can't light a shot that's not flammable! return ..() diff --git a/code/modules/hydroponics/grown/misc.dm b/code/modules/hydroponics/grown/misc.dm index 605f5082522..0d60c7d864f 100644 --- a/code/modules/hydroponics/grown/misc.dm +++ b/code/modules/hydroponics/grown/misc.dm @@ -151,5 +151,4 @@ /obj/item/reagent_containers/food/snacks/grown/cherry_bomb/proc/prime() icon_state = "cherry_bomb_lit" playsound(src, 'sound/goonstation/misc/fuse.ogg', seed.potency, 0) - reagents.chem_temp = 1000 //Sets off the black powder - reagents.handle_reactions() + reagents.set_reagent_temp(1000) //Sets off the black powder \ No newline at end of file diff --git a/code/modules/hydroponics/grown/towercap.dm b/code/modules/hydroponics/grown/towercap.dm index f71cd6ed86a..4ed9d963274 100644 --- a/code/modules/hydroponics/grown/towercap.dm +++ b/code/modules/hydroponics/grown/towercap.dm @@ -153,7 +153,8 @@ Burn() processing_objects.Add(src) -/obj/structure/bonfire/fire_act(exposed_temperature, exposed_volume) +/obj/structure/bonfire/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() StartBurning() /obj/structure/bonfire/Crossed(atom/movable/AM) diff --git a/code/modules/mining/ore.dm b/code/modules/mining/ore.dm index 08b81e1fd78..dda5fb47f78 100644 --- a/code/modules/mining/ore.dm +++ b/code/modules/mining/ore.dm @@ -52,7 +52,7 @@ F.attackby(OB, AM) return ..() -/obj/item/stack/ore/fire_act() +/obj/item/stack/ore/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) ..() if(isnull(refined_type)) return diff --git a/code/modules/mob/living/carbon/alien/special/facehugger.dm b/code/modules/mob/living/carbon/alien/special/facehugger.dm index 5294e3bda91..04dcb0c60ef 100644 --- a/code/modules/mob/living/carbon/alien/special/facehugger.dm +++ b/code/modules/mob/living/carbon/alien/special/facehugger.dm @@ -65,9 +65,9 @@ var/const/MAX_ACTIVE_TIME = 400 return /obj/item/clothing/mask/facehugger/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(exposed_temperature > 300) Die() - return /obj/item/clothing/mask/facehugger/equipped(mob/M) Attach(M) diff --git a/code/modules/mob/living/living_defense.dm b/code/modules/mob/living/living_defense.dm index f65faaba70d..0641ce380f5 100644 --- a/code/modules/mob/living/living_defense.dm +++ b/code/modules/mob/living/living_defense.dm @@ -179,7 +179,8 @@ var/turf/location = get_turf(src) location.hotspot_expose(700, 50, 1) -/mob/living/fire_act() +/mob/living/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() adjust_fire_stacks(3) IgniteMob() diff --git a/code/modules/mob/living/silicon/robot/life.dm b/code/modules/mob/living/silicon/robot/life.dm index 752cdc0f631..5f37177f674 100644 --- a/code/modules/mob/living/silicon/robot/life.dm +++ b/code/modules/mob/living/silicon/robot/life.dm @@ -230,7 +230,7 @@ if(on_fire) overlays += image("icon"='icons/mob/OnFire.dmi', "icon_state"="Generic_mob_burning") -/mob/living/silicon/robot/fire_act() +/mob/living/silicon/robot/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) if(!on_fire) //Silicons don't gain stacks from hotspots, but hotspots can ignite them IgniteMob() diff --git a/code/modules/paperwork/paper.dm b/code/modules/paperwork/paper.dm index 36af97b0972..87dd368c17d 100644 --- a/code/modules/paperwork/paper.dm +++ b/code/modules/paperwork/paper.dm @@ -401,7 +401,7 @@ add_fingerprint(user) -/obj/item/paper/fire_act() +/obj/item/paper/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) ..() if(burn_state >= FLAMMABLE) //Only render paper that's burnable to be hard to read. info = "[stars(info)]" diff --git a/code/modules/paperwork/paperbin.dm b/code/modules/paperwork/paperbin.dm index a3f41c0ac25..e8643c97cff 100644 --- a/code/modules/paperwork/paperbin.dm +++ b/code/modules/paperwork/paperbin.dm @@ -12,7 +12,7 @@ var/amount = 30 //How much paper is in the bin. var/list/papers = list() //List of papers put in the bin for reference. -/obj/item/paper_bin/fire_act() +/obj/item/paper_bin/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) if(!amount) return ..() diff --git a/code/modules/power/lighting.dm b/code/modules/power/lighting.dm index dcd884da879..8dda1ed8731 100644 --- a/code/modules/power/lighting.dm +++ b/code/modules/power/lighting.dm @@ -586,6 +586,7 @@ // called when on fire /obj/machinery/light/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() if(prob(max(0, exposed_temperature - 673))) //0% at <400C, 100% at >500C broken() diff --git a/code/modules/reagents/chem_splash.dm b/code/modules/reagents/chem_splash.dm index e586e6f806b..c73ffc72ced 100644 --- a/code/modules/reagents/chem_splash.dm +++ b/code/modules/reagents/chem_splash.dm @@ -25,8 +25,7 @@ for(var/datum/reagents/R in reactants) R.trans_to(splash_holder, R.total_volume, threatscale, 1, 1) total_temp += R.chem_temp - splash_holder.chem_temp = (total_temp/reactants.len) + extra_heat // Average temperature of reagents + extra heat. - splash_holder.handle_reactions() // React them now. + splash_holder.set_reagent_temp((total_temp / reactants.len) + extra_heat) // Average temperature of reagents + extra heat. if(splash_holder.total_volume && affected_range >= 0) //The possible reactions didnt use up all reagents, so we spread it around. var/datum/effect_system/steam_spread/steam = new /datum/effect_system/steam_spread() diff --git a/code/modules/reagents/chemistry/holder.dm b/code/modules/reagents/chemistry/holder.dm index fa2a8d71a9a..426c9ae3a8b 100644 --- a/code/modules/reagents/chemistry/holder.dm +++ b/code/modules/reagents/chemistry/holder.dm @@ -9,7 +9,7 @@ var/const/INGEST = 2 var/total_volume = 0 var/maximum_volume = 100 var/atom/my_atom = null - var/chem_temp = 300 + var/chem_temp = T20C var/list/datum/reagent/addiction_list = new/list() var/flags @@ -166,6 +166,30 @@ var/const/INGEST = 2 handle_reactions() return amount +/datum/reagents/proc/set_reagent_temp(new_temp = T0C, react = TRUE) + chem_temp = new_temp + if(react) + temperature_react() + handle_reactions() + +/datum/reagents/proc/temperature_react() //Calls the temperature reaction procs without changing the temp. + for(var/datum/reagent/current_reagent in reagent_list) + current_reagent.reaction_temperature(chem_temp, 100) + +/datum/reagents/proc/temperature_reagents(exposed_temperature, divisor = 35, change_cap = 15) //This is what you use to change the temp of a reagent holder. + //Do not manually change the reagent unless you know what youre doing. + var/difference = abs(chem_temp - exposed_temperature) + var/change = min(max((difference / divisor), 1), change_cap) + if(exposed_temperature > chem_temp) + chem_temp += change + else if(exposed_temperature < chem_temp) + chem_temp -= change + + chem_temp = max(min(chem_temp, 10000), 0) //Cap for the moment. + temperature_react() + + handle_reactions() + /datum/reagents/proc/trans_id_to(obj/target, reagent, amount=1, preserve_data=1)//Not sure why this proc didn't exist before. It does now! /N if(!target) return @@ -194,8 +218,7 @@ var/const/INGEST = 2 /datum/reagents/proc/metabolize(mob/living/M) if(M) - chem_temp = M.bodytemperature - handle_reactions() + temperature_reagents(M.bodytemperature - 30) // a bitfield filled in by each reagent's `on_mob_life` to find out which states to update var/update_flags = STATUS_UPDATE_NONE @@ -548,14 +571,14 @@ var/const/INGEST = 2 var/amt = list_reagents[r_id] add_reagent(r_id, amt, data) -/datum/reagents/proc/add_reagent(reagent, amount, list/data=null, reagtemp = 300, no_react = 0) +/datum/reagents/proc/add_reagent(reagent, amount, list/data=null, reagtemp = T20C, no_react = 0) if(!isnum(amount)) return 1 update_total() if(total_volume + amount > maximum_volume) amount = (maximum_volume - total_volume) //Doesnt fit in. Make it disappear. Shouldnt happen. Will happen. if(amount <= 0) return 0 - chem_temp = round(((amount * reagtemp) + (total_volume * chem_temp)) / (total_volume + amount)) //equalize with new chems + chem_temp = (chem_temp * total_volume + reagtemp * amount) / (total_volume + amount) //equalize with new chems for(var/A in reagent_list) @@ -567,6 +590,7 @@ var/const/INGEST = 2 my_atom.on_reagent_change() R.on_merge(data) if(!no_react) + temperature_react() handle_reactions() return 0 @@ -585,6 +609,7 @@ var/const/INGEST = 2 if(my_atom) my_atom.on_reagent_change() if(!no_react) + temperature_react() handle_reactions() return 0 else diff --git a/code/modules/reagents/chemistry/machinery/chem_heater.dm b/code/modules/reagents/chemistry/machinery/chem_heater.dm index 1b84afb3d74..ba329f30c0e 100644 --- a/code/modules/reagents/chemistry/machinery/chem_heater.dm +++ b/code/modules/reagents/chemistry/machinery/chem_heater.dm @@ -7,8 +7,7 @@ use_power = IDLE_POWER_USE idle_power_usage = 40 var/obj/item/reagent_containers/beaker = null - var/desired_temp = 300 - var/heater_coefficient = 0.03 + var/desired_temp = T0C var/on = FALSE /obj/machinery/chem_heater/New() @@ -19,34 +18,22 @@ component_parts += new /obj/item/stock_parts/console_screen(null) RefreshParts() -/obj/machinery/chem_heater/upgraded/New() - ..() - component_parts = list() - component_parts += new /obj/item/circuitboard/chem_heater(null) - component_parts += new /obj/item/stock_parts/micro_laser/ultra(null) - component_parts += new /obj/item/stock_parts/console_screen(null) - RefreshParts() - -/obj/machinery/chem_heater/RefreshParts() - heater_coefficient = 0.03 - for(var/obj/item/stock_parts/micro_laser/M in component_parts) - heater_coefficient *= M.rating - /obj/machinery/chem_heater/process() ..() if(stat & NOPOWER) return - var/state_change = 0 + var/state_change = FALSE if(on) if(beaker) - if(beaker.reagents.chem_temp > desired_temp) - beaker.reagents.chem_temp += min(-1, max((desired_temp - beaker.reagents.chem_temp) * heater_coefficient, -15)) - if(beaker.reagents.chem_temp < desired_temp) - beaker.reagents.chem_temp += max(1, min((desired_temp - beaker.reagents.chem_temp) * heater_coefficient, 15)) - beaker.reagents.chem_temp = round(beaker.reagents.chem_temp) //stops stuff like 456.12312312302 - - beaker.reagents.handle_reactions() - state_change = 1 + if(!beaker.reagents.total_volume) + on = FALSE + SSnanoui.update_uis(src) + return + beaker.reagents.temperature_reagents(desired_temp) + beaker.reagents.temperature_reagents(desired_temp) + if(abs(beaker.reagents.chem_temp - desired_temp) <= 3) + on = FALSE + state_change = TRUE if(state_change) SSnanoui.update_uis(src) @@ -54,7 +41,6 @@ /obj/machinery/chem_heater/proc/eject_beaker() if(beaker) beaker.forceMove(get_turf(src)) - beaker.reagents.handle_reactions() beaker = null icon_state = "mixer0b" on = FALSE @@ -111,6 +97,8 @@ return 0 if(href_list["toggle_on"]) + if(!beaker.reagents.total_volume) + return on = !on . = 1 diff --git a/code/modules/reagents/chemistry/reagents.dm b/code/modules/reagents/chemistry/reagents.dm index 7e76217fe15..79c23d8dfad 100644 --- a/code/modules/reagents/chemistry/reagents.dm +++ b/code/modules/reagents/chemistry/reagents.dm @@ -33,6 +33,9 @@ . = ..() holder = null +/datum/reagent/proc/reaction_temperature(exposed_temperature, exposed_volume) //By default we do nothing. + return + /datum/reagent/proc/reaction_mob(mob/living/M, method = TOUCH, volume) //Some reagents transfer on touch, others don't; dependent on if they penetrate the skin or not. if(holder) //for catching rare runtimes if(method == TOUCH && penetrates_skin) diff --git a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm index 857b15330d4..b0dd577db9f 100644 --- a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm +++ b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm @@ -224,8 +224,9 @@ /datum/reagent/cryostylane/on_tick() if(holder.has_reagent("oxygen")) holder.remove_reagent("oxygen", 1) - holder.chem_temp -= 10 - holder.handle_reactions() + holder.remove_reagent("cryostylane", 1) + holder.temperature_reagents(holder.chem_temp - 200) + holder.temperature_reagents(holder.chem_temp - 200) ..() /datum/reagent/cryostylane/reaction_turf(turf/T, volume) @@ -249,8 +250,9 @@ /datum/reagent/pyrosium/on_tick() if(holder.has_reagent("oxygen")) holder.remove_reagent("oxygen", 1) - holder.chem_temp += 10 - holder.handle_reactions() + holder.remove_reagent("pyrosium", 1) + holder.temperature_reagents(holder.chem_temp + 200) + holder.temperature_reagents(holder.chem_temp + 200) ..() /datum/reagent/firefighting_foam diff --git a/code/modules/reagents/chemistry/recipes/drinks.dm b/code/modules/reagents/chemistry/recipes/drinks.dm index c348db060ff..2f3eda996b0 100644 --- a/code/modules/reagents/chemistry/recipes/drinks.dm +++ b/code/modules/reagents/chemistry/recipes/drinks.dm @@ -229,7 +229,7 @@ id = "flamingmoe" result = "flamingmoe" required_reagents = list("vodka" = 1, "gin" = 1, "cognac" = 1, "tequila" = 1, "salglu_solution" = 1) //Close enough - min_temp = 374 //Fire makes it good! + min_temp = T0C + 100 //Fire makes it good! result_amount = 5 mix_sound = 'sound/goonstation/misc/drinkfizz.ogg' mix_message = "The concoction bursts into flame!" @@ -701,7 +701,7 @@ id = "applejack" result = "applejack" required_reagents = list("cider" = 2) - max_temp = 270 + max_temp = T0C result_amount = 1 mix_message = "The drink darkens as the water freezes, leaving the concentrated cider behind." mix_sound = null diff --git a/code/modules/reagents/chemistry/recipes/drugs.dm b/code/modules/reagents/chemistry/recipes/drugs.dm index e44ace8f511..aa0a9c21714 100644 --- a/code/modules/reagents/chemistry/recipes/drugs.dm +++ b/code/modules/reagents/chemistry/recipes/drugs.dm @@ -15,7 +15,7 @@ result_amount = 5 mix_message = "The mixture violently reacts, leaving behind a few crystalline shards." mix_sound = 'sound/goonstation/effects/crystalshatter.ogg' - min_temp = 390 + min_temp = T0C + 100 /datum/chemical_reaction/crank/on_reaction(datum/reagents/holder, created_volume) var/turf/T = get_turf(holder.my_atom) @@ -30,7 +30,7 @@ required_reagents = list("diphenhydramine" = 1, "morphine" = 1, "cleaner" = 1, "potassium" = 1, "phosphorus" = 1, "fuel" = 1) result_amount = 6 mix_message = "The mixture dries into a pale blue powder." - min_temp = 380 + min_temp = T0C + 100 mix_sound = 'sound/goonstation/misc/fuse.ogg' /datum/chemical_reaction/methamphetamine @@ -39,7 +39,7 @@ result = "methamphetamine" required_reagents = list("ephedrine" = 1, "iodine" = 1, "phosphorus" = 1, "hydrogen" = 1) result_amount = 4 - min_temp = 374 + min_temp = T0C + 100 /datum/chemical_reaction/methamphetamine/on_reaction(datum/reagents/holder) var/turf/T = get_turf(holder.my_atom) @@ -57,7 +57,7 @@ result = "bath_salts" required_reagents = list("????" = 1, "saltpetre" = 1, "msg" = 1, "cleaner" = 1, "enzyme" = 1, "mugwort" = 1, "mercury" = 1) result_amount = 6 - min_temp = 374 + min_temp = T0C + 100 mix_message = "Tiny cubic crystals precipitate out of the mixture. Huh." mix_sound = 'sound/goonstation/misc/fuse.ogg' diff --git a/code/modules/reagents/chemistry/recipes/food.dm b/code/modules/reagents/chemistry/recipes/food.dm index ec732bba858..5b5efc105d6 100644 --- a/code/modules/reagents/chemistry/recipes/food.dm +++ b/code/modules/reagents/chemistry/recipes/food.dm @@ -124,7 +124,7 @@ result = "corn_syrup" required_reagents = list("corn_starch" = 1, "sacid" = 1) result_amount = 2 - min_temp = 374 + min_temp = T0C + 100 mix_message = "The mixture forms a viscous, clear fluid!" /datum/chemical_reaction/vhfcs @@ -176,7 +176,7 @@ result = "hydrogenated_soybeanoil" required_reagents = list("soybeanoil" = 1, "hydrogen" = 1) result_amount = 2 - min_temp = 520 + min_temp = T0C + 250 mix_message = "The mixture emits a burnt, oily smell." /datum/chemical_reaction/meatslurry @@ -194,7 +194,7 @@ result = "gravy" required_reagents = list("porktonium" = 1, "corn_starch" = 1, "milk" = 1) result_amount = 3 - min_temp = 374 + min_temp = T0C + 100 mix_message = "The substance thickens and takes on a meaty odor." /datum/chemical_reaction/beff @@ -221,7 +221,7 @@ result = "enzyme" required_reagents = list("vomit" = 1, "sugar" = 1) result_amount = 2 - min_temp = 750 + min_temp = T0C + 480 mix_message = "The mixture emits a horrible smell as you heat up the contents. Luckily, enzymes don't stink." mix_sound = 'sound/goonstation/misc/fuse.ogg' @@ -231,6 +231,6 @@ result = "enzyme" required_reagents = list("green_vomit" = 1, "sugar" = 1) result_amount = 2 - min_temp = 750 + min_temp = T0C + 480 mix_message = "The mixture emits a horrible smell as you heat up the contents. Luckily, enzymes don't stink." mix_sound = 'sound/goonstation/misc/fuse.ogg' diff --git a/code/modules/reagents/chemistry/recipes/medicine.dm b/code/modules/reagents/chemistry/recipes/medicine.dm index 864733f6555..0897de76566 100644 --- a/code/modules/reagents/chemistry/recipes/medicine.dm +++ b/code/modules/reagents/chemistry/recipes/medicine.dm @@ -50,7 +50,7 @@ required_reagents = list("ash" = 1, "sodiumchloride" = 1) result_amount = 2 mix_message = "The mixture yields a fine black powder." - min_temp = 380 + min_temp = T0C + 100 mix_sound = 'sound/goonstation/misc/fuse.ogg' /datum/chemical_reaction/silver_sulfadiazine @@ -92,7 +92,7 @@ result = "calomel" required_reagents = list("mercury" = 1, "chlorine" = 1) result_amount = 2 - min_temp = 374 + min_temp = T0C + 100 mix_message = "Stinging vapors rise from the solution." /datum/chemical_reaction/potass_iodide @@ -135,7 +135,7 @@ result = "perfluorodecalin" required_reagents = list("hydrogen" = 1, "fluorine" = 1, "oil" = 1) result_amount = 3 - min_temp = 370 + min_temp = T0C + 100 mix_message = "The mixture rapidly turns into a dense pink liquid." mix_sound = 'sound/goonstation/misc/drinkfizz.ogg' @@ -195,7 +195,7 @@ result = null required_reagents = list("strange_reagent" = 1, "synthflesh" = 1, "blood" = 1) result_amount = 3 - min_temp = 374 + min_temp = T0C + 100 /datum/chemical_reaction/life/on_reaction(datum/reagents/holder, created_volume) chemical_mob_spawn(holder, 1, "Life") @@ -263,7 +263,7 @@ result = "liquid_solder" required_reagents = list("ethanol" = 1, "copper" = 1, "silver" = 1) result_amount = 3 - min_temp = 370 + min_temp = T0C + 100 mix_message = "The solution gently swirls with a metallic sheen." /datum/chemical_reaction/corazone diff --git a/code/modules/reagents/chemistry/recipes/others.dm b/code/modules/reagents/chemistry/recipes/others.dm index 0259ed89e86..e06dec7de3f 100644 --- a/code/modules/reagents/chemistry/recipes/others.dm +++ b/code/modules/reagents/chemistry/recipes/others.dm @@ -74,7 +74,7 @@ result = "diethylamine" required_reagents = list ("ammonia" = 1, "ethanol" = 1) result_amount = 2 - min_temp = 374 + min_temp = T0C + 100 mix_message = "A horrible smell pours forth from the mixture." /datum/chemical_reaction/space_cleaner @@ -98,7 +98,7 @@ id = "plastic_polymers" result = null required_reagents = list("oil" = 5, "sacid" = 2, "ash" = 3) - min_temp = 374 + min_temp = T0C + 100 result_amount = 1 /datum/chemical_reaction/plastic_polymers/on_reaction(datum/reagents/holder, created_volume) @@ -177,7 +177,7 @@ result = "ash" required_reagents = list("oil" = 1) result_amount = 0.5 - min_temp = 480 + min_temp = T0C + 600 mix_sound = null no_message = 1 @@ -195,7 +195,7 @@ result = null required_reagents = list("nutriment" = 1, "colorful_reagent" = 1, "strange_reagent" = 1, "blood" = 1) result_amount = 3 - min_temp = 374 + min_temp = T0C + 100 /datum/chemical_reaction/corgium/on_reaction(datum/reagents/holder, created_volume) var/location = get_turf(holder.my_atom) @@ -208,7 +208,7 @@ result = null required_reagents = list("egg" = 1, "colorful_reagent" = 1, "chicken_soup" = 1, "strange_reagent" = 1, "blood" = 1) result_amount = 5 - min_temp = 374 + min_temp = T0C + 100 mix_message = "The substance turns an airy sky-blue and foams up into a new shape." /datum/chemical_reaction/flaptonium/on_reaction(datum/reagents/holder, created_volume) @@ -244,7 +244,7 @@ id = "soapification" result = null required_reagents = list("liquidgibs" = 10, "lye" = 10) // requires two scooped gib tiles - min_temp = 374 + min_temp = T0C + 100 result_amount = 1 @@ -257,7 +257,7 @@ id = "candlefication" result = null required_reagents = list("liquidgibs" = 5, "oxygen" = 5) // - min_temp = 374 + min_temp = T0C + 100 result_amount = 1 /datum/chemical_reaction/candlefication/on_reaction(datum/reagents/holder, created_volume) @@ -295,7 +295,7 @@ id = "jestosterone" result = "jestosterone" required_reagents = list("blood" = 1, "sodiumchloride" = 1, "banana" = 1, "lube" = 1, "space_drugs" = 1) //Or one freshly-squeezed clown - min_temp = 374 + min_temp = T0C + 100 result_amount = 5 mix_message = "The substance quickly shifts colour, cycling from red, to yellow, to green, to blue, and finally settles at a vibrant fuchsia." @@ -338,7 +338,7 @@ result = "ice" required_reagents = list("water" = 1) result_amount = 1 - max_temp = 273 + max_temp = T0C mix_message = "Ice forms as the water freezes." mix_sound = null @@ -348,7 +348,7 @@ result = "water" required_reagents = list("ice" = 1) result_amount = 1 - min_temp = 301 // In Space.....ice melts at 82F...don't ask + min_temp = T0C + 29 // In Space.....ice melts at 82F...don't ask mix_message = "Water pools as the ice melts." mix_sound = null diff --git a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm index 362aebfcc10..36225f6924f 100644 --- a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm +++ b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm @@ -80,7 +80,7 @@ result = "clf3" required_reagents = list("chlorine" = 1, "fluorine" = 3) result_amount = 2 - min_temp = 424 + min_temp = T0C + 150 /datum/chemical_reaction/clf3/on_reaction(datum/reagents/holder, created_volume) var/turf/T = get_turf(holder.my_atom) @@ -107,7 +107,7 @@ result = "sorium_vortex" required_reagents = list("sorium" = 1) result_amount = 1 - min_temp = 474 + min_temp = T0C + 200 /datum/chemical_reaction/sorium_vortex/on_reaction(datum/reagents/holder, created_volume) var/turf/simulated/T = get_turf(holder.my_atom) @@ -134,7 +134,7 @@ result = "ldm_vortex" required_reagents = list("liquid_dark_matter" = 1) result_amount = 1 - min_temp = 474 + min_temp = T0C + 200 /datum/chemical_reaction/ldm_vortex/on_reaction(datum/reagents/holder, created_volume) var/turf/simulated/T = get_turf(holder.my_atom) @@ -155,7 +155,7 @@ result = null required_reagents = list("blackpowder" = 1) result_amount = 1 - min_temp = 474 + min_temp = T0C + 200 no_message = 1 mix_sound = null @@ -202,7 +202,7 @@ datum/chemical_reaction/flash_powder id = "flash_powder_flash" result = null required_reagents = list("flash_powder" = 1) - min_temp = 374 + min_temp = T0C + 100 /datum/chemical_reaction/flash_powder_flash/on_reaction(datum/reagents/holder, created_volume) var/location = get_turf(holder.my_atom) @@ -256,7 +256,7 @@ datum/chemical_reaction/flash_powder name = "smoke_powder_smoke" id = "smoke_powder_smoke" required_reagents = list("smoke_powder" = 1) - min_temp = 374 + min_temp = T0C + 100 secondary = 1 result_amount = 1 forbidden_reagents = list("stimulants") @@ -307,7 +307,7 @@ datum/chemical_reaction/flash_powder id = "sonic_powder_deafen" result = null required_reagents = list("sonic_powder" = 1) - min_temp = 374 + min_temp = T0C + 100 /datum/chemical_reaction/sonic_powder_deafen/on_reaction(datum/reagents/holder, created_volume) var/location = get_turf(holder.my_atom) diff --git a/code/modules/reagents/chemistry/recipes/toxins.dm b/code/modules/reagents/chemistry/recipes/toxins.dm index 1531c80542a..54e3ce4fdb8 100644 --- a/code/modules/reagents/chemistry/recipes/toxins.dm +++ b/code/modules/reagents/chemistry/recipes/toxins.dm @@ -4,7 +4,7 @@ result = "formaldehyde" required_reagents = list("ethanol" = 1, "oxygen" = 1, "silver" = 1) result_amount = 3 - min_temp = 420 + min_temp = T0C + 150 mix_message = "Ugh, it smells like the morgue in here." /datum/chemical_reaction/neurotoxin2 @@ -13,7 +13,7 @@ result = "neurotoxin2" required_reagents = list("space_drugs" = 1) result_amount = 1 - min_temp = 674 + min_temp = T0C + 400 mix_sound = null no_message = 1 @@ -23,7 +23,7 @@ result = "cyanide" required_reagents = list("oil" = 1, "ammonia" = 1, "oxygen" = 1) result_amount = 3 - min_temp = 380 + min_temp = T0C + 100 mix_message = "The mixture gives off a faint scent of almonds." mix_sound = 'sound/goonstation/misc/drinkfizz.ogg' @@ -49,7 +49,7 @@ result = "facid" required_reagents = list("sacid" = 1, "fluorine" = 1, "hydrogen" = 1, "potassium" = 1) result_amount = 4 - min_temp = 380 + min_temp = T0C + 100 mix_message = "The mixture deepens to a dark blue, and slowly begins to corrode its container." /datum/chemical_reaction/initropidril @@ -83,7 +83,7 @@ required_reagents = list("chlorine" = 1, "fuel" = 1, "oxygen" = 1, "phosphorus" = 1, "fluorine" = 1, "hydrogen" = 1, "acetone" = 1, "atrazine" = 1) result_amount = 3 mix_message = "The mixture yields a colorless, odorless liquid." - min_temp = 374 + min_temp = T0C + 100 mix_sound = 'sound/goonstation/misc/drinkfizz.ogg' /datum/chemical_reaction/sarin/on_reaction(datum/reagents/holder) @@ -139,7 +139,7 @@ required_reagents = list("plasma" = 1, "silver" = 1, "blackpowder" = 1) result_amount = 3 mix_message = "A jet of sparks flies from the mixture as it merges into a flickering slurry." - min_temp = 400 + min_temp = T0C + 130 mix_sound = null /datum/chemical_reaction/teslium/on_reaction(datum/reagents/holder, created_volume) diff --git a/code/modules/reagents/reagent_containers.dm b/code/modules/reagents/reagent_containers.dm index 6d58e42d539..a350d75a4b4 100644 --- a/code/modules/reagents/reagent_containers.dm +++ b/code/modules/reagents/reagent_containers.dm @@ -44,11 +44,6 @@ R.on_ex_act() ..() -/obj/item/reagent_containers/fire_act() - reagents.chem_temp += 30 - reagents.handle_reactions() - ..() - /obj/item/reagent_containers/attack_self(mob/user) if(has_lid) if(is_open_container()) diff --git a/code/modules/reagents/reagent_containers/glass_containers.dm b/code/modules/reagents/reagent_containers/glass_containers.dm index 23ec5f5cadb..cc866f7a2c7 100644 --- a/code/modules/reagents/reagent_containers/glass_containers.dm +++ b/code/modules/reagents/reagent_containers/glass_containers.dm @@ -124,13 +124,6 @@ /obj/item/reagent_containers/glass/attackby(obj/item/I, mob/user, params) - if(istype(I, /obj/item/clothing/mask/cigarette)) //ciggies are weird - return - if(is_hot(I)) - if(reagents) - reagents.chem_temp += 15 - to_chat(user, "You heat [src] with [I].") - reagents.handle_reactions() if(istype(I, /obj/item/pen) || istype(I, /obj/item/flashlight/pen)) var/tmp_label = sanitize(input(user, "Enter a label for [name]","Label",label_text)) if(length(tmp_label) > MAX_NAME_LEN) @@ -210,8 +203,7 @@ /obj/item/reagent_containers/glass/beaker/proc/heat_beaker() if(reagents) - reagents.chem_temp += 30 - reagents.handle_reactions() + reagents.temperature_reagents(4000) /obj/item/reagent_containers/glass/beaker/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/assembly_holder) && can_assembly) diff --git a/code/modules/reagents/reagent_dispenser.dm b/code/modules/reagents/reagent_dispenser.dm index da9f408a7c3..d7fa514d29d 100644 --- a/code/modules/reagents/reagent_dispenser.dm +++ b/code/modules/reagents/reagent_dispenser.dm @@ -99,7 +99,8 @@ /obj/structure/reagent_dispensers/fueltank/ex_act() boom() -/obj/structure/reagent_dispensers/fueltank/fire_act() +/obj/structure/reagent_dispensers/fueltank/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE) + ..() boom() /obj/structure/reagent_dispensers/fueltank/tesla_act() From cc1b49eed6da060dc346438a437724fff0316e95 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Mon, 18 Mar 2019 23:19:13 -0400 Subject: [PATCH 02/12] fix --- code/game/objects/items/weapons/tools.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/items/weapons/tools.dm b/code/game/objects/items/weapons/tools.dm index e90a7bb4b6d..7fb2a50e65a 100644 --- a/code/game/objects/items/weapons/tools.dm +++ b/code/game/objects/items/weapons/tools.dm @@ -469,7 +469,7 @@ /obj/item/weldingtool/afterattack(atom/O, mob/user, proximity) if(!proximity) return - + ..() if(welding) remove_fuel(1) var/turf/location = get_turf(user) From e98f1b36e25f1062639ab95bf4328e779df5fddd Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Tue, 19 Mar 2019 00:15:59 -0400 Subject: [PATCH 03/12] this for now --- code/modules/reagents/chemistry/holder.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/reagents/chemistry/holder.dm b/code/modules/reagents/chemistry/holder.dm index 426c9ae3a8b..9586dec9bc9 100644 --- a/code/modules/reagents/chemistry/holder.dm +++ b/code/modules/reagents/chemistry/holder.dm @@ -218,7 +218,7 @@ var/const/INGEST = 2 /datum/reagents/proc/metabolize(mob/living/M) if(M) - temperature_reagents(M.bodytemperature - 30) + set_reagent_temp(M.bodytemperature) // a bitfield filled in by each reagent's `on_mob_life` to find out which states to update var/update_flags = STATUS_UPDATE_NONE From de09634df161f4f6e42c656aa19facb432586075 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Tue, 19 Mar 2019 01:53:30 -0400 Subject: [PATCH 04/12] fixes black powder --- code/modules/reagents/chemistry/recipes/pyrotechnics.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm index 36225f6924f..8248a88b349 100644 --- a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm +++ b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm @@ -162,16 +162,16 @@ /datum/chemical_reaction/blackpowder_explosion/on_reaction(datum/reagents/holder, created_volume) var/location = get_turf(holder.my_atom) do_sparks(2, 1, location) - sleep(rand(20,30)) - blackpowder_detonate(holder, created_volume) + spawn(rand(5, 15)) + blackpowder_detonate(holder, created_volume) /proc/blackpowder_detonate(datum/reagents/holder, created_volume) - var/turf/simulated/T = get_turf(holder.my_atom) + var/turf/T = get_turf(holder.my_atom) var/ex_severe = round(created_volume / 100) var/ex_heavy = round(created_volume / 42) var/ex_light = round(created_volume / 20) var/ex_flash = round(created_volume / 8) - explosion(T,ex_severe,ex_heavy,ex_light,ex_flash, 1) + explosion(T, ex_severe, ex_heavy,ex_light, ex_flash, 1) // If this black powder is in a decal, remove the decal, because it just exploded if(istype(holder.my_atom, /obj/effect/decal/cleanable/dirt/blackpowder)) spawn(0) From eedc8afa8e9d7256162730997fb294a4373aa973 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Tue, 19 Mar 2019 14:58:53 -0400 Subject: [PATCH 05/12] reagents mob temp --- .../mob/living/carbon/human/human_defense.dm | 9 ++++++ code/modules/reagents/chemistry/holder.dm | 29 +++++++++++++++++++ .../chemistry/machinery/chem_heater.dm | 6 ++-- 3 files changed, 41 insertions(+), 3 deletions(-) diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index 965a2c81ab2..84764bfddaa 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -513,3 +513,12 @@ emp_act return TRUE if(check_mask && wear_mask && (wear_mask.flags_cover & MASKCOVERSMOUTH)) return TRUE + +/mob/living/carbon/human/proc/reagent_safety_check(hot = TRUE) + if(wear_mask) + to_chat(src, "Your [wear_mask.name] protects you from the [hot ? "hot" : "cold"] liquid!") + return FALSE + if(head) + to_chat(src, "Your [head.name] protects you from the [hot ? "hot" : "cold"] liquid!") + return FALSE + return TRUE \ No newline at end of file diff --git a/code/modules/reagents/chemistry/holder.dm b/code/modules/reagents/chemistry/holder.dm index 9586dec9bc9..95dece3ad75 100644 --- a/code/modules/reagents/chemistry/holder.dm +++ b/code/modules/reagents/chemistry/holder.dm @@ -554,6 +554,35 @@ var/const/INGEST = 2 react_type = "OBJ" else return + + if(react_type == "LIVING" && ishuman(A)) + var/mob/living/carbon/human/H = A + if(method == TOUCH) + var/obj/item/organ/external/head/affecting = H.get_organ("head") + if(affecting) + if(chem_temp > H.dna.species.heat_level_1) + if(H.reagent_safety_check()) + to_chat(H, "You are scalded by the hot chemicals!") + affecting.receive_damage(0, round(log(chem_temp / 50) * 10)) + H.emote("scream") + H.adjust_bodytemperature(min(max((chem_temp - T0C) - 20, 5), 500)) + else if(chem_temp < H.dna.species.cold_level_1) + if(H.reagent_safety_check(FALSE)) + to_chat(H, "You are frostbitten by the freezing cold chemicals!") + affecting.receive_damage(0, round(log(T0C - chem_temp / 50) * 10)) + H.emote("scream") + H.adjust_bodytemperature(- min(max(T0C - chem_temp - 20, 5), 500)) + + if(method == INGEST) + if(chem_temp > H.dna.species.heat_level_1) + to_chat(H, "You scald yourself trying to consume the boiling hot substance!") + H.adjustFireLoss(7) + H.adjust_bodytemperature(min(max((chem_temp - T0C) - 20, 5), 700)) + else if(chem_temp < H.dna.species.cold_level_1) + to_chat(H, "You frostburn yourself trying to consume the freezing cold substance!") + H.adjustFireLoss(7) + H.adjust_bodytemperature(- min(max((T0C - chem_temp) - 20, 5), 700)) + for(var/datum/reagent/R in reagent_list) switch(react_type) if("LIVING") diff --git a/code/modules/reagents/chemistry/machinery/chem_heater.dm b/code/modules/reagents/chemistry/machinery/chem_heater.dm index ba329f30c0e..2db474b39c4 100644 --- a/code/modules/reagents/chemistry/machinery/chem_heater.dm +++ b/code/modules/reagents/chemistry/machinery/chem_heater.dm @@ -94,11 +94,11 @@ /obj/machinery/chem_heater/Topic(href, href_list) if(..()) - return 0 + return FALSE if(href_list["toggle_on"]) if(!beaker.reagents.total_volume) - return + return FALSE on = !on . = 1 @@ -110,7 +110,7 @@ var/target = input("Please input the target temperature", name) as num desired_temp = Clamp(target, 0, 1000) else - return 0 + return FALSE . = 1 if(href_list["eject_beaker"]) From 122c17a0065a5ca70b431c8cc8d6a21997936ca2 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Tue, 19 Mar 2019 18:23:04 -0400 Subject: [PATCH 06/12] oh no fox lost it --- code/LINDA/LINDA_fire.dm | 141 +++++++++++++++++- code/__HELPERS/game.dm | 13 ++ code/__HELPERS/unsorted.dm | 17 +++ code/_onclick/item_attack.dm | 7 +- code/game/turfs/simulated/floor.dm | 3 + code/game/turfs/simulated/walls.dm | 22 +-- code/game/turfs/simulated/walls_mineral.dm | 3 + code/game/turfs/turf.dm | 3 + .../reagents/chemistry/reagents/misc.dm | 12 ++ .../chemistry/reagents/paradise_pop.dm | 4 +- .../chemistry/reagents/pyrotechnic.dm | 113 +++++++++++--- code/modules/reagents/chemistry/recipes.dm | 23 ++- .../reagents/chemistry/recipes/drugs.dm | 5 +- .../reagents/chemistry/recipes/others.dm | 10 -- .../chemistry/recipes/pyrotechnics.dm | 12 +- code/modules/reagents/reagent_dispenser.dm | 24 ++- 16 files changed, 323 insertions(+), 89 deletions(-) diff --git a/code/LINDA/LINDA_fire.dm b/code/LINDA/LINDA_fire.dm index 13e20785d33..dad05f32c99 100644 --- a/code/LINDA/LINDA_fire.dm +++ b/code/LINDA/LINDA_fire.dm @@ -69,21 +69,24 @@ /obj/effect/hotspot/proc/perform_exposure() var/turf/simulated/location = loc - if(!istype(location) || !(location.air)) return 0 + if(!istype(location) || !(location.air)) + return FALSE - if(volume > CELL_VOLUME*0.95) bypassing = 1 - else bypassing = 0 + if(volume > CELL_VOLUME * 0.95) + bypassing = TRUE + else + bypassing = FALSE if(bypassing) if(!just_spawned) - volume = location.air.fuel_burnt*FIRE_GROWTH_RATE + volume = location.air.fuel_burnt * FIRE_GROWTH_RATE temperature = location.air.temperature else - var/datum/gas_mixture/affected = location.air.remove_ratio(volume/location.air.volume) + var/datum/gas_mixture/affected = location.air.remove_ratio(volume / location.air.volume) affected.temperature = temperature affected.react() temperature = affected.temperature - volume = affected.fuel_burnt*FIRE_GROWTH_RATE + volume = affected.fuel_burnt * FIRE_GROWTH_RATE location.assume_air(affected) for(var/A in loc) @@ -93,7 +96,7 @@ color = heat2color(temperature) set_light(l_color = color) - return 0 + return FALSE /obj/effect/hotspot/process() @@ -186,3 +189,127 @@ ..() if(isliving(L)) L.fire_act() + +/proc/fireflash(atom/center, radius, temp) + if(!temp) + temp = rand(2800, 3200) + for(var/turf/T in view(radius, get_turf(center))) + if(istype(T, /turf/space)) + continue + if(locate(/obj/effect/hotspot) in T) + continue + if(!can_line(get_turf(center), T, radius + 1)) + continue + + var/obj/effect/hotspot/H = new(T) + H.temperature = temp + H.volume = 400 + if(istype(T, /turf/simulated)) + var/turf/simulated/S = T + S.active_hotspot = H + + T.hotspot_expose(H.temperature, H.volume) + + if(istype(T, /turf/simulated/floor)) + var/turf/simulated/floor/F = T + F.burn_tile() + + for(var/mob/living/L in T) + L.adjust_fire_stacks(3) + L.IgniteMob() + L.bodytemperature = max(temp / 3, L.bodytemperature) + +/proc/fireflash_s(atom/center, radius, temp, falloff) + if(temp < T0C + 60) + return list() + var/list/open = list() + var/list/affected = list() + var/list/closed = list() + var/turf/Ce = get_turf(center) + var/max_dist = radius + if(falloff) + max_dist = min((temp - (T0C + 60)) / falloff, radius) + open[Ce] = 0 + while(open.len) + var/turf/T = open[1] + var/dist = open[T] + open -= T + closed += T + + if(isspaceturf(T)) + continue + if(dist > max_dist) + continue + if(!ff_cansee(Ce, T)) + continue + + var/obj/effect/hotspot/existing_hotspot = locate(/obj/effect/hotspot) in T + var/prev_temp = 0 + var/need_expose = 0 + var/expose_temp = 0 + if(!existing_hotspot) + var/obj/effect/hotspot/H = new(T) + need_expose = TRUE + H.temperature = temp - dist * falloff + expose_temp = H.temperature + H.volume = 400 + if(istype(T, /turf/simulated)) + var/turf/simulated/S = T + S.active_hotspot = H + existing_hotspot = H + + else if(existing_hotspot.temperature < temp - dist * falloff) + expose_temp = (temp - dist * falloff) - existing_hotspot.temperature + prev_temp = existing_hotspot.temperature + if(expose_temp > prev_temp * 3) + need_expose = TRUE + existing_hotspot.temperature = temp - dist * falloff + + affected[T] = existing_hotspot.temperature + if(need_expose && expose_temp) + T.hotspot_expose(expose_temp, existing_hotspot.volume) + if(istype(T, /turf/simulated/floor)) + var/turf/simulated/floor/F = T + F.burn_tile() + for(var/mob/living/L in T) + L.adjust_fire_stacks(3) + L.bodytemperature = (2 * L.bodytemperature + temp) / 3 + + if(T.density) + continue + for(var/obj/O in T) + if(O.density) + continue + if(dist == max_dist) + continue + + for(var/dir in cardinal) + var/turf/link = get_step(T, dir) + if (!link) + continue + var/dx = link.x - Ce.x + var/dy = link.y - Ce.y + var/target_dist = max((dist + 1 + sqrt(dx * dx + dy * dy)) / 2, dist) + if(!(link in closed)) + if(link in open) + if(open[link] > target_dist) + open[link] = target_dist + else + open[link] = target_dist + + return affected + +/proc/fireflash_sm(atom/center, radius, temp, falloff, capped = TRUE, bypass_rng = FALSE) + var/list/affected = fireflash_s(center, radius, temp, falloff) + for(var/turf/simulated/T in affected) + var/mytemp = affected[T] + var/melt = 1643.15 // default steel melting point + var/divisor = melt + if(mytemp >= melt * 2) + var/chance = mytemp / divisor + if(capped) + chance = min(chance, 30) + if(prob(chance) || bypass_rng) + T.visible_message("[T] melts!") + T.burn_down() + return affected \ No newline at end of file diff --git a/code/__HELPERS/game.dm b/code/__HELPERS/game.dm index 79b7da3c10c..c7c3bbf5256 100644 --- a/code/__HELPERS/game.dm +++ b/code/__HELPERS/game.dm @@ -74,6 +74,19 @@ //turfs += centerturf return atoms +/proc/ff_cansee(atom/A, atom/B) + var/AT = get_turf(A) + var/BT = get_turf(B) + if(AT == BT) + return 1 + var/list/line = getline(A, B) + for(var/turf/T in line) + if(T == AT || T == BT) + break + if(T.density) + return FALSE + return TRUE + /proc/get_dist_euclidian(atom/Loc1 as turf|mob|obj,atom/Loc2 as turf|mob|obj) var/dx = Loc1.x - Loc2.x var/dy = Loc1.y - Loc2.y diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index a22c4cf3f99..287de3fb424 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -216,6 +216,23 @@ Turf and target are seperate in case you want to teleport some distance from a t line+=locate(px,py,M.z) return line +//Same as the thing below just for density and without support for atoms. +/proc/can_line(atom/source, atom/target, length = 5) + var/turf/current = get_turf(source) + var/turf/target_turf = get_turf(target) + var/steps = 0 + + while(current != target_turf) + if(steps > length) + return FALSE + if(!current) + return FALSE + if(current.density) + return FALSE + current = get_step_towards(current, target_turf) + steps++ + return TRUE + //Returns whether or not a player is a guest using their ckey as an input /proc/IsGuestKey(key) if(findtext(key, "Guest-", 1, 7) != 1) //was findtextEx diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index d47bc134774..47036da9cf8 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -12,6 +12,9 @@ return /obj/item/proc/pre_attackby(atom/A, mob/living/user, params) //do stuff before attackby! + if(is_hot(src) && A.reagents && !ismob(A)) + to_chat(user, "You heat [A] with [src].") + A.reagents.temperature_reagents(is_hot(src)) return TRUE //return FALSE to avoid calling attackby after this proc does stuff // No comment @@ -123,9 +126,7 @@ // Proximity_flag is 1 if this afterattack was called on something adjacent, in your square, or on your person. // Click parameters is the params string from byond Click() code, see that documentation. /obj/item/proc/afterattack(atom/target, mob/user, proximity_flag, click_parameters) - if(is_hot(src) && target.reagents && !ismob(target) && proximity_flag) - to_chat(user, "You heat [target].") - target.reagents.temperature_reagents(is_hot(src)) + return /obj/item/proc/get_clamped_volume() if(w_class) diff --git a/code/game/turfs/simulated/floor.dm b/code/game/turfs/simulated/floor.dm index d26a24b39a2..6b3dc1e93ff 100644 --- a/code/game/turfs/simulated/floor.dm +++ b/code/game/turfs/simulated/floor.dm @@ -79,6 +79,9 @@ var/list/icons_to_ignore_at_floor_init = list("damaged1","damaged2","damaged3"," src.hotspot_expose(1000,CELL_VOLUME) return +/turf/simulated/floor/burn_down() + ex_act(2) + /turf/simulated/floor/is_shielded() for(var/obj/structure/A in contents) if(A.level == 3) diff --git a/code/game/turfs/simulated/walls.dm b/code/game/turfs/simulated/walls.dm index 4c855ac1f15..6fddc40dfa9 100644 --- a/code/game/turfs/simulated/walls.dm +++ b/code/game/turfs/simulated/walls.dm @@ -201,6 +201,11 @@ for(var/i=0, i T0C + 600) + var/turf/T = get_turf(holder.my_atom) + holder.my_atom.visible_message("The oil burns!") + fireflash(T, min(max(0, volume / 40), 8)) + var/datum/effect_system/smoke_spread/bad/BS = new + BS.set_up(1, 0, T) + BS.start() + if(holder) + holder.add_reagent("ash", round(volume * 0.5)) + holder.del_reagent(id) + /datum/reagent/oil/reaction_turf(turf/T, volume) if(volume >= 3 && !isspaceturf(T) && !locate(/obj/effect/decal/cleanable/blood/oil) in T) new /obj/effect/decal/cleanable/blood/oil(T) diff --git a/code/modules/reagents/chemistry/reagents/paradise_pop.dm b/code/modules/reagents/chemistry/reagents/paradise_pop.dm index 08f01bdd381..204848e1fe9 100644 --- a/code/modules/reagents/chemistry/reagents/paradise_pop.dm +++ b/code/modules/reagents/chemistry/reagents/paradise_pop.dm @@ -29,7 +29,7 @@ /datum/reagent/consumable/drink/apple_pocalypse/on_mob_life(mob/living/M) if(prob(1)) var/turf/simulated/T = get_turf(M) - goonchem_vortex(T, 0, 2, 1) + goonchem_vortex(T, 1, 0) to_chat(M, "You briefly feel super-massive, like a black hole. Probably just your imagination...") ..() @@ -119,7 +119,7 @@ /datum/reagent/consumable/drink/grape_granade/on_mob_life(mob/living/M) if(prob(1)) var/turf/simulated/T = get_turf(M) - goonchem_vortex(T, 1, 1, 2) + goonchem_vortex(T, 0, 0) M.emote("burp") to_chat(M, "You feel ready to burst! Oh wait, just a burp...") else if(prob(25)) diff --git a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm index b0dd577db9f..7761772a44c 100644 --- a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm +++ b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm @@ -8,6 +8,43 @@ drink_name = "Glass of welder fuel" drink_desc = "Unless you are an industrial tool, this is probably not safe for consumption." taste_message = "mistakes" + var/max_radius = 7 + var/min_radius = 0 + var/volume_radius_modifier = -0.15 + var/volume_radius_multiplier = 0.09 + var/explosion_threshold = 100 + var/min_explosion_radius = 0 + var/max_explosion_radius = 4 + var/volume_explosion_radius_multiplier = 0.005 + var/volume_explosion_radius_modifier = 0 + var/combustion_temp = T0C + 200 + +/datum/reagent/fuel/reaction_temperature(exposed_temperature, exposed_volume) + if(exposed_temperature > combustion_temp) + if(volume < 1) + if(holder) + holder.del_reagent(id) + return + var/turf/T = get_turf(holder.my_atom) + var/radius = min(max(min_radius, volume * volume_radius_multiplier + volume_radius_modifier), max_radius) + fireflash_sm(T, radius, 2200 + radius * 250, radius * 50) + if(holder && volume >= explosion_threshold) + if(holder.my_atom) + holder.my_atom.visible_message("[holder.my_atom] explodes!") + message_admins("Fuel explosion ([holder.my_atom], reagent type: [id]) at [COORD(holder.my_atom.loc)]. Last touched by: [holder.my_atom.fingerprintslast ? "[holder.my_atom.fingerprintslast]" : "*null*"].") + log_game("Fuel explosion ([holder.my_atom], reagent type: [id]) at [COORD(holder.my_atom.loc)]. Last touched by: [holder.my_atom.fingerprintslast ? "[holder.my_atom.fingerprintslast]" : "*null*"].") + holder.my_atom.investigate_log("A fuel explosion, last touched by [holder.my_atom.fingerprintslast ? "[holder.my_atom.fingerprintslast]" : "*null*"], triggered at [COORD(holder.my_atom.loc)].", INVESTIGATE_BOMB) + var/boomrange = min(max(min_explosion_radius, round(volume * volume_explosion_radius_multiplier + volume_explosion_radius_modifier)), max_explosion_radius) + explosion(T, -1, -1, boomrange, 1) + if(holder) + holder.del_reagent(id) + +/datum/reagent/fuel/reaction_turf(turf/T, volume) //Don't spill the fuel, or you'll regret it + if(isspaceturf(T)) + return + if(!T.reagents) + T.create_reagents(50) + T.reagents.add_reagent("fuel", volume) /datum/reagent/fuel/reaction_mob(mob/living/M, method=TOUCH, volume)//Splashing people with welding fuel to make them easy to ignite! if(method == TOUCH) @@ -23,6 +60,12 @@ color = "#7A2B94" taste_message = "corporate assets going to waste" +/datum/reagent/plasma/reaction_temperature(exposed_temperature, exposed_volume) + if(exposed_temperature >= T0C + 100) + fireflash(get_turf(holder.my_atom), min(max(0, volume / 10), 8)) + if(holder) + holder.del_reagent(id) + /datum/reagent/plasma/on_mob_life(mob/living/M) var/update_flags = STATUS_UPDATE_NONE update_flags |= M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, FALSE) @@ -48,11 +91,27 @@ process_flags = ORGANIC | SYNTHETIC taste_message = "rust" -/datum/reagent/thermite/reaction_turf(turf/simulated/wall/W, volume) - if(volume >= 5 && istype(W)) - W.thermite = 1 - W.overlays.Cut() - W.overlays = image('icons/effects/effects.dmi', icon_state = "thermite") +/datum/reagent/thermite/reaction_temperature(exposed_temperature, exposed_volume) + var/turf/simulated/S = holder.my_atom + if(!istype(S)) + return + + if(exposed_temperature >= T0C + 100) + var/datum/reagents/Holder = holder + var/Id = id + var/Volume = volume + Holder.del_reagent(Id) + fireflash_sm(S, 0, rand(20000, 25000) + Volume * 2500, 0, 0, 1) + +/datum/reagent/thermite/reaction_turf(turf/simulated/S, volume) + if(istype(S)) + if(!S.reagents) + S.create_reagents(volume) + S.reagents.add_reagent("thermite", volume) + S.overlays.Cut() + S.overlays = image('icons/effects/effects.dmi', icon_state = "thermite") + if(S.active_hotspot) + S.reagents.temperature_reagents(S.active_hotspot.temperature, S.active_hotspot.volume, 10, 300) /datum/reagent/glycerol name = "Glycerol" @@ -87,21 +146,11 @@ update_flags |= M.adjustFireLoss(burndmg, FALSE) return ..() | update_flags -/datum/reagent/clf3/reaction_turf(turf/simulated/T, volume) - if(prob(1) && istype(T, /turf/simulated/floor/plating)) - var/turf/simulated/floor/plating/F = T - F.ChangeTurf(/turf/space) - if(istype(T, /turf/simulated/floor)) - var/turf/simulated/floor/F = T - if(prob(volume/10)) - F.make_plating() - if(istype(F, /turf/simulated/floor)) - new /obj/effect/hotspot(F) - if(prob(volume/10) && istype(T, /turf/simulated/wall)) - var/turf/simulated/wall/W = T - W.ChangeTurf(/turf/simulated/floor) - if(istype(T, /turf/simulated/shuttle)) - new /obj/effect/hotspot(T) +/datum/reagent/clf3/reaction_turf(turf/T, volume) + if(volume < 3) + return + var/radius = min((volume - 3) * 0.15, 3) + fireflash_sm(T, radius, 4500 + volume * 500, 350) /datum/reagent/clf3/reaction_mob(mob/living/M, method=TOUCH, volume) if(method == TOUCH) @@ -116,6 +165,15 @@ reagent_state = LIQUID color = "#FFA500" +/datum/reagent/sorium/reaction_turf(turf/T, volume) // oh no + if(prob(75)) + return + if(isspaceturf(T)) + return + if(!T.reagents) + T.create_reagents(50) + T.reagents.add_reagent("sorium", 5) + /datum/reagent/sorium_vortex name = "sorium_vortex" id = "sorium_vortex" @@ -130,6 +188,15 @@ color = "#800080" taste_message = "the end of the world" +/datum/reagent/liquid_dark_matter/reaction_turf(turf/T, volume) //Oh gosh, why + if(prob(75)) + return + if(isspaceturf(T)) + return + if(!T.reagents) + T.create_reagents(50) + T.reagents.add_reagent("liquid_dark_matter", 5) + /datum/reagent/ldm_vortex name = "LDM Vortex" id = "ldm_vortex" @@ -292,6 +359,12 @@ color = "#500064" // rgb: 80, 0, 100 taste_message = "corporate assets going to waste" +/datum/reagent/plasma_dust/reaction_temperature(exposed_temperature, exposed_volume) + if(exposed_temperature >= T0C + 100) + fireflash(get_turf(holder.my_atom), min(max(0, volume / 10), 8)) + if(holder) + holder.del_reagent(id) + /datum/reagent/plasma_dust/on_mob_life(mob/living/M) var/update_flags = STATUS_UPDATE_NONE update_flags |= M.adjustToxLoss(3, FALSE) diff --git a/code/modules/reagents/chemistry/recipes.dm b/code/modules/reagents/chemistry/recipes.dm index 3464b145f6a..78f46884273 100644 --- a/code/modules/reagents/chemistry/recipes.dm +++ b/code/modules/reagents/chemistry/recipes.dm @@ -65,17 +65,16 @@ var/list/chemical_mob_spawn_nicecritters = list() // and possible friendly mobs for(var/j = 1, j <= rand(1, 3), j++) step(C, pick(NORTH,SOUTH,EAST,WEST)) -/proc/goonchem_vortex(turf/simulated/T, setting_type, range, pull_times) - for(var/atom/movable/X in orange(range, T)) +/proc/goonchem_vortex(turf/T, setting_type, volume) + if(setting_type) + playsound(T, 'sound/effects/whoosh.ogg', 25, 1) //credit to Robinhood76 of Freesound.org for this. + else + playsound(T, 'sound/effects/bang.ogg', 25, 1) + for(var/atom/movable/X in view(2 + setting_type + (volume > 30 ? 1 : 0), T)) if(istype(X, /obj/effect)) continue //stop pulling smoke and hotspots please - if(istype(X, /atom/movable)) - if((X) && !X.anchored && X.move_resist <= MOVE_FORCE_DEFAULT) - if(setting_type) - playsound(T, 'sound/effects/bang.ogg', 25, 1) - for(var/i = 0, i < pull_times, i++) - step_away(X,T) - else - playsound(T, 'sound/effects/whoosh.ogg', 25, 1) //credit to Robinhood76 of Freesound.org for this. - for(var/i = 0, i < pull_times, i++) - step_towards(X,T) \ No newline at end of file + if(X && !X.anchored && X.move_resist <= MOVE_FORCE_DEFAULT) + if(setting_type) + X.throw_at(T, 20 + round(volume * 2), 1 + round(volume / 10)) + else + X.throw_at(get_edge_target_turf(T, get_dir(T, X)), 20 + round(volume * 2), 1 + round(volume / 10)) \ No newline at end of file diff --git a/code/modules/reagents/chemistry/recipes/drugs.dm b/code/modules/reagents/chemistry/recipes/drugs.dm index aa0a9c21714..d2499a06c54 100644 --- a/code/modules/reagents/chemistry/recipes/drugs.dm +++ b/code/modules/reagents/chemistry/recipes/drugs.dm @@ -19,9 +19,8 @@ /datum/chemical_reaction/crank/on_reaction(datum/reagents/holder, created_volume) var/turf/T = get_turf(holder.my_atom) - for(var/turf/turf in range(1,T)) - new /obj/effect/hotspot(turf) - explosion(T,0,0,2) + fireflash(holder.my_atom, 1) + explosion(T, 0, 0, 2) /datum/chemical_reaction/krokodil name = "Krokodil" diff --git a/code/modules/reagents/chemistry/recipes/others.dm b/code/modules/reagents/chemistry/recipes/others.dm index e06dec7de3f..c40c1213793 100644 --- a/code/modules/reagents/chemistry/recipes/others.dm +++ b/code/modules/reagents/chemistry/recipes/others.dm @@ -171,16 +171,6 @@ mix_message = "The mixture bubbles and gives off an unpleasant medicinal odor." mix_sound = 'sound/goonstation/misc/drinkfizz.ogg' -/datum/chemical_reaction/ash - name = "Ash" - id = "ash" - result = "ash" - required_reagents = list("oil" = 1) - result_amount = 0.5 - min_temp = T0C + 600 - mix_sound = null - no_message = 1 - /datum/chemical_reaction/colorful_reagent name = "colorful_reagent" id = "colorful_reagent" diff --git a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm index 8248a88b349..6c0c1566414 100644 --- a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm +++ b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm @@ -83,9 +83,7 @@ min_temp = T0C + 150 /datum/chemical_reaction/clf3/on_reaction(datum/reagents/holder, created_volume) - var/turf/T = get_turf(holder.my_atom) - for(var/turf/turf in range(1,T)) - new /obj/effect/hotspot(turf) + fireflash(holder.my_atom, 1, 7000) /datum/chemical_reaction/sorium name = "Sorium" @@ -98,7 +96,7 @@ if(holder.has_reagent("stabilizing_agent")) return var/turf/simulated/T = get_turf(holder.my_atom) - goonchem_vortex(T, 1, min(10, created_volume), min(11, created_volume + 1)) + goonchem_vortex(T, 0, created_volume) holder.remove_reagent("sorium", created_volume) /datum/chemical_reaction/sorium_vortex @@ -111,7 +109,7 @@ /datum/chemical_reaction/sorium_vortex/on_reaction(datum/reagents/holder, created_volume) var/turf/simulated/T = get_turf(holder.my_atom) - goonchem_vortex(T, 1, min(10, created_volume), min(11, created_volume + 1)) + goonchem_vortex(T, 0, created_volume) holder.remove_reagent("sorium_vortex", created_volume) /datum/chemical_reaction/liquid_dark_matter @@ -125,7 +123,7 @@ if(holder.has_reagent("stabilizing_agent")) return var/turf/simulated/T = get_turf(holder.my_atom) - goonchem_vortex(T, 0, min(10, created_volume), min(11, created_volume + 1)) + goonchem_vortex(T, 1, created_volume) holder.remove_reagent("liquid_dark_matter", created_volume) /datum/chemical_reaction/ldm_vortex @@ -138,7 +136,7 @@ /datum/chemical_reaction/ldm_vortex/on_reaction(datum/reagents/holder, created_volume) var/turf/simulated/T = get_turf(holder.my_atom) - goonchem_vortex(T, 0, min(10, created_volume), min(11, created_volume + 1)) + goonchem_vortex(T, 1, created_volume) holder.remove_reagent("ldm_vortex", created_volume) /datum/chemical_reaction/blackpowder diff --git a/code/modules/reagents/reagent_dispenser.dm b/code/modules/reagents/reagent_dispenser.dm index d7fa514d29d..098708bde57 100644 --- a/code/modules/reagents/reagent_dispenser.dm +++ b/code/modules/reagents/reagent_dispenser.dm @@ -22,6 +22,12 @@ reagents.add_reagent(reagent_id, tank_volume) ..() +/obj/structure/reagent_dispensers/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() + if(reagents) + for(var/i in 1 to 8) + reagents.temperature_reagents(exposed_temperature, exposed_volume) + /obj/structure/reagent_dispensers/proc/boom() visible_message("[src] ruptures!") chem_splash(loc, 5, list(reagents)) @@ -68,6 +74,7 @@ desc = "A tank full of industrial welding fuel. Do not consume." icon_state = "fuel" reagent_id = "fuel" + tank_volume = 4000 var/obj/item/assembly_holder/rig = null var/accepts_rig = 1 @@ -85,13 +92,13 @@ boom() /obj/structure/reagent_dispensers/fueltank/boom(var/rigtrigger = FALSE) // Prevent case where someone who rigged the tank is blamed for the explosion when the rig isn't what triggered the explosion - if(reagents.has_reagent("fuel")) - if(rigtrigger == TRUE) // If the explosion is triggered by an assembly holder - message_admins("A fueltank, last rigged by [lastrigger], exploded at [COORD(loc)]") // Then admin is informed of the last person who rigged the fuel tank - log_game("A fueltank, last rigged by [lastrigger], exploded at [COORD(loc)]") - investigate_log("A fueltank, last rigged by [lastrigger], exploded at [COORD(loc)]", INVESTIGATE_BOMB) - explosion(loc, 0, 1, 5, 7, 10, flame_range = 5) - qdel(src) + if(rigtrigger == TRUE) // If the explosion is triggered by an assembly holder + message_admins("A fueltank, last rigged by [lastrigger], was triggered at [COORD(loc)]") // Then admin is informed of the last person who rigged the fuel tank + log_game("A fueltank, last rigged by [lastrigger], triggered at [COORD(loc)]") + investigate_log("A fueltank, last rigged by [lastrigger], triggered at [COORD(loc)]", INVESTIGATE_BOMB) + if(reagents) + reagents.set_reagent_temp(1000) //uh-oh + qdel(src) /obj/structure/reagent_dispensers/fueltank/blob_act() boom() @@ -168,7 +175,7 @@ investigate_log("[key_name(user)] triggered a fueltank explosion at [COORD(loc)]", INVESTIGATE_BOMB) boom() else - ..() + return ..() /obj/structure/reagent_dispensers/fueltank/Move() ..() @@ -296,3 +303,4 @@ anchored = 1 density = 0 accepts_rig = 0 + tank_volume = 1000 From 23954aece6496ee4d944cf1a0f3ea49dbf706b40 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Wed, 20 Mar 2019 00:19:12 -0400 Subject: [PATCH 07/12] that's a lot of fire --- .../reagents/chemistry/reagents/alcohol.dm | 4 +- .../chemistry/reagents/pyrotechnic.dm | 163 ++++++++++++------ .../reagents/chemistry/reagents/water.dm | 3 +- .../chemistry/recipes/pyrotechnics.dm | 56 +++--- 4 files changed, 147 insertions(+), 79 deletions(-) diff --git a/code/modules/reagents/chemistry/reagents/alcohol.dm b/code/modules/reagents/chemistry/reagents/alcohol.dm index 88e2d685f57..d2fb4eec567 100644 --- a/code/modules/reagents/chemistry/reagents/alcohol.dm +++ b/code/modules/reagents/chemistry/reagents/alcohol.dm @@ -1126,7 +1126,7 @@ /datum/reagent/consumable/ethanol/dragons_breath/reaction_mob(mob/living/M, method=TOUCH, volume) if(method == INGEST && prob(20)) if(M.on_fire) - M.adjust_fire_stacks(3) + M.adjust_fire_stacks(6) /datum/reagent/consumable/ethanol/dragons_breath/on_mob_life(mob/living/M) var/update_flags = STATUS_UPDATE_NONE @@ -1148,7 +1148,7 @@ if(prob(2 * volume)) to_chat(M, "OH GOD OH GOD PLEASE NO!!") if(M.on_fire) - M.adjust_fire_stacks(5) + M.adjust_fire_stacks(20) if(prob(50)) to_chat(M, "IT BURNS!!!!") M.visible_message("[M] is consumed in flames!") diff --git a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm index 7761772a44c..f9c98130549 100644 --- a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm +++ b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm @@ -1,3 +1,80 @@ +/datum/reagent/phlogiston + name = "phlogiston" + id = "phlogiston" + description = "It appears to be liquid fire." + reagent_state = LIQUID + color = "#FFAF00" + process_flags = ORGANIC | SYNTHETIC + var/temp_fire = 4000 + var/temp_deviance = 1000 + var/size_divisor = 40 + var/mob_burning = 6.6 // 33 + +/datum/reagent/phlogiston/reaction_turf(turf/T, volume) + if(holder.chem_temp <= T0C - 50) + return + var/radius = min(max(0, volume / size_divisor), 8) + fireflash_sm(T, radius, rand(temp_fire - temp_deviance, temp_fire + temp_deviance), 500) + +/datum/reagent/phlogiston/reaction_mob(mob/living/M, method = TOUCH, volume) + if(holder.chem_temp <= T0C - 50) + return + M.adjust_fire_stacks(mob_burning) + M.IgniteMob() + if(method == INGEST) + M.adjustFireLoss(min(max(15, volume * 3), 45)) + to_chat(M, "It burns!") + M.emote("scream") + +/datum/reagent/phlogiston/on_mob_life(mob/living/M) + if(holder.chem_temp <= T0C - 50) + return + M.adjust_fire_stacks(0.4) + M.IgniteMob() + return ..() + +/datum/reagent/phlogiston/firedust + name = "phlogiston dust" + id = "phlogiston_dust" + description = "And this is solid fire. However that works." + temp_fire = 1500 + temp_deviance = 500 + size_divisor = 80 + mob_burning = 3 // 15 + +/datum/reagent/napalm + name = "napalm" + id = "napalm" + description = "A highly flammable jellied fuel." + reagent_state = LIQUID + process_flags = ORGANIC | SYNTHETIC + color = "#C86432" + +/datum/reagent/napalm/reaction_temperature(exposed_temperature, exposed_volume) + if(exposed_temperature > T0C + 100) + var/radius = min(max(0, volume * 0.15), 8) + fireflash_sm(get_turf(holder.my_atom), radius, rand(3000, 6000), 500) + if(holder) + holder.del_reagent(id) + +/datum/reagent/napalm/reaction_turf(turf/T, volume) + if(isspaceturf(T)) + return + if(!T.reagents) + T.create_reagents(volume) + T.reagents.add_reagent("napalm", volume) + +/datum/reagent/napalm/reaction_mob(mob/living/M, method = TOUCH, volume) + if(method == TOUCH) + if(M.on_fire) + M.adjust_fire_stacks(14) + M.emote("scream") + +/datum/reagent/napalm/on_mob_life(mob/living/M) + if(M.on_fire) + M.adjust_fire_stacks(2) + return ..() + /datum/reagent/fuel name = "Welding fuel" id = "fuel" @@ -8,6 +85,7 @@ drink_name = "Glass of welder fuel" drink_desc = "Unless you are an industrial tool, this is probably not safe for consumption." taste_message = "mistakes" + process_flags = ORGANIC | SYNTHETIC var/max_radius = 7 var/min_radius = 0 var/volume_radius_modifier = -0.15 @@ -19,6 +97,11 @@ var/volume_explosion_radius_modifier = 0 var/combustion_temp = T0C + 200 +/datum/reagent/fuel/on_mob_life(mob/living/M) + if(M.on_fire) + M.adjust_fire_stacks(0.4) + return ..() + /datum/reagent/fuel/reaction_temperature(exposed_temperature, exposed_volume) if(exposed_temperature > combustion_temp) if(volume < 1) @@ -48,9 +131,8 @@ /datum/reagent/fuel/reaction_mob(mob/living/M, method=TOUCH, volume)//Splashing people with welding fuel to make them easy to ignite! if(method == TOUCH) - M.adjust_fire_stacks(volume / 10) - return - ..() + if(M.on_fire) + M.adjust_fire_stacks(6) /datum/reagent/plasma name = "Plasma" @@ -76,10 +158,10 @@ C.adjustPlasma(10) return ..() | update_flags -/datum/reagent/plasma/reaction_mob(mob/living/M, method=TOUCH, volume)//Splashing people with plasma is stronger than fuel! +/datum/reagent/plasma/reaction_mob(mob/living/M, method = TOUCH, volume)//Splashing people with plasma is stronger than fuel! if(method == TOUCH) - M.adjust_fire_stacks(volume / 5) - ..() + if(M.on_fire) + M.adjust_fire_stacks(6) /datum/reagent/thermite @@ -91,6 +173,11 @@ process_flags = ORGANIC | SYNTHETIC taste_message = "rust" +/datum/reagent/thermite/reaction_mob(mob/living/M, method= TOUCH, volume) + if(method == TOUCH) + if(M.on_fire) + M.adjust_fire_stacks(20) + /datum/reagent/thermite/reaction_temperature(exposed_temperature, exposed_volume) var/turf/simulated/S = holder.my_atom if(!istype(S)) @@ -140,11 +227,9 @@ taste_message = null /datum/reagent/clf3/on_mob_life(mob/living/M) - var/update_flags = STATUS_UPDATE_NONE - M.adjust_fire_stacks(2) - var/burndmg = max(0.3*M.fire_stacks, 0.3) - update_flags |= M.adjustFireLoss(burndmg, FALSE) - return ..() | update_flags + if(M.on_fire) + M.adjust_fire_stacks(1) + return ..() /datum/reagent/clf3/reaction_turf(turf/T, volume) if(volume < 3) @@ -152,11 +237,14 @@ var/radius = min((volume - 3) * 0.15, 3) fireflash_sm(T, radius, 4500 + volume * 500, 350) -/datum/reagent/clf3/reaction_mob(mob/living/M, method=TOUCH, volume) - if(method == TOUCH) - M.adjust_fire_stacks(min(volume/5, 10)) +/datum/reagent/clf3/reaction_mob(mob/living/M, method = TOUCH, volume) + if(method == TOUCH || method == INGEST) + M.adjust_fire_stacks(10) M.IgniteMob() - M.bodytemperature += 30 + if(method == INGEST) + M.adjustFireLoss(min(max(30, volume * 6), 90)) + to_chat(M, "It burns!") + M.emote("scream") /datum/reagent/sorium name = "Sorium" @@ -224,6 +312,7 @@ description = "Makes a very bright flash." reagent_state = LIQUID color = "#FFFF00" + penetrates_skin = TRUE /datum/reagent/smoke_powder name = "Smoke Powder" @@ -238,42 +327,7 @@ description = "Makes a deafening noise." reagent_state = LIQUID color = "#0000FF" - -/datum/reagent/phlogiston - name = "Phlogiston" - id = "phlogiston" - description = "Catches you on fire and makes you ignite." - reagent_state = LIQUID - color = "#FF9999" - process_flags = ORGANIC | SYNTHETIC - -/datum/reagent/phlogiston/on_mob_life(mob/living/M) - var/update_flags = STATUS_UPDATE_NONE - M.adjust_fire_stacks(1) - var/burndmg = max(0.3*M.fire_stacks, 0.3) - update_flags |= M.adjustFireLoss(burndmg, FALSE) - return ..() | update_flags - -/datum/reagent/phlogiston/reaction_mob(mob/living/M, method=TOUCH, volume) - M.adjust_fire_stacks(1) - M.IgniteMob() - ..() - -/datum/reagent/napalm - name = "Napalm" - id = "napalm" - description = "Very flammable." - reagent_state = LIQUID - color = "#FF9999" - process_flags = ORGANIC | SYNTHETIC - -/datum/reagent/napalm/on_mob_life(mob/living/M) - M.adjust_fire_stacks(1) - return ..() - -/datum/reagent/napalm/reaction_mob(mob/living/M, method=TOUCH, volume) - if(method == TOUCH) - M.adjust_fire_stacks(min(volume/4, 20)) + penetrates_skin = TRUE /datum/reagent/cryostylane name = "Cryostylane" @@ -296,6 +350,10 @@ holder.temperature_reagents(holder.chem_temp - 200) ..() +/datum/reagent/cryostylane/reaction_mob(mob/living/M, method = TOUCH, volume) + if(method == TOUCH) + M.ExtinguishMob() + /datum/reagent/cryostylane/reaction_turf(turf/T, volume) if(volume >= 5) for(var/mob/living/carbon/slime/M in T) @@ -333,8 +391,7 @@ /datum/reagent/firefighting_foam/reaction_mob(mob/living/M, method=TOUCH, volume) // Put out fire if(method == TOUCH) - M.adjust_fire_stacks(-(volume / 5)) // more effective than water - M.ExtinguishMob() + M.adjust_fire_stacks(-10) // more effective than water /datum/reagent/firefighting_foam/reaction_obj(obj/O, volume) O.extinguish() diff --git a/code/modules/reagents/chemistry/reagents/water.dm b/code/modules/reagents/chemistry/reagents/water.dm index 6d8ea272cfe..5623023659b 100644 --- a/code/modules/reagents/chemistry/reagents/water.dm +++ b/code/modules/reagents/chemistry/reagents/water.dm @@ -23,8 +23,7 @@ /datum/reagent/water/reaction_mob(mob/living/M, method=TOUCH, volume) if(method == TOUCH) // Put out fire - M.adjust_fire_stacks(-(volume / 10)) - M.ExtinguishMob() + M.adjust_fire_stacks(-(volume * 0.2)) if(ishuman(M)) var/mob/living/carbon/human/H = M diff --git a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm index 6c0c1566414..55c7de4d326 100644 --- a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm +++ b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm @@ -212,6 +212,40 @@ datum/chemical_reaction/flash_powder continue C.Stun(5) +/datum/chemical_reaction/phlogiston + name = "Phlogiston" + id = "phlogiston" + result = "phlogiston" + required_reagents = list("phosphorus" = 1, "plasma" = 1, "sacid" = 1, "stabilizing_agent" = 1) + result_amount = 4 + mix_message = "The substance becomes sticky and extremely warm." + +/datum/chemical_reaction/phlogiston_dust + name = "Phlogiston Dust" + id = "phlogiston_dust" + result = "phlogiston_dust" + required_reagents = list("phlogiston" = 1, "charcoal" = 1, "phosphorus" = 1, "sulfur" = 1) + result_amount = 2 + mix_message = "The substance becomes a pile of burning dust." + +/datum/chemical_reaction/phlogiston_fire //This MUST be above the smoke recipe. + name = "Phlogiston Fire" + id = "phlogiston_fire" + result = "phlogiston" + required_reagents = list("phosphorus" = 1, "plasma" = 1, "sacid" = 1) + mix_message = "The substance erupts into wild flames." + +/datum/chemical_reaction/phlogiston_fire/on_reaction(datum/reagents/holder, created_volume) + fireflash(get_turf(holder.my_atom), min(max(2, round(created_volume / 10)), 8)) + +/datum/chemical_reaction/napalm + name = "Napalm" + id = "napalm" + result = "napalm" + required_reagents = list("fuel" = 1, "sugar" = 1, "ethanol" = 1) + result_amount = 3 + mix_message = "The mixture congeals into a sticky gel." + /datum/chemical_reaction/smoke_powder name = "smoke_powder" id = "smoke_powder" @@ -337,28 +371,6 @@ datum/chemical_reaction/flash_powder if(ears.ear_damage >= 5) to_chat(M, "Your ears start to ring!") - -/datum/chemical_reaction/phlogiston - name = "phlogiston" - id = "phlogiston" - result = "phlogiston" - required_reagents = list("phosphorus" = 1, "sacid" = 1, "plasma" = 1) - result_amount = 3 - -/datum/chemical_reaction/phlogiston/on_reaction(datum/reagents/holder, created_volume) - if(holder.has_reagent("stabilizing_agent")) - return - var/turf/simulated/T = get_turf(holder.my_atom) - for(var/turf/simulated/turf in range(min(created_volume/10,4),T)) - new /obj/effect/hotspot(turf) - -/datum/chemical_reaction/napalm - name = "Napalm" - id = "napalm" - result = "napalm" - required_reagents = list("sugar" = 1, "fuel" = 1, "ethanol" = 1 ) - result_amount = 1 - /datum/chemical_reaction/cryostylane name = "cryostylane" id = "cryostylane" From 6caec96c2a60790ccc8e721bd218273f4a88ad1a Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Wed, 20 Mar 2019 01:56:46 -0400 Subject: [PATCH 08/12] fixed --- code/game/objects/items/weapons/tools.dm | 1 - 1 file changed, 1 deletion(-) diff --git a/code/game/objects/items/weapons/tools.dm b/code/game/objects/items/weapons/tools.dm index 7fb2a50e65a..5eb7a5b30ff 100644 --- a/code/game/objects/items/weapons/tools.dm +++ b/code/game/objects/items/weapons/tools.dm @@ -469,7 +469,6 @@ /obj/item/weldingtool/afterattack(atom/O, mob/user, proximity) if(!proximity) return - ..() if(welding) remove_fuel(1) var/turf/location = get_turf(user) From aba98f6cb2441c63125926f0414f6a3287337b5f Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Wed, 20 Mar 2019 17:11:30 -0400 Subject: [PATCH 09/12] fake hotspots --- code/LINDA/LINDA_fire.dm | 46 ++++++++++++++----- .../chemistry/reagents/pyrotechnic.dm | 10 ++-- code/modules/reagents/reagent_dispenser.dm | 7 +-- 3 files changed, 44 insertions(+), 19 deletions(-) diff --git a/code/LINDA/LINDA_fire.dm b/code/LINDA/LINDA_fire.dm index dad05f32c99..7c56277e7ab 100644 --- a/code/LINDA/LINDA_fire.dm +++ b/code/LINDA/LINDA_fire.dm @@ -59,11 +59,14 @@ var/temperature = FIRE_MINIMUM_TEMPERATURE_TO_EXIST var/just_spawned = 1 var/bypassing = 0 + var/fake = FALSE + var/burn_time = 0 /obj/effect/hotspot/New() ..() - SSair.hotspots += src - perform_exposure() + if(!fake) + SSair.hotspots += src + perform_exposure() dir = pick(cardinal) air_update_turf() @@ -162,7 +165,8 @@ /obj/effect/hotspot/Destroy() set_light(0) SSair.hotspots -= src - DestroyTurf() + if(!fake) + DestroyTurf() if(istype(loc, /turf/simulated)) var/turf/simulated/T = loc if(T.active_hotspot == src) @@ -190,6 +194,15 @@ if(isliving(L)) L.fire_act() +/obj/effect/hotspot/fake // Largely for the fireflash procs below + fake = TRUE + burn_time = 30 + +/obj/effect/hotspot/fake/New() + ..() + if(burn_time) + QDEL_IN(src, burn_time) + /proc/fireflash(atom/center, radius, temp) if(!temp) temp = rand(2800, 3200) @@ -201,14 +214,18 @@ if(!can_line(get_turf(center), T, radius + 1)) continue - var/obj/effect/hotspot/H = new(T) + var/obj/effect/hotspot/fake/H = new(T) H.temperature = temp H.volume = 400 - if(istype(T, /turf/simulated)) - var/turf/simulated/S = T - S.active_hotspot = H + H.color = heat2color(H.temperature) + H.set_light(l_color = H.color) T.hotspot_expose(H.temperature, H.volume) + for(var/atom/A in T) + if(isliving(A)) + continue + if(A != H) + A.fire_act(null, H.temperature, H.volume) if(istype(T, /turf/simulated/floor)) var/turf/simulated/floor/F = T @@ -248,14 +265,13 @@ var/need_expose = 0 var/expose_temp = 0 if(!existing_hotspot) - var/obj/effect/hotspot/H = new(T) + var/obj/effect/hotspot/fake/H = new(T) need_expose = TRUE H.temperature = temp - dist * falloff expose_temp = H.temperature H.volume = 400 - if(istype(T, /turf/simulated)) - var/turf/simulated/S = T - S.active_hotspot = H + H.color = heat2color(H.temperature) + H.set_light(l_color = H.color) existing_hotspot = H else if(existing_hotspot.temperature < temp - dist * falloff) @@ -264,15 +280,23 @@ if(expose_temp > prev_temp * 3) need_expose = TRUE existing_hotspot.temperature = temp - dist * falloff + existing_hotspot.color = heat2color(existing_hotspot.temperature) + existing_hotspot.set_light(l_color = existing_hotspot.color) affected[T] = existing_hotspot.temperature if(need_expose && expose_temp) T.hotspot_expose(expose_temp, existing_hotspot.volume) + for(var/atom/A in T) + if(isliving(A)) + continue + if(A != existing_hotspot) + A.fire_act(null, expose_temp, existing_hotspot.volume) if(istype(T, /turf/simulated/floor)) var/turf/simulated/floor/F = T F.burn_tile() for(var/mob/living/L in T) L.adjust_fire_stacks(3) + L.IgniteMob() L.bodytemperature = (2 * L.bodytemperature + temp) / 3 if(T.density) diff --git a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm index f9c98130549..fb58e351a03 100644 --- a/code/modules/reagents/chemistry/reagents/pyrotechnic.dm +++ b/code/modules/reagents/chemistry/reagents/pyrotechnic.dm @@ -198,7 +198,7 @@ S.overlays.Cut() S.overlays = image('icons/effects/effects.dmi', icon_state = "thermite") if(S.active_hotspot) - S.reagents.temperature_reagents(S.active_hotspot.temperature, S.active_hotspot.volume, 10, 300) + S.reagents.temperature_reagents(S.active_hotspot.temperature, 10, 300) /datum/reagent/glycerol name = "Glycerol" @@ -344,8 +344,8 @@ /datum/reagent/cryostylane/on_tick() if(holder.has_reagent("oxygen")) - holder.remove_reagent("oxygen", 1) - holder.remove_reagent("cryostylane", 1) + holder.remove_reagent("oxygen", 2) + holder.remove_reagent("cryostylane", 2) holder.temperature_reagents(holder.chem_temp - 200) holder.temperature_reagents(holder.chem_temp - 200) ..() @@ -374,8 +374,8 @@ /datum/reagent/pyrosium/on_tick() if(holder.has_reagent("oxygen")) - holder.remove_reagent("oxygen", 1) - holder.remove_reagent("pyrosium", 1) + holder.remove_reagent("oxygen", 2) + holder.remove_reagent("pyrosium", 2) holder.temperature_reagents(holder.chem_temp + 200) holder.temperature_reagents(holder.chem_temp + 200) ..() diff --git a/code/modules/reagents/reagent_dispenser.dm b/code/modules/reagents/reagent_dispenser.dm index 098708bde57..b3c98f82b54 100644 --- a/code/modules/reagents/reagent_dispenser.dm +++ b/code/modules/reagents/reagent_dispenser.dm @@ -26,7 +26,8 @@ ..() if(reagents) for(var/i in 1 to 8) - reagents.temperature_reagents(exposed_temperature, exposed_volume) + if(reagents) + reagents.temperature_reagents(exposed_temperature) /obj/structure/reagent_dispensers/proc/boom() visible_message("[src] ruptures!") @@ -91,8 +92,8 @@ investigate_log("[key_name(P.firer)] triggered a fueltank explosion with [P.name] at [COORD(loc)]", INVESTIGATE_BOMB) boom() -/obj/structure/reagent_dispensers/fueltank/boom(var/rigtrigger = FALSE) // Prevent case where someone who rigged the tank is blamed for the explosion when the rig isn't what triggered the explosion - if(rigtrigger == TRUE) // If the explosion is triggered by an assembly holder +/obj/structure/reagent_dispensers/fueltank/boom(rigtrigger = FALSE) // Prevent case where someone who rigged the tank is blamed for the explosion when the rig isn't what triggered the explosion + if(rigtrigger) // If the explosion is triggered by an assembly holder message_admins("A fueltank, last rigged by [lastrigger], was triggered at [COORD(loc)]") // Then admin is informed of the last person who rigged the fuel tank log_game("A fueltank, last rigged by [lastrigger], triggered at [COORD(loc)]") investigate_log("A fueltank, last rigged by [lastrigger], triggered at [COORD(loc)]", INVESTIGATE_BOMB) From 85b9fe2ebe45f4bfa2a82d6d73fb109452c102d9 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Thu, 21 Mar 2019 16:28:46 -0400 Subject: [PATCH 10/12] lower fire damage --- code/modules/mob/living/carbon/_defines.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/mob/living/carbon/_defines.dm b/code/modules/mob/living/carbon/_defines.dm index 163ce8f7c8d..483502965da 100644 --- a/code/modules/mob/living/carbon/_defines.dm +++ b/code/modules/mob/living/carbon/_defines.dm @@ -4,7 +4,7 @@ #define HEAT_DAMAGE_LEVEL_1 2 //Amount of damage applied when your body temperature just passes the 360.15k safety point #define HEAT_DAMAGE_LEVEL_2 3 //Amount of damage applied when your body temperature passes the 400K point -#define HEAT_DAMAGE_LEVEL_3 10 //Amount of damage applied when your body temperature passes the 1000K point +#define HEAT_DAMAGE_LEVEL_3 5 //Amount of damage applied when your body temperature passes the 1000K point #define COLD_DAMAGE_LEVEL_1 0.5 //Amount of damage applied when your body temperature just passes the 260.15k safety point #define COLD_DAMAGE_LEVEL_2 1.5 //Amount of damage applied when your body temperature passes the 200K point From f14359a0ddc180091ac3242e79430beab9e3b689 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Fri, 22 Mar 2019 14:33:36 -0400 Subject: [PATCH 11/12] effects fixes smoke layer --- .../effect_system/effects_chem_smoke.dm | 1 + .../temporary_visuals/miscellaneous.dm | 18 ++++++++++++++++++ code/modules/reagents/chemistry/recipes.dm | 2 ++ icons/goonstation/effects/64x64.dmi | Bin 5895 -> 10868 bytes 4 files changed, 21 insertions(+) diff --git a/code/game/objects/effects/effect_system/effects_chem_smoke.dm b/code/game/objects/effects/effect_system/effects_chem_smoke.dm index d68692a03e6..4b720a607ea 100644 --- a/code/game/objects/effects/effect_system/effects_chem_smoke.dm +++ b/code/game/objects/effects/effect_system/effects_chem_smoke.dm @@ -7,6 +7,7 @@ icon_state = "smoke" density = FALSE opacity = FALSE + layer = ABOVE_MOB_LAYER animate_movement = NO_STEPS var/matrix/first = matrix() var/matrix/second = matrix() diff --git a/code/game/objects/effects/temporary_visuals/miscellaneous.dm b/code/game/objects/effects/temporary_visuals/miscellaneous.dm index 8b9314e9a6f..880043c8be6 100644 --- a/code/game/objects/effects/temporary_visuals/miscellaneous.dm +++ b/code/game/objects/effects/temporary_visuals/miscellaneous.dm @@ -211,3 +211,21 @@ pixel_x = rand(-4,4) pixel_y = rand(-4,4) animate(src, pixel_y = pixel_y + 32, alpha = 0, time = 25) + +/obj/effect/temp_visual/shockwave + name = "shockwave" + icon = 'icons/goonstation/effects/64x64.dmi' + icon_state = "shockwave" + randomdir = FALSE + pixel_y = -16 + pixel_x = -16 + duration = 20 + +/obj/effect/temp_visual/implosion + name = "implosion" + icon = 'icons/goonstation/effects/64x64.dmi' + icon_state = "implosion" + randomdir = FALSE + pixel_y = -16 + pixel_x = -16 + duration = 20 \ No newline at end of file diff --git a/code/modules/reagents/chemistry/recipes.dm b/code/modules/reagents/chemistry/recipes.dm index 78f46884273..288abeb5f4d 100644 --- a/code/modules/reagents/chemistry/recipes.dm +++ b/code/modules/reagents/chemistry/recipes.dm @@ -67,8 +67,10 @@ var/list/chemical_mob_spawn_nicecritters = list() // and possible friendly mobs /proc/goonchem_vortex(turf/T, setting_type, volume) if(setting_type) + new /obj/effect/temp_visual/implosion(T) playsound(T, 'sound/effects/whoosh.ogg', 25, 1) //credit to Robinhood76 of Freesound.org for this. else + new /obj/effect/temp_visual/shockwave(T) playsound(T, 'sound/effects/bang.ogg', 25, 1) for(var/atom/movable/X in view(2 + setting_type + (volume > 30 ? 1 : 0), T)) if(istype(X, /obj/effect)) diff --git a/icons/goonstation/effects/64x64.dmi b/icons/goonstation/effects/64x64.dmi index e1b168bbc116b3a920bef64a5940a130049e19b3..17910cfdfb18f9a46c1faf45c042c73383df7a8c 100644 GIT binary patch literal 10868 zcmbt)cQjn#`{$?;BzlPwjNXF?LJTrW5Hfo75H&hc$7qqvs1ZHEh+d*c@4Y4n(R&v} zv{6RcJA2OWkMD2y?AfzB=P2ind*{9H^J&lHqF!jJ-XUco1%W_!o~c1~Kp;E?;0r`T z3>@j`E9(J%FPhVJn=3XlDHnOtNK~lpFfzJtHdFE6aNgoB~eHGm}d-j>~ z?L$khSI5oI)Vy47TfXLUiM;-Z2sCOUV{p`8_?^9n-#!o_7*q5G#am;RHsvUe|C_PnH;&j1t ze{TQQ*Qul7)4BRnPxPkTX4=lQ? zR7d~+a{~VU4BhW?;oTkoqI)$HyIG6057L-^2M06Z;o*Wp@*B7ON>DQ)ZSHAXP1`7)eYAe`L8DyMiU@uv{gUg^DWQdFTsUn&aM{eT>KAeN}mn?~^kVD!TFUUMGKke{;wt zr9NzYt{ISOcYiw2WoHA^7hv5wo8Y@eOa+r>G2aGGqlT#mV7wQSlU9y)Qh*{5gR>$c zB0eteFSf->0iP-)Dk{Y|{iqfXZzed9Vh*BjW;W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1l|cQl*WMhaIV&r(;k+yo>Xn^^E&hSBg~t>7i?bE)gQ~Eh%_cbaWDVc}+Vh?2wa_ z7QtAoahur8H7d-!=LxM1i3{h8I+y>k1$(CKe16)OTOUUc?ra0v8V2fBs`g?30b({p A7XSbN From 552967716b654822e4837c3128c22e8d786eb001 Mon Sep 17 00:00:00 2001 From: Fox McCloud Date: Fri, 22 Mar 2019 14:56:44 -0400 Subject: [PATCH 12/12] helpers --- code/LINDA/LINDA_fire.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/LINDA/LINDA_fire.dm b/code/LINDA/LINDA_fire.dm index 7c56277e7ab..3d0ec87a8a2 100644 --- a/code/LINDA/LINDA_fire.dm +++ b/code/LINDA/LINDA_fire.dm @@ -207,7 +207,7 @@ if(!temp) temp = rand(2800, 3200) for(var/turf/T in view(radius, get_turf(center))) - if(istype(T, /turf/space)) + if(isspaceturf(T)) continue if(locate(/obj/effect/hotspot) in T) continue @@ -227,7 +227,7 @@ if(A != H) A.fire_act(null, H.temperature, H.volume) - if(istype(T, /turf/simulated/floor)) + if(isfloorturf(T)) var/turf/simulated/floor/F = T F.burn_tile() @@ -291,7 +291,7 @@ continue if(A != existing_hotspot) A.fire_act(null, expose_temp, existing_hotspot.volume) - if(istype(T, /turf/simulated/floor)) + if(isfloorturf(T)) var/turf/simulated/floor/F = T F.burn_tile() for(var/mob/living/L in T)