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
+12 -12
View File
@@ -33,7 +33,7 @@
//teleport person to cell
M.Paralyse(5)
sleep(5) //so they black out before warping
M.loc = pick(prisonwarp)
M.loc = pick(GLOB.prisonwarp)
if(istype(M, /mob/living/carbon/human))
var/mob/living/carbon/human/prisoner = M
prisoner.equip_to_slot_or_del(new /obj/item/clothing/under/color/orange(prisoner), slot_w_uniform)
@@ -361,8 +361,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(G_found.mind.assigned_role=="Alien")
if(alert("This character appears to have been an alien. Would you like to respawn them as such?",,"Yes","No")=="Yes")
var/turf/T
if(xeno_spawn.len) T = pick(xeno_spawn)
else T = pick(latejoin)
if(GLOB.xeno_spawn.len) T = pick(GLOB.xeno_spawn)
else T = pick(GLOB.latejoin)
var/mob/living/carbon/alien/new_xeno
switch(G_found.mind.special_role)//If they have a mind, we can determine which caste they were.
@@ -381,14 +381,14 @@ Traitors and the like can also be revived with the previous role mostly intact.
message_admins("<span class='notice'>[key_name_admin(usr)] has respawned [new_xeno.key] as a filthy xeno.</span>", 1)
return //all done. The ghost is auto-deleted
var/mob/living/carbon/human/new_character = new(pick(latejoin))//The mob being spawned.
var/mob/living/carbon/human/new_character = new(pick(GLOB.latejoin))//The mob being spawned.
var/datum/data/record/record_found //Referenced to later to either randomize or not randomize the character.
if(G_found.mind && !G_found.mind.active) //mind isn't currently in use by someone/something
/*Try and locate a record for the person being respawned through data_core.
This isn't an exact science but it does the trick more often than not.*/
var/id = md5("[G_found.real_name][G_found.mind.assigned_role]")
for(var/datum/data/record/t in data_core.locked)
for(var/datum/data/record/t in GLOB.data_core.locked)
if(t.fields["id"]==id)
record_found = t//We shall now reference the record.
break
@@ -446,7 +446,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
else
new_character.mind.add_antag_datum(/datum/antagonist/traitor)
if("Wizard")
new_character.loc = pick(wizardstart)
new_character.loc = pick(GLOB.wizardstart)
//ticker.mode.learn_basic_spells(new_character)
SSticker.mode.equip_wizard(new_character)
if("Syndicate")
@@ -481,7 +481,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!record_found && new_character.mind.assigned_role != new_character.mind.special_role)//If there are no records for them. If they have a record, this info is already in there. Offstation special characters announced anyway.
//Power to the user!
if(alert(new_character,"Warning: No data core entry detected. Would you like to announce the arrival of this character by adding them to various databases, such as medical records?",,"No","Yes")=="Yes")
data_core.manifest_inject(new_character)
GLOB.data_core.manifest_inject(new_character)
if(alert(new_character,"Would you like an active AI to announce this character?",,"No","Yes")=="Yes")
call(/mob/new_player/proc/AnnounceArrival)(new_character, new_character.mind.assigned_role)
@@ -511,7 +511,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!istext(ckey)) return 0
var/alien_caste = input(usr, "Please choose which caste to spawn.","Pick a caste",null) as null|anything in list("Queen","Hunter","Sentinel","Drone","Larva")
var/obj/effect/landmark/spawn_here = xeno_spawn.len ? pick(xeno_spawn) : pick(latejoin)
var/obj/effect/landmark/spawn_here = GLOB.xeno_spawn.len ? pick(GLOB.xeno_spawn) : pick(GLOB.latejoin)
var/mob/living/carbon/alien/new_xeno
switch(alien_caste)
if("Queen") new_xeno = new /mob/living/carbon/alien/humanoid/queen/large(spawn_here)
@@ -623,11 +623,11 @@ Traitors and the like can also be revived with the previous role mostly intact.
if("Yes")
var/beepsound = input(usr, "What sound should the announcement make?", "Announcement Sound", "") as anything in MsgSound
command_announcement.Announce(input, customname, MsgSound[beepsound], , , type)
GLOB.command_announcement.Announce(input, customname, MsgSound[beepsound], , , type)
print_command_report(input, "[command_name()] Update")
if("No")
//same thing as the blob stuff - it's not public, so it's classified, dammit
command_announcer.autosay("A classified message has been printed out at all communication consoles.");
GLOB.command_announcer.autosay("A classified message has been printed out at all communication consoles.");
print_command_report(input, "Classified [command_name()] Update")
else
return
@@ -986,7 +986,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
else
job_string = "-"
key_string = H.key
if(job_string in command_positions)
if(job_string in GLOB.command_positions)
job_string = "<U>" + job_string + "</U>"
role_string = "-"
obj_count = 0
@@ -1025,7 +1025,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
else
job_string = "-"
key_string = H.key
if(job_string in command_positions)
if(job_string in GLOB.command_positions)
job_string = "<U>" + job_string + "</U>"
role_string = "-"
obj_count = 0