Merge pull request #36899 from vuonojenmustaturska/quantumsolace

Fixes an edge case with atmos gas mixture garbage collection
This commit is contained in:
Jordan Brown
2018-04-02 09:30:54 -04:00
committed by CitadelStationBot
parent 7de2934a26
commit 5b2df864e3
@@ -68,7 +68,7 @@ GLOBAL_LIST_INIT(nonreactive_gases, typecacheof(list(/datum/gas/oxygen, /datum/g
/datum/gas_mixture/proc/garbage_collect(list/tocheck)
var/list/cached_gases = gases
for(var/id in (tocheck || cached_gases))
if(cached_gases[id][MOLES] <= 0 && cached_gases[id][ARCHIVE] <= 0)
if(QUANTIZE(cached_gases[id][MOLES]) <= 0 && QUANTIZE(cached_gases[id][ARCHIVE]) <= 0)
cached_gases -= id
//PV = nRT