Typecheck all return_air calls (#15363)

This commit is contained in:
Wildkins
2022-12-19 12:19:41 +01:00
committed by GitHub
parent bc3728c4e7
commit bb04ba3f87
53 changed files with 94 additions and 47 deletions
@@ -198,8 +198,10 @@
if(istype(H, /obj/machinery/portable_atmospherics/hydroponics/soil/invisible))
qdel(H)
var/datum/gas_mixture/environment = T.return_air()
environment.adjust_gas(GAS_PHORON,-amount*10)
if(istype(T))
var/datum/gas_mixture/environment = T.return_air()
if(environment)
environment.adjust_gas(GAS_PHORON,-amount*10)
/decl/reagent/toxin/cyanide //Fast and Lethal
name = "Cyanide"
+9 -7
View File
@@ -401,10 +401,12 @@
playsound(src.loc, 'sound/effects/smoke.ogg', 50, 1, -3)
INVOKE_ASYNC(S, /datum/effect/effect/system/smoke_spread/.proc/start)
var/datum/gas_mixture/env = src.loc.return_air()
if(env)
if (reagents.total_volume > 750)
env.temperature = 0
else if (reagents.total_volume > 500)
env.temperature -= 100
QDEL_IN(src, 10)
if(src.loc)
var/datum/gas_mixture/env = src.loc.return_air()
if(env)
if (reagents.total_volume > 750)
env.temperature = 0
else if (reagents.total_volume > 500)
env.temperature -= 100
QDEL_IN(src, 10)