[MIRROR] More globals (#12530)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2026-03-15 19:26:29 +01:00
committed by GitHub
co-authored by Kashargul
parent de8fed65df
commit 4f5dce5ebe
238 changed files with 984 additions and 1026 deletions
+4 -4
View File
@@ -1,4 +1,4 @@
var/list/mining_overlay_cache = list()
GLOBAL_LIST_EMPTY(mining_overlay_cache)
/**********************Mineral deposits**************************/
/turf/unsimulated/mineral
@@ -194,7 +194,7 @@ var/list/mining_overlay_cache = list()
/turf/simulated/mineral/proc/get_cached_border(var/cache_id, var/direction, var/icon_file, var/icon_state, var/offset = 32)
//Cache miss
if(!mining_overlay_cache["[cache_id]_[direction]"])
if(!GLOB.mining_overlay_cache["[cache_id]_[direction]"])
var/image/new_cached_image = image(icon_state, dir = direction, layer = ABOVE_TURF_LAYER)
switch(direction)
if(NORTH)
@@ -205,11 +205,11 @@ var/list/mining_overlay_cache = list()
new_cached_image.pixel_x = offset
if(WEST)
new_cached_image.pixel_x = -offset
mining_overlay_cache["[cache_id]_[direction]"] = new_cached_image
GLOB.mining_overlay_cache["[cache_id]_[direction]"] = new_cached_image
return new_cached_image
//Cache hit
return mining_overlay_cache["[cache_id]_[direction]"]
return GLOB.mining_overlay_cache["[cache_id]_[direction]"]
/turf/simulated/mineral/Initialize(mapload)
. = ..()