From 241e9cf1115433db2ca660dee501f76e1811e23a Mon Sep 17 00:00:00 2001 From: Ghilker <42839747+Ghilker@users.noreply.github.com> Date: Tue, 15 Dec 2020 19:11:12 +0100 Subject: [PATCH] fix infinite gas production (#55510) No more infinite gas production due to a gas_mixture not clearing up --- .../atmospherics/machinery/components/fusion/hypertorus.dm | 7 ++----- tgstation.dme | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/code/modules/atmospherics/machinery/components/fusion/hypertorus.dm b/code/modules/atmospherics/machinery/components/fusion/hypertorus.dm index bd8ce1071c4..29b2925b695 100644 --- a/code/modules/atmospherics/machinery/components/fusion/hypertorus.dm +++ b/code/modules/atmospherics/machinery/components/fusion/hypertorus.dm @@ -186,8 +186,6 @@ var/datum/gas_mixture/internal_fusion ///Stores the information of the moderators gasmix var/datum/gas_mixture/moderator_internal - ///Stores the information of the output gasmix - var/datum/gas_mixture/internal_output ///Set the filtering type of the waste remove var/filter_type = null @@ -311,7 +309,6 @@ internal_fusion = new internal_fusion.assert_gases(/datum/gas/hydrogen, /datum/gas/tritium) moderator_internal = new - internal_output = new radio = new(src) radio.keyslot = new radio_key @@ -325,8 +322,6 @@ internal_fusion = null if(moderator_internal) moderator_internal = null - if(internal_output) - internal_output = null if(linked_input) QDEL_NULL(linked_input) if(linked_output) @@ -930,6 +925,7 @@ else internal_fusion.temperature -= heat_limiter_modifier * 0.01 * delta_time + var/datum/gas_mixture/internal_output //gas consumption and production if(check_fuel()) var/fuel_consumption = clamp((fuel_injection_rate * 0.001) * 5 * power_level, 0.05, 30) * delta_time @@ -1104,6 +1100,7 @@ internal_remove = internal_fusion.remove_specific(/datum/gas/antinoblium, internal_fusion.gases[/datum/gas/antinoblium][MOLES] * 0.05) linked_output.airs[1].merge(internal_remove) internal_fusion.garbage_collect() + moderator_internal.garbage_collect() //Update pipenets diff --git a/tgstation.dme b/tgstation.dme index c25bb55c0eb..aa3f35fb3eb 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -398,8 +398,8 @@ #include "code\datums\ai\_ai_behavior.dm" #include "code\datums\ai\_ai_controller.dm" #include "code\datums\ai\generic_actions.dm" -#include "code\datums\ai\monkey\monkey_controller.dm" #include "code\datums\ai\monkey\monkey_behaviors.dm" +#include "code\datums\ai\monkey\monkey_controller.dm" #include "code\datums\atmosphere\_atmosphere.dm" #include "code\datums\atmosphere\planetary.dm" #include "code\datums\brain_damage\brain_trauma.dm"