Fixes Airlocks losing pressure (Baystation Fix) And fixes the icon pathing

-Allows your code to be easily used by fixing the forensics icon
pathing.
-Ports a fix from Baystation's 12 Developer atlantiscze
(As well as testing done by Dennok on BS12 and Mango and Myself for
testing on Aurora Code)
This commit is contained in:
Michael Abbey
2015-12-30 11:55:53 -05:00
parent b62a93d17e
commit e0611edac3
4 changed files with 65 additions and 81 deletions
@@ -120,14 +120,14 @@
if(pressure_delta > 0.5)
if(pump_direction) //internal -> external
if (node1 && (environment.temperature || air1.temperature))
var/transfer_moles = calculate_transfer_moles(air1, environment)
var/transfer_moles = calculate_transfer_moles(air1, environment, pressure_delta)
power_draw = pump_gas(src, air1, environment, transfer_moles, power_rating)
if(power_draw >= 0 && network1)
network1.update = 1
else //external -> internal
if (node2 && (environment.temperature || air2.temperature))
var/transfer_moles = calculate_transfer_moles(environment, air2, (network2)? network2.volume : 0)
var/transfer_moles = calculate_transfer_moles(environment, air2, pressure_delta, (network2)? network2.volume : 0)
//limit flow rate from turfs
transfer_moles = min(transfer_moles, environment.total_moles*air2.volume/environment.volume) //group_multiplier gets divided out here