Suit coolers don't magically shut off in mild fires (#4820)

This commit is contained in:
Anewbe
2018-02-17 11:19:21 -08:00
committed by Atermonera
parent 61e689960f
commit 077b73a446
3 changed files with 47 additions and 5 deletions
@@ -46,9 +46,15 @@
var/mob/living/carbon/human/H = loc
var/efficiency = 1 - H.get_pressure_weakness() //you need to have a good seal for effective cooling
var/env_temp = get_environment_temperature() //wont save you from a fire
var/temp_adj = min(H.bodytemperature - max(thermostat, env_temp), max_cooling)
var/efficiency = 1 - H.get_pressure_weakness() // You need to have a good seal for effective cooling
var/temp_adj = 0 // How much the unit cools you. Adjusted later on.
var/env_temp = get_environment_temperature() // This won't save you from a fire
var/thermal_protection = H.get_heat_protection(env_temp) // ... unless you've got a good suit.
if(thermal_protection < 0.99) //For some reason, < 1 returns false if the value is 1.
temp_adj = min(H.bodytemperature - max(thermostat, env_temp), max_cooling)
else
temp_adj = min(H.bodytemperature - thermostat, max_cooling)
if (temp_adj < 0.5) //only cools, doesn't heat, also we don't need extreme precision
return