Filters allow air to pass through when not set to filter any gas (#31831)
* filters ignore air2 pressure if not filtering anything * filter air2 being limited does not stop movement from air1 to air3
This commit is contained in:
committed by
CitadelStationBot
parent
7f9d13ab42
commit
09330f079a
@@ -69,7 +69,7 @@
|
||||
|
||||
var/output_starting_pressure = air3.return_pressure()
|
||||
|
||||
if(output_starting_pressure >= target_pressure || air2.return_pressure() >= target_pressure)
|
||||
if(output_starting_pressure >= target_pressure)
|
||||
//No need to transfer if target is already full!
|
||||
return
|
||||
|
||||
@@ -106,7 +106,8 @@
|
||||
removed.gases[filter_type][MOLES] = 0
|
||||
removed.garbage_collect()
|
||||
|
||||
air2.merge(filtered_out)
|
||||
var/datum/gas_mixture/target = (air2.return_pressure() < target_pressure ? air2 : air1) //if there's no room for the filtered gas; just leave it in air1
|
||||
target.merge(filtered_out)
|
||||
|
||||
air3.merge(removed)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user