Changes cryoxadone to check external temp

This commit is contained in:
warior4356
2020-09-25 22:01:07 -07:00
parent 7e8d9ad51e
commit f6965a2a76
@@ -121,7 +121,14 @@
/datum/reagent/medicine/cryoxadone/on_mob_life(mob/living/M)
var/update_flags = STATUS_UPDATE_NONE
if(M.bodytemperature < TCRYO)
var/external_temp
if(istype(M.loc, /obj/machinery/atmospherics/unary/cryo_cell))
var/obj/machinery/atmospherics/unary/cryo_cell/C = M.loc
external_temp = C.temperature_archived
else
var/turf/T = M.loc
external_temp = T.temperature
if(external_temp < TCRYO)
update_flags |= M.adjustCloneLoss(-4, FALSE)
update_flags |= M.adjustOxyLoss(-10, FALSE)
update_flags |= M.adjustToxLoss(-3, FALSE)