Fixes almost all the bugs that I should have fixed six months ago (#18323)

* Fixes scanners properly this time

* Just some code cleanup

* Fixes HE pipes being fast

* Fixes a bug that, for once, was not my fault

* Bugs both my fault and otherwise

* Why didn't I just do this in the first place?

* Turns out I wasn't the one who did the last one

* Simplification

* This was just completely incorrect

* Just style, which should have been included in the last commit

* Use new proc

* Simplification. This is still fucked up by the way

* And fixes a bug with freezers. This behavior is still fucked up though

* Woah fuck I nearly missed this. Freezers no longer have the volume of an entire zone.

* This should really be based on partial pressure, but that's a problem for another day

* There was never a reason to remove the air since thermal energy change is scale-invariant, dummy

* I THINK this is as correct as it's going to get without a rewrite

* Reading this hurt me

* Forgot this one, long ago

* Fuck lifecode

* Various stuff

* Removing the air is still unnecessary

* Fixes these not updating the zones, but these should really adjust thermal energy rather than absolute temperature

* Fixes these to update and use pressure

* This one gets special mention for breaking any existing sleeping agent in the area

* Whoops. I really need to standardize this.

* For fuck's sake

* I was going to make it adjust the environment temperature directly but looking at the code hurt my skull

* Not really deserving of its own commit but R-UST is next

* Existence is pain

* Fixes compile errors and a trillion runtimes
The gas_mixture procs should probably never return null, but oh well

* You're solving for the wrong n
This commit is contained in:
Exxion
2018-05-22 05:39:19 -04:00
committed by jknpj
parent 1171796a43
commit e7c24c311c
58 changed files with 208 additions and 266 deletions

View File

@@ -122,12 +122,7 @@
if(!gas)
return null
var/datum/gas_mixture/newgas = new/datum/gas_mixture()
newgas.oxygen = gas.oxygen
newgas.carbon_dioxide = gas.carbon_dioxide
newgas.nitrogen = gas.nitrogen
newgas.toxins = gas.toxins
newgas.volume = gas.volume
newgas.temperature = gas.temperature
newgas.copy_from(gas)
if(newgas.temperature <= target_temp)
return
@@ -135,6 +130,7 @@
newgas.temperature -= cooling_power
else
newgas.temperature = target_temp
newgas.update_values()
return newgas
/obj/structure/closet/crate/freezer/surgery