mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-22 19:47:47 +01:00
Conversion many Globals to Managed Globals (Part 1) (#17121)
* Conversion of some Globals to Managed Globals * Fix * for later --------- Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
@@ -307,7 +307,7 @@
|
||||
// Update manifest'
|
||||
if(data_core)
|
||||
data_core.get_manifest_list()
|
||||
data["manifest"] = PDA_Manifest
|
||||
data["manifest"] = GLOB.PDA_Manifest
|
||||
data["mapRef"] = map_name
|
||||
return data
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
//
|
||||
// Allows ghosts to roleplay with crewmembers without having to commit to joining the round, and also allows communications between two communicators.
|
||||
|
||||
var/global/list/obj/item/communicator/all_communicators = list()
|
||||
GLOBAL_LIST_EMPTY_TYPED(all_communicators, /obj/item/communicator)
|
||||
|
||||
// List of core tabs the communicator can switch to
|
||||
#define HOMETAB 1
|
||||
@@ -97,8 +97,8 @@ var/global/list/obj/item/communicator/all_communicators = list()
|
||||
// assign the device to the holder's name automatically in a spectacularly shitty way.
|
||||
/obj/item/communicator/Initialize(mapload)
|
||||
. = ..()
|
||||
all_communicators += src
|
||||
all_communicators = sortAtom(all_communicators)
|
||||
GLOB.all_communicators += src
|
||||
GLOB.all_communicators = sortAtom(GLOB.all_communicators)
|
||||
node = get_exonet_node()
|
||||
START_PROCESSING(SSobj, src)
|
||||
camera = new(src)
|
||||
@@ -187,7 +187,7 @@ var/global/list/obj/item/communicator/all_communicators = list()
|
||||
src.known_devices.Cut()
|
||||
if(!get_connection_to_tcomms()) //If the network's down, we can't see anything.
|
||||
return
|
||||
for(var/obj/item/communicator/comm in all_communicators)
|
||||
for(var/obj/item/communicator/comm in GLOB.all_communicators)
|
||||
if(!comm || !comm.exonet || !comm.exonet.address || comm.exonet.address == src.exonet.address) //Don't add addressless devices, and don't add ourselves.
|
||||
continue
|
||||
src.known_devices |= comm
|
||||
@@ -314,7 +314,7 @@ var/global/list/obj/item/communicator/all_communicators = list()
|
||||
node = null
|
||||
|
||||
//Clean up references that might point at us
|
||||
all_communicators -= src
|
||||
GLOB.all_communicators -= src
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
listening_objects.Remove(src)
|
||||
QDEL_NULL(camera)
|
||||
|
||||
@@ -140,7 +140,7 @@
|
||||
return
|
||||
|
||||
var/list/choices = list()
|
||||
for(var/obj/item/communicator/comm in all_communicators)
|
||||
for(var/obj/item/communicator/comm in GLOB.all_communicators)
|
||||
if(!comm.network_visibility || !comm.exonet || !comm.exonet.address)
|
||||
continue
|
||||
choices.Add(comm)
|
||||
|
||||
@@ -306,7 +306,7 @@
|
||||
return
|
||||
|
||||
var/list/choices = list()
|
||||
for(var/obj/item/communicator/comm in all_communicators)
|
||||
for(var/obj/item/communicator/comm in GLOB.all_communicators)
|
||||
if(!comm.network_visibility || !comm.exonet || !comm.exonet.address)
|
||||
continue
|
||||
choices.Add(comm)
|
||||
|
||||
@@ -194,7 +194,7 @@ var/global/mob/living/carbon/human/dummy/mannequin/sleevemate_mob
|
||||
|
||||
//The actual options
|
||||
if(href_list["mindscan"])
|
||||
if(!target.mind || (target.mind.name in prevent_respawns))
|
||||
if(!target.mind || (target.mind.name in GLOB.prevent_respawns))
|
||||
to_chat(usr,span_warning("Target seems totally braindead."))
|
||||
return
|
||||
|
||||
@@ -231,7 +231,7 @@ var/global/mob/living/carbon/human/dummy/mannequin/sleevemate_mob
|
||||
return
|
||||
|
||||
if(href_list["mindsteal"])
|
||||
if(!target.mind || (target.mind.name in prevent_respawns))
|
||||
if(!target.mind || (target.mind.name in GLOB.prevent_respawns))
|
||||
to_chat(usr,span_warning("Target seems totally braindead."))
|
||||
return
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
p.name = "Security Citation: [ticket_name]"
|
||||
playsound(user, 'sound/items/ticket_printer.ogg', 75, 1)
|
||||
|
||||
security_printer_tickets |= details
|
||||
GLOB.security_printer_tickets |= details
|
||||
log_and_message_admins("has issued '[ticket_name]' a security citation: \"[details]\"", user)
|
||||
last_print = world.time
|
||||
|
||||
|
||||
@@ -108,8 +108,8 @@ var/datum/uplink_random_selection/all_uplink_selection = new/datum/uplink_random
|
||||
|
||||
#ifdef DEBUG
|
||||
/proc/debug_uplink_purchage_log()
|
||||
for(var/antag_type in all_antag_types)
|
||||
var/datum/antagonist/A = all_antag_types[antag_type]
|
||||
for(var/antag_type in GLOB.all_antag_types)
|
||||
var/datum/antagonist/A = GLOB.all_antag_types[antag_type]
|
||||
A.print_player_summary()
|
||||
|
||||
/proc/debug_uplink_item_assoc_list()
|
||||
|
||||
Reference in New Issue
Block a user