From 7956e3df2746a06a31ed4451f2d4946b5d752365 Mon Sep 17 00:00:00 2001 From: ShizCalev Date: Sun, 7 Jan 2018 12:01:26 -0500 Subject: [PATCH 1/2] Corrects inconsistent usage of 310.055, 310.15, & 310 as body temp --- code/__DEFINES/atmospherics.dm | 4 +- code/datums/diseases/advance/symptoms/heal.dm | 8 +-- code/datums/status_effects/gas.dm | 2 +- .../components/unary_devices/cryo.dm | 4 +- code/modules/mob/living/blood.dm | 7 +- code/modules/mob/living/carbon/alien/alien.dm | 2 +- code/modules/mob/living/carbon/life.dm | 10 +-- code/modules/mob/living/carbon/monkey/life.dm | 2 +- code/modules/mob/living/living.dm | 2 +- code/modules/mob/mob_defines.dm | 2 +- .../chemistry/reagents/alcohol_reagents.dm | 20 +++--- .../chemistry/reagents/drink_reagents.dm | 64 +++++++++---------- .../chemistry/reagents/food_reagents.dm | 8 +-- .../chemistry/reagents/medicine_reagents.dm | 8 +-- 14 files changed, 75 insertions(+), 68 deletions(-) diff --git a/code/__DEFINES/atmospherics.dm b/code/__DEFINES/atmospherics.dm index 430f7f29b3..b0e0e483e6 100644 --- a/code/__DEFINES/atmospherics.dm +++ b/code/__DEFINES/atmospherics.dm @@ -14,9 +14,10 @@ //stuff you should probably leave well alone! #define R_IDEAL_GAS_EQUATION 8.31 //kPa*L/(K*mol) #define ONE_ATMOSPHERE 101.325 //kPa +#define TCMB 2.7 // -270.3degC +#define TCRYO 225 // -48.15degC #define T0C 273.15 // 0degC #define T20C 293.15 // 20degC -#define TCMB 2.7 // -270.3degC #define MOLES_CELLSTANDARD (ONE_ATMOSPHERE*CELL_VOLUME/(T20C*R_IDEAL_GAS_EQUATION)) //moles in a 2.5 m^3 cell at 101.325 Pa and 20 degC #define M_CELL_WITH_RATIO (MOLES_CELLSTANDARD * 0.005) //compared against for superconductivity @@ -87,6 +88,7 @@ #define TEMPERATURE_DAMAGE_COEFFICIENT 1.5 //This is used in handle_temperature_damage() for humans, and in reagents that affect body temperature. Temperature damage is multiplied by this amount. #define BODYTEMP_AUTORECOVERY_DIVISOR 12 //This is the divisor which handles how much of the temperature difference between the current body temperature and 310.15K (optimal temperature) humans auto-regenerate each tick. The higher the number, the slower the recovery. This is applied each tick, so long as the mob is alive. #define BODYTEMP_AUTORECOVERY_MINIMUM 10 //Minimum amount of kelvin moved toward 310.15K per tick. So long as abs(310.15 - bodytemp) is more than 50. +#define BODYTEMP_NORMAL 310.15 //98.6F, or 37C, the normal temprature of the human body. #define BODYTEMP_COLD_DIVISOR 6 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is lower than their body temperature. Make it lower to lose bodytemp faster. #define BODYTEMP_HEAT_DIVISOR 6 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is higher than their body temperature. Make it lower to gain bodytemp faster. #define BODYTEMP_COOLING_MAX 30 //The maximum number of degrees that your body can cool in 1 tick, when in a cold area. diff --git a/code/datums/diseases/advance/symptoms/heal.dm b/code/datums/diseases/advance/symptoms/heal.dm index 104a4c00c2..23fb2ed866 100644 --- a/code/datums/diseases/advance/symptoms/heal.dm +++ b/code/datums/diseases/advance/symptoms/heal.dm @@ -384,12 +384,12 @@ if(prob(5)) to_chat(M, "You feel yourself absorbing plasma inside and around you...") - if(M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (20 * temp_rate * TEMPERATURE_DAMAGE_COEFFICIENT)) + if(M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (20 * temp_rate * TEMPERATURE_DAMAGE_COEFFICIENT)) if(prob(5)) to_chat(M, "You feel less hot.") - else if(M.bodytemperature < 311) - M.bodytemperature = min(310, M.bodytemperature + (20 * temp_rate * TEMPERATURE_DAMAGE_COEFFICIENT)) + else if(M.bodytemperature < (BODYTEMP_NORMAL + 1)) + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (20 * temp_rate * TEMPERATURE_DAMAGE_COEFFICIENT)) if(prob(5)) to_chat(M, "You feel warmer.") diff --git a/code/datums/status_effects/gas.dm b/code/datums/status_effects/gas.dm index 688c921a73..0e18b01cf8 100644 --- a/code/datums/status_effects/gas.dm +++ b/code/datums/status_effects/gas.dm @@ -21,7 +21,7 @@ /datum/status_effect/freon/tick() owner.update_canmove() - if(can_melt && owner.bodytemperature >= 310.055) + if(can_melt && owner.bodytemperature >= BODYTEMP_NORMAL) qdel(src) /datum/status_effect/freon/on_remove() diff --git a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm index 87d6387b99..7ff046ab15 100644 --- a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm +++ b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm @@ -341,9 +341,9 @@ data["occupant"]["toxLoss"] = round(mob_occupant.getToxLoss(), 1) data["occupant"]["fireLoss"] = round(mob_occupant.getFireLoss(), 1) data["occupant"]["bodyTemperature"] = round(mob_occupant.bodytemperature, 1) - if(mob_occupant.bodytemperature < 225) + if(mob_occupant.bodytemperature < TCRYO) data["occupant"]["temperaturestatus"] = "good" - else if(mob_occupant.bodytemperature < 273.15) + else if(mob_occupant.bodytemperature < T0C) data["occupant"]["temperaturestatus"] = "average" else data["occupant"]["temperaturestatus"] = "bad" diff --git a/code/modules/mob/living/blood.dm b/code/modules/mob/living/blood.dm index 6d0fc988c7..2efc9a906c 100644 --- a/code/modules/mob/living/blood.dm +++ b/code/modules/mob/living/blood.dm @@ -16,7 +16,7 @@ /mob/living/carbon/monkey/handle_blood() - if(bodytemperature >= 225 && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. + if(bodytemperature >= TCRYO && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. //Blood regeneration if there is some space if(blood_volume < BLOOD_VOLUME_NORMAL) blood_volume += 0.1 // regenerate blood VERY slowly @@ -27,7 +27,12 @@ if(NOBLOOD in dna.species.species_traits) bleed_rate = 0 return +<<<<<<< HEAD if(bodytemperature >= 225 && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. +======= + + if(bodytemperature >= TCRYO && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. +>>>>>>> 18892a0... Corrects inconsistent usage of 310.055, 310.15, & 310 as body temp (#34134) //Blood regeneration if there is some space if(blood_volume < BLOOD_VOLUME_NORMAL && !(NOHUNGER in dna.species.species_traits)) diff --git a/code/modules/mob/living/carbon/alien/alien.dm b/code/modules/mob/living/carbon/alien/alien.dm index b05ab78daf..089f536958 100644 --- a/code/modules/mob/living/carbon/alien/alien.dm +++ b/code/modules/mob/living/carbon/alien/alien.dm @@ -71,7 +71,7 @@ else bodytemperature += 1 * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR) - if(bodytemperature > 360.15) + if(bodytemperature > BODYTEMP_HEAT_DAMAGE_LIMIT) //Body temperature is too hot. throw_alert("alien_fire", /obj/screen/alert/alien_fire) switch(bodytemperature) diff --git a/code/modules/mob/living/carbon/life.dm b/code/modules/mob/living/carbon/life.dm index 4399607984..3fe77eadae 100644 --- a/code/modules/mob/living/carbon/life.dm +++ b/code/modules/mob/living/carbon/life.dm @@ -394,15 +394,15 @@ //used in human and monkey handle_environment() /mob/living/carbon/proc/natural_bodytemperature_stabilization() - var/body_temperature_difference = 310.15 - bodytemperature + var/body_temperature_difference = BODYTEMP_NORMAL - bodytemperature switch(bodytemperature) - if(-INFINITY to 260.15) //260.15 is 310.15 - 50, the temperature where you start to feel effects. + if(-INFINITY to BODYTEMP_COLD_DAMAGE_LIMIT) //BODYTEMP_COLD_DAMAGE_LIMIT is BODYTEMP_NORMAL(310.15) - 50, the temperature where you start to feel effects. bodytemperature += max((body_temperature_difference * metabolism_efficiency / BODYTEMP_AUTORECOVERY_DIVISOR), BODYTEMP_AUTORECOVERY_MINIMUM) - if(260.15 to 310.15) + if(BODYTEMP_COLD_DAMAGE_LIMIT to BODYTEMP_NORMAL) bodytemperature += max(body_temperature_difference * metabolism_efficiency / BODYTEMP_AUTORECOVERY_DIVISOR, min(body_temperature_difference, BODYTEMP_AUTORECOVERY_MINIMUM/4)) - if(310.15 to 360.15) + if(BODYTEMP_NORMAL to BODYTEMP_HEAT_DAMAGE_LIMIT) bodytemperature += min(body_temperature_difference * metabolism_efficiency / BODYTEMP_AUTORECOVERY_DIVISOR, max(body_temperature_difference, -BODYTEMP_AUTORECOVERY_MINIMUM/4)) - if(360.15 to INFINITY) //360.15 is 310.15 + 50, the temperature where you start to feel effects. + if(BODYTEMP_HEAT_DAMAGE_LIMIT to INFINITY) //BODYTEMP_HEAT_DAMAGE_LIMIT is BODYTEMP_NORMAL(310.15) + 50, the temperature where you start to feel effects. //We totally need a sweat system cause it totally makes sense...~ bodytemperature += min((body_temperature_difference / BODYTEMP_AUTORECOVERY_DIVISOR), -BODYTEMP_AUTORECOVERY_MINIMUM) //We're dealing with negative numbers ///////// diff --git a/code/modules/mob/living/carbon/monkey/life.dm b/code/modules/mob/living/carbon/monkey/life.dm index 613a04bd17..09d3665bfc 100644 --- a/code/modules/mob/living/carbon/monkey/life.dm +++ b/code/modules/mob/living/carbon/monkey/life.dm @@ -44,7 +44,7 @@ return ..() /mob/living/carbon/monkey/handle_breath_temperature(datum/gas_mixture/breath) - if(abs(310.15 - breath.temperature) > 50) + if(abs(BODYTEMP_NORMAL - breath.temperature) > 50) switch(breath.temperature) if(-INFINITY to 120) adjustFireLoss(3) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 964e1feef0..3b2a95f6bd 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -406,7 +406,7 @@ SetSleeping(0, FALSE) radiation = 0 nutrition = NUTRITION_LEVEL_FED + 50 - bodytemperature = 310 + bodytemperature = BODYTEMP_NORMAL set_blindness(0) set_blurriness(0) set_eye_damage(0) diff --git a/code/modules/mob/mob_defines.dm b/code/modules/mob/mob_defines.dm index edbf11654b..370e569b75 100644 --- a/code/modules/mob/mob_defines.dm +++ b/code/modules/mob/mob_defines.dm @@ -60,7 +60,7 @@ var/timeofdeath = 0//Living var/cpr_time = 1//Carbon - var/bodytemperature = 310.055 //98.7 F + var/bodytemperature = BODYTEMP_NORMAL //310.15K / 98.6F var/drowsyness = 0//Carbon var/dizziness = 0//Carbon var/jitteriness = 0//Carbon diff --git a/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm b/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm index fe58e4ea77..6b47b99a32 100644 --- a/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm @@ -149,8 +149,8 @@ All effects don't start immediately, but rather get worse over time; the rate is /datum/reagent/consumable/ethanol/thirteenloko/on_mob_life(mob/living/M) M.drowsyness = max(0,M.drowsyness-7) M.AdjustSleeping(-40) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) M.Jitter(5) return ..() @@ -541,8 +541,8 @@ All effects don't start immediately, but rather get worse over time; the rate is shot_glass_icon_state = "toxinsspecialglass" /datum/reagent/consumable/ethanol/toxins_special/on_mob_life(var/mob/living/M as mob) - if (M.bodytemperature < 330) - M.bodytemperature = min(330, M.bodytemperature + (15 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature < (BODYTEMP_NORMAL + 20)) + M.bodytemperature = min((BODYTEMP_NORMAL + 20), M.bodytemperature + (15 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. return ..() /datum/reagent/consumable/ethanol/beepsky_smash @@ -721,8 +721,8 @@ All effects don't start immediately, but rather get worse over time; the rate is glass_desc = "The ultimate refreshment." /datum/reagent/consumable/ethanol/antifreeze/on_mob_life(mob/living/M) - if (M.bodytemperature < 330) - M.bodytemperature = min(330, M.bodytemperature + (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature < (BODYTEMP_NORMAL + 20)) + M.bodytemperature = min((BODYTEMP_NORMAL + 20), M.bodytemperature + (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. return ..() /datum/reagent/consumable/ethanol/barefoot @@ -835,8 +835,8 @@ All effects don't start immediately, but rather get worse over time; the rate is glass_desc = "A spicy mix of Vodka and Spice. Very hot." /datum/reagent/consumable/ethanol/sbiten/on_mob_life(mob/living/M) - if (M.bodytemperature < 360) - M.bodytemperature = min(360, M.bodytemperature + (50 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature < BODYTEMP_HEAT_DAMAGE_LIMIT) + M.bodytemperature = min(BODYTEMP_HEAT_DAMAGE_LIMIT, M.bodytemperature + (50 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. return ..() /datum/reagent/consumable/ethanol/red_mead @@ -874,8 +874,8 @@ All effects don't start immediately, but rather get worse over time; the rate is glass_desc = "A beer so frosty, the air around it freezes." /datum/reagent/consumable/ethanol/iced_beer/on_mob_life(mob/living/M) - if(M.bodytemperature > 270) - M.bodytemperature = max(270, M.bodytemperature - (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if(M.bodytemperature > T0C) + M.bodytemperature = max(T0C, M.bodytemperature - (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. return ..() /datum/reagent/consumable/ethanol/grog diff --git a/code/modules/reagents/chemistry/reagents/drink_reagents.dm b/code/modules/reagents/chemistry/reagents/drink_reagents.dm index b62afb80c0..f86e15f10f 100644 --- a/code/modules/reagents/chemistry/reagents/drink_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/drink_reagents.dm @@ -264,8 +264,8 @@ M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) M.AdjustSleeping(-40, FALSE) - if (M.bodytemperature < 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (25 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (25 * TEMPERATURE_DAMAGE_COEFFICIENT)) if(holder.has_reagent("frostoil")) holder.remove_reagent("frostoil", 5) ..() @@ -289,8 +289,8 @@ M.AdjustSleeping(-20, FALSE) if(M.getToxLoss() && prob(20)) M.adjustToxLoss(-1, 0) - if (M.bodytemperature < 310) //310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL) //310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (20 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() . = 1 @@ -326,8 +326,8 @@ M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) M.AdjustSleeping(-40, FALSE) - if (M.bodytemperature > 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) M.Jitter(5) ..() . = 1 @@ -349,8 +349,8 @@ M.AdjustSleeping(-40, FALSE) if(M.getToxLoss() && prob(20)) M.adjustToxLoss(-1, 0) - if (M.bodytemperature > 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() . = 1 @@ -366,8 +366,8 @@ /datum/reagent/consumable/space_cola/on_mob_life(mob/living/M) M.drowsyness = max(0,M.drowsyness-5) - if (M.bodytemperature > 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() /datum/reagent/consumable/nuka_cola @@ -387,8 +387,8 @@ M.drowsyness = 0 M.AdjustSleeping(-40, FALSE) M.status_flags |= GOTTAGOFAST - if (M.bodytemperature > 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() . = 1 @@ -405,8 +405,8 @@ /datum/reagent/consumable/spacemountainwind/on_mob_life(mob/living/M) M.drowsyness = max(0,M.drowsyness-7) M.AdjustSleeping(-20, FALSE) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) M.Jitter(5) ..() . = 1 @@ -423,8 +423,8 @@ /datum/reagent/consumable/dr_gibb/on_mob_life(mob/living/M) M.drowsyness = max(0,M.drowsyness-6) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. ..() /datum/reagent/consumable/space_up @@ -439,8 +439,8 @@ /datum/reagent/consumable/space_up/on_mob_life(mob/living/M) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. ..() /datum/reagent/consumable/lemon_lime @@ -455,8 +455,8 @@ /datum/reagent/consumable/lemon_lime/on_mob_life(mob/living/M) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. ..() /datum/reagent/consumable/pwr_game @@ -470,8 +470,8 @@ glass_desc = "Goes well with a Vlad's salad." /datum/reagent/consumable/pwr_game/on_mob_life(mob/living/M) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. ..() /datum/reagent/consumable/shamblers @@ -485,8 +485,8 @@ glass_desc = "Mmm mm, shambly." /datum/reagent/consumable/shamblers/on_mob_life(mob/living/M) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310 is the normal bodytemp. 310.055 + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (8 * TEMPERATURE_DAMAGE_COEFFICIENT)) //310.15 is the normal bodytemp. ..() /datum/reagent/consumable/sodawater name = "Soda Water" @@ -501,8 +501,8 @@ /datum/reagent/consumable/sodawater/on_mob_life(mob/living/M) M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() /datum/reagent/consumable/tonic @@ -519,8 +519,8 @@ M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) M.AdjustSleeping(-40, FALSE) - if (M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() . = 1 @@ -553,8 +553,8 @@ M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) M.SetSleeping(0, FALSE) - if (M.bodytemperature < 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) M.Jitter(5) if(M.getBruteLoss() && prob(20)) M.heal_bodypart_damage(1,0, 0) @@ -575,8 +575,8 @@ M.dizziness = max(0,M.dizziness-5) M.drowsyness = max(0,M.drowsyness-3) M.SetSleeping(0, FALSE) - if (M.bodytemperature < 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) M.Jitter(5) if(M.getBruteLoss() && prob(20)) M.heal_bodypart_damage(1,0, 0) diff --git a/code/modules/reagents/chemistry/reagents/food_reagents.dm b/code/modules/reagents/chemistry/reagents/food_reagents.dm index bfa9ddc0a2..835bcaaad7 100644 --- a/code/modules/reagents/chemistry/reagents/food_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/food_reagents.dm @@ -371,8 +371,8 @@ glass_desc = "Tasty." /datum/reagent/consumable/hot_coco/on_mob_life(mob/living/M) - if (M.bodytemperature < 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (5 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() /datum/reagent/mushroomhallucinogen @@ -463,8 +463,8 @@ taste_description = "wet and cheap noodles" /datum/reagent/consumable/hot_ramen/on_mob_life(mob/living/M) - if (M.bodytemperature < 310)//310 is the normal bodytemp. 310.055 - M.bodytemperature = min(310, M.bodytemperature + (10 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (M.bodytemperature < BODYTEMP_NORMAL)//310.15 is the normal bodytemp. + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (10 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() /datum/reagent/consumable/hell_ramen diff --git a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm index 4f4bb6fdd1..d7750d5ff5 100644 --- a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm @@ -21,10 +21,10 @@ color = "#C8A5DC" // rgb: 200, 165, 220 /datum/reagent/medicine/leporazine/on_mob_life(mob/living/M) - if(M.bodytemperature > 310) - M.bodytemperature = max(310, M.bodytemperature - (40 * TEMPERATURE_DAMAGE_COEFFICIENT)) - else if(M.bodytemperature < 311) - M.bodytemperature = min(310, M.bodytemperature + (40 * TEMPERATURE_DAMAGE_COEFFICIENT)) + if(M.bodytemperature > BODYTEMP_NORMAL) + M.bodytemperature = max(BODYTEMP_NORMAL, M.bodytemperature - (40 * TEMPERATURE_DAMAGE_COEFFICIENT)) + else if(M.bodytemperature < (BODYTEMP_NORMAL + 1)) + M.bodytemperature = min(BODYTEMP_NORMAL, M.bodytemperature + (40 * TEMPERATURE_DAMAGE_COEFFICIENT)) ..() /datum/reagent/medicine/adminordrazine //An OP chemical for admins From dd5dc57043e1c4baa851c06f4b3e166db08bb7ee Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 7 Jan 2018 15:20:11 -0500 Subject: [PATCH 2/2] Update blood.dm --- code/modules/mob/living/blood.dm | 4 ---- 1 file changed, 4 deletions(-) diff --git a/code/modules/mob/living/blood.dm b/code/modules/mob/living/blood.dm index 2efc9a906c..9c3bb25da3 100644 --- a/code/modules/mob/living/blood.dm +++ b/code/modules/mob/living/blood.dm @@ -27,12 +27,8 @@ if(NOBLOOD in dna.species.species_traits) bleed_rate = 0 return -<<<<<<< HEAD - if(bodytemperature >= 225 && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. -======= if(bodytemperature >= TCRYO && !(has_disability(DISABILITY_NOCLONE))) //cryosleep or husked people do not pump the blood. ->>>>>>> 18892a0... Corrects inconsistent usage of 310.055, 310.15, & 310 as body temp (#34134) //Blood regeneration if there is some space if(blood_volume < BLOOD_VOLUME_NORMAL && !(NOHUNGER in dna.species.species_traits))