More globals (#19247)

* More globals

* planets

* .

* .

* Update jukebox.dm

* Fix timer callback syntax in jukebox.dm

* .
This commit is contained in:
Kashargul
2026-03-15 02:54:17 -04:00
committed by GitHub
parent 24d023dfa8
commit 72628d226c
210 changed files with 941 additions and 990 deletions
+8 -8
View File
@@ -17,7 +17,7 @@
// If hooded, have [kit_icon]_suit_t in both files for the hood-up version.
// If not using the default overlay, have [kit_icon]_light in both files for custom light overlays.
/var/list/custom_items = list()
GLOBAL_LIST_INIT(custom_items, load_custom_items())
/datum/custom_item
var/assoc_key
@@ -118,8 +118,8 @@
return t_icon
// Parses the config file into the custom_items list.
/hook/startup/proc/load_custom_items()
/proc/load_custom_items()
var/list/all_custom_items = list()
var/datum/custom_item/current_data
for(var/line in splittext(file2text("config/custom_items.txt"), "\n"))
@@ -129,9 +129,9 @@
if(findtext(line, "{", 1, 2) || findtext(line, "}", 1, 2)) // New block!
if(current_data && current_data.assoc_key)
if(!custom_items[current_data.assoc_key])
custom_items[current_data.assoc_key] = list()
var/list/L = custom_items[current_data.assoc_key]
if(!all_custom_items[current_data.assoc_key])
all_custom_items[current_data.assoc_key] = list()
var/list/L = all_custom_items[current_data.assoc_key]
L |= current_data
current_data = null
@@ -173,11 +173,11 @@
current_data.kit_icon = field_data
if("additional_data")
current_data.additional_data = field_data
return 1
return all_custom_items
//gets the relevant list for the key from the listlist if it exists, check to make sure they are meant to have it and then calls the giving function
/proc/equip_custom_items(mob/living/carbon/human/M)
var/list/key_list = custom_items[M.ckey]
var/list/key_list = GLOB.custom_items[M.ckey]
if(!key_list || key_list.len < 1)
return