From bbe0413e2760e6a4da556ae50274a4e249cc4969 Mon Sep 17 00:00:00 2001 From: Lexanx <61974560+Lexanx@users.noreply.github.com> Date: Fri, 17 Nov 2023 20:39:20 +0300 Subject: [PATCH] Feat: limit IPC temperature (#674) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # Описание Фиксит предел нагрева ИПС без охлаждающего органа или со сломанным охлаждающим органном теперь ~950 цельсия. --------- Co-authored-by: SuhEugene <32931701+SuhEugene@users.noreply.github.com> --- code/modules/mob/living/carbon/human/human.dm | 2 ++ code/modules/organs/internal/cooling_system.dm | 5 +++-- code/modules/organs/internal/species/fbp.dm | 5 ++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 6fef891fcf..1d3add76ea 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -130,6 +130,8 @@ GLOBAL_LIST_EMPTY(compatable_genomes_owners) stat("Battery charge:", "[potato.get_charge()]/[potato.cell.maxcharge]") stat("Operating temperature:", "[round(bodytemperature-T0C)]°C") stat("Coolant remaining:","[coolant.get_coolant_remaining()]/[coolant.refrigerant_max]") + + if(back && istype(back,/obj/item/rig)) var/obj/item/rig/suit = back var/cell_status = "ERROR" diff --git a/code/modules/organs/internal/cooling_system.dm b/code/modules/organs/internal/cooling_system.dm index 017cae9539..782d39cb4b 100644 --- a/code/modules/organs/internal/cooling_system.dm +++ b/code/modules/organs/internal/cooling_system.dm @@ -94,9 +94,10 @@ refrigerant_rate += 40 /obj/item/organ/internal/cooling_system/proc/get_tempgain() + if(owner.bodytemperature > 950 CELSIUS) + return 0 if(refrigerant_rate > 0) - var/tempgain = refrigerant_rate - return tempgain + return refrigerant_rate /obj/item/organ/internal/cooling_system/proc/get_coolant_remaining() if(status & ORGAN_DEAD) diff --git a/code/modules/organs/internal/species/fbp.dm b/code/modules/organs/internal/species/fbp.dm index e5ce7d5731..6ef541ab5d 100644 --- a/code/modules/organs/internal/species/fbp.dm +++ b/code/modules/organs/internal/species/fbp.dm @@ -65,7 +65,10 @@ if(owner.species.name == SPECIES_IPC) var/obj/item/organ/internal/cooling_system/Cooling = owner.internal_organs_by_name[BP_COOLING] if(!(owner.internal_organs_by_name[BP_COOLING])) - owner.species.passive_temp_gain = 30 + if(owner.bodytemperature > 950 CELSIUS) + owner.species.passive_temp_gain = 0 + else + owner.species.passive_temp_gain = 30 else owner.species.passive_temp_gain = Cooling.get_tempgain()