removes pipe construction cache (#32516)
This commit is contained in:
committed by
CitadelStationBot
parent
cde4d39989
commit
3c8eef9243
@@ -27,7 +27,7 @@ SUBSYSTEM_DEF(air)
|
||||
var/list/hotspots = list()
|
||||
var/list/networks = list()
|
||||
var/list/obj/machinery/atmos_machinery = list()
|
||||
var/list/pipe_construction_generation_cache = list()
|
||||
var/list/pipe_init_dirs_cache = list()
|
||||
|
||||
|
||||
|
||||
@@ -377,19 +377,16 @@ SUBSYSTEM_DEF(air)
|
||||
AM.build_network()
|
||||
CHECK_TICK
|
||||
|
||||
/datum/controller/subsystem/air/proc/get_pipe_cache(type, direction=NORTH)
|
||||
if(!pipe_construction_generation_cache[type])
|
||||
pipe_construction_generation_cache[type] = list()
|
||||
/datum/controller/subsystem/air/proc/get_init_dirs(type, dir)
|
||||
if(!pipe_init_dirs_cache[type])
|
||||
pipe_init_dirs_cache[type] = list()
|
||||
|
||||
if(!pipe_construction_generation_cache[type]["[direction]"])
|
||||
var/obj/machinery/atmospherics/cached = new type(null, FALSE, direction)
|
||||
pipe_construction_generation_cache[type]["[direction]"] = cached
|
||||
STOP_PROCESSING(SSmachines, cached)
|
||||
STOP_PROCESSING(SSfastprocess, cached)
|
||||
GLOB.machines -= cached
|
||||
|
||||
return pipe_construction_generation_cache[type]["[direction]"]
|
||||
if(!pipe_init_dirs_cache[type]["[dir]"])
|
||||
var/obj/machinery/atmospherics/temp = new type(null, FALSE, dir)
|
||||
pipe_init_dirs_cache[type]["[dir]"] = temp.GetInitDirections()
|
||||
qdel(temp)
|
||||
|
||||
return pipe_init_dirs_cache[type]["[dir]"]
|
||||
|
||||
#undef SSAIR_PIPENETS
|
||||
#undef SSAIR_ATMOSMACHINERY
|
||||
|
||||
Reference in New Issue
Block a user