From 1f46248c2c5200eccdcc7d4fdb1071d87d055adb Mon Sep 17 00:00:00 2001 From: SiliconMain <65544193+SiliconMain@users.noreply.github.com> Date: Wed, 28 Oct 2020 09:27:59 -0500 Subject: [PATCH 1/5] Update mask.dm --- modular_citadel/code/modules/client/loadout/mask.dm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modular_citadel/code/modules/client/loadout/mask.dm b/modular_citadel/code/modules/client/loadout/mask.dm index 0d7e32552e..9468c9303d 100644 --- a/modular_citadel/code/modules/client/loadout/mask.dm +++ b/modular_citadel/code/modules/client/loadout/mask.dm @@ -14,3 +14,9 @@ name = "Joy mask" path = /obj/item/clothing/mask/joy cost = 3 + +/datum/gear/mask/gas + name = "Gas Mask" + path = /obj/item/clothing/mask/gas + cost = 2 + restricted_roles = list("Chief Engineer", "Atmospheric Technician", "Station Engineer") //*shrug From cc1d498ab6e4759387fb5e8c1f3870c25931e4d8 Mon Sep 17 00:00:00 2001 From: CitadelStationBot Date: Thu, 29 Oct 2020 16:05:21 -0500 Subject: [PATCH 2/5] Automatic changelog generation for PR #13636 [ci skip] --- html/changelogs/AutoChangeLog-pr-13636.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-13636.yml diff --git a/html/changelogs/AutoChangeLog-pr-13636.yml b/html/changelogs/AutoChangeLog-pr-13636.yml new file mode 100644 index 0000000000..75124f759f --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-13636.yml @@ -0,0 +1,4 @@ +author: "SiliconMain" +delete-after: True +changes: + - tweak: "Engi department has gas masks in loadout" From 75280c9705938381eeaf9dd359c67ee5e62ce8fb Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 29 Oct 2020 20:27:47 -0400 Subject: [PATCH 3/5] patches recently-found atmos circuit exploit --- .../integrated_electronics/subtypes/atmospherics.dm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/code/modules/integrated_electronics/subtypes/atmospherics.dm b/code/modules/integrated_electronics/subtypes/atmospherics.dm index d9a18bc509..beae1744c4 100644 --- a/code/modules/integrated_electronics/subtypes/atmospherics.dm +++ b/code/modules/integrated_electronics/subtypes/atmospherics.dm @@ -115,10 +115,10 @@ source_air = air_contents // Move gas from one place to another - move_gas(source_air, target_air) + move_gas(source_air, target_air, (istype(target, /obj/item/tank) ? target : null)) air_update_turf() -/obj/item/integrated_circuit/atmospherics/pump/proc/move_gas(datum/gas_mixture/source_air, datum/gas_mixture/target_air) +/obj/item/integrated_circuit/atmospherics/pump/proc/move_gas(datum/gas_mixture/source_air, datum/gas_mixture/target_air, obj/item/tank/snowflake) // No moles = nothing to pump if(source_air.total_moles() <= 0 || target_air.return_pressure() >= PUMP_MAX_PRESSURE) @@ -132,7 +132,10 @@ if(pressure_delta > 0.1) var/transfer_moles = (pressure_delta*target_air.return_volume()/(source_air.return_temperature() * R_IDEAL_GAS_EQUATION))*PUMP_EFFICIENCY var/datum/gas_mixture/removed = source_air.remove(transfer_moles) - target_air.merge(removed) + if(istype(snowflake)) //Snowflake check for tanks specifically, because tank ruptures are handled in a very snowflakey way that expects all tank interactions to be handled via the tank's procs + snowflake.assume_air(removed) + else + target_air.merge(removed) // - volume pump - // **Works** From 5d79ea344175c37dade56d3451491b56f8eeba53 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 29 Oct 2020 21:00:56 -0400 Subject: [PATCH 4/5] forgot volume pumps, fuk --- .../integrated_electronics/subtypes/atmospherics.dm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/code/modules/integrated_electronics/subtypes/atmospherics.dm b/code/modules/integrated_electronics/subtypes/atmospherics.dm index beae1744c4..699cb0e6e7 100644 --- a/code/modules/integrated_electronics/subtypes/atmospherics.dm +++ b/code/modules/integrated_electronics/subtypes/atmospherics.dm @@ -168,7 +168,7 @@ direction = SOURCE_TO_TARGET target_pressure = min(PUMP_MAX_VOLUME,abs(new_amount)) -/obj/item/integrated_circuit/atmospherics/pump/volume/move_gas(datum/gas_mixture/source_air, datum/gas_mixture/target_air) +/obj/item/integrated_circuit/atmospherics/pump/volume/move_gas(datum/gas_mixture/source_air, datum/gas_mixture/target_air, obj/item/tank/snowflake) // No moles = nothing to pump if(source_air.total_moles() <= 0) return @@ -185,7 +185,10 @@ var/datum/gas_mixture/removed = source_air.remove_ratio(transfer_ratio * PUMP_EFFICIENCY) - target_air.merge(removed) + if(istype(snowflake)) + snowflake.assume_air(removed) + else + target_air.merge(removed) // - gas vent - // **works** From b11947a468c9f4c418348493cca8d5fc71e55986 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 29 Oct 2020 21:31:06 -0400 Subject: [PATCH 5/5] covers filters and mixers as well --- .../subtypes/atmospherics.dm | 29 +++++++++++++++---- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/code/modules/integrated_electronics/subtypes/atmospherics.dm b/code/modules/integrated_electronics/subtypes/atmospherics.dm index 699cb0e6e7..26ac3080de 100644 --- a/code/modules/integrated_electronics/subtypes/atmospherics.dm +++ b/code/modules/integrated_electronics/subtypes/atmospherics.dm @@ -385,9 +385,20 @@ obj/item/integrated_circuit/atmospherics/connector/portableConnectorReturnAir() removed.set_moles(filtered_gas, 0) //Check if the pressure is high enough to put stuff in filtered, or else just put it back in the source - var/datum/gas_mixture/target = (filtered_air.return_pressure() < target_pressure ? filtered_air : source_air) - target.merge(filtered_out) - contaminated_air.merge(removed) + if(filtered_air.return_pressure() < target_pressure) + if(istype(filtered, /obj/item/tank)) + filtered.assume_air(filtered_out) + else + filtered_air.merge(filtered_out) + else + if(istype(source, /obj/item/tank)) + source.assume_air(filtered_out) + else + source_air.merge(filtered_out) + if(istype(contaminants, /obj/item/tank)) + contaminants.assume_air(removed) + else + contaminated_air.merge(removed) /obj/item/integrated_circuit/atmospherics/pump/filter/Initialize() @@ -455,10 +466,18 @@ obj/item/integrated_circuit/atmospherics/connector/portableConnectorReturnAir() if(transfer_moles <= 0) return + var/snowflakecheck = istype(gas_output, /obj/item/tank) + var/datum/gas_mixture/mix = source_1_gases.remove(transfer_moles * gas_percentage) - output_gases.merge(mix) + if(snowflakecheck) + gas_output.assume_air(mix) + else + output_gases.merge(mix) mix = source_2_gases.remove(transfer_moles * (1-gas_percentage)) - output_gases.merge(mix) + if(snowflakecheck) + gas_output.assume_air(mix) + else + output_gases.merge(mix) // - integrated tank - // **works**