Makes all global variables handled by the GLOB controller (#13152)

* Handlers converted, now to fix 3532 compile errors

* 3532 compile fixes later, got runtimes on startup

* Well the server loads now atleast

* Take 2

* Oops
This commit is contained in:
AffectedArc07
2020-03-20 21:56:37 -06:00
committed by GitHub
parent c8dbd0190e
commit 210f8badf4
667 changed files with 4243 additions and 4240 deletions
+8 -8
View File
@@ -261,7 +261,7 @@
//The list of slots by priority. equip_to_appropriate_slot() uses this list. Doesn't matter if a mob type doesn't have a slot.
var/list/slot_equipment_priority = list( \
GLOBAL_LIST_INIT(slot_equipment_priority, list( \
slot_back,\
slot_wear_pda,\
slot_wear_id,\
@@ -279,14 +279,14 @@ var/list/slot_equipment_priority = list( \
slot_tie,\
slot_l_store,\
slot_r_store\
)
))
//puts the item "W" into an appropriate slot in a human's inventory
//returns 0 if it cannot, 1 if successful
/mob/proc/equip_to_appropriate_slot(obj/item/W)
if(!istype(W)) return 0
for(var/slot in slot_equipment_priority)
for(var/slot in GLOB.slot_equipment_priority)
if(istype(W,/obj/item/storage/) && slot == slot_head) // Storage items should be put on the belt before the head
continue
if(equip_to_slot_if_possible(W, slot, 0, 1, 1)) //del_on_fail = 0; disable_warning = 0; redraw_mob = 1
@@ -297,7 +297,7 @@ var/list/slot_equipment_priority = list( \
/mob/proc/check_for_open_slot(obj/item/W)
if(!istype(W)) return 0
var/openslot = 0
for(var/slot in slot_equipment_priority)
for(var/slot in GLOB.slot_equipment_priority)
if(W.mob_check_equip(src, slot, 1) == 1)
openslot = 1
break
@@ -741,7 +741,7 @@ var/list/slot_equipment_priority = list( \
set name = "Respawn"
set category = "OOC"
if(!abandon_allowed)
if(!GLOB.abandon_allowed)
to_chat(usr, "<span class='warning'>Respawning is disabled.</span>")
return
@@ -1118,10 +1118,10 @@ var/list/slot_equipment_priority = list( \
/mob/proc/become_mouse()
var/timedifference = world.time - client.time_died_as_mouse
if(client.time_died_as_mouse && timedifference <= mouse_respawn_time * 600)
if(client.time_died_as_mouse && timedifference <= GLOB.mouse_respawn_time * 600)
var/timedifference_text
timedifference_text = time2text(mouse_respawn_time * 600 - timedifference,"mm:ss")
to_chat(src, "<span class='warning'>You may only spawn again as a mouse more than [mouse_respawn_time] minutes after your death. You have [timedifference_text] left.</span>")
timedifference_text = time2text(GLOB.mouse_respawn_time * 600 - timedifference,"mm:ss")
to_chat(src, "<span class='warning'>You may only spawn again as a mouse more than [GLOB.mouse_respawn_time] minutes after your death. You have [timedifference_text] left.</span>")
return
//find a viable mouse candidate