From bfdaf453b07358abc99fdced9be33614aa292071 Mon Sep 17 00:00:00 2001 From: Bjorn Neergaard Date: Fri, 4 Dec 2015 00:31:43 -0500 Subject: [PATCH] Fix Cryo checks Derp --- code/ATMOSPHERICS/components/unary_devices/cryo.dm | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/code/ATMOSPHERICS/components/unary_devices/cryo.dm b/code/ATMOSPHERICS/components/unary_devices/cryo.dm index 2f79446bac7..88fb4e5bc03 100644 --- a/code/ATMOSPHERICS/components/unary_devices/cryo.dm +++ b/code/ATMOSPHERICS/components/unary_devices/cryo.dm @@ -59,15 +59,16 @@ /obj/machinery/atmospherics/components/unary/cryo_cell/process() ..() - if(occupant && occupant.health >= 100 && autoEject) + if(occupant && occupant.health >= 100) on = 0 - open_machine() playsound(src.loc, 'sound/machines/ding.ogg', 50, 1) + if(autoEject) + open_machine() + if(!NODE1 || !is_operational()) return - if(AIR1) - if (occupant) + if(on && occupant) process_occupant() expel_gas() @@ -82,7 +83,7 @@ return /obj/machinery/atmospherics/components/unary/cryo_cell/container_resist() - usr << "Release sequence activated. This will take a few seconds." + usr << "You struggle inside the cryotube, kicking the release with your foot." sleep(150) if(!src || !usr || (!occupant && !contents.Find(usr))) // Make sure they didn't disappear. return @@ -260,6 +261,8 @@ /obj/machinery/atmospherics/components/unary/cryo_cell/proc/process_occupant() var/datum/gas_mixture/air_contents = AIR1 + if(!on) + return if(air_contents.total_moles() < 10) return if(occupant)