[MIRROR] More globals (#12341)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2026-01-30 20:27:42 +01:00
committed by GitHub
co-authored by Kashargul
parent 38e634dce7
commit d031fa3c4e
76 changed files with 267 additions and 257 deletions
+5 -5
View File
@@ -480,7 +480,7 @@
user.position_hud_item(src,slot)
if(user.client) user.client.screen |= src
if(user.pulling == src) user.stop_pulling()
if(("[slot]" in slot_flags_enumeration) && (slot_flags & slot_flags_enumeration["[slot]"]))
if(("[slot]" in GLOB.slot_flags_enumeration) && (slot_flags & GLOB.slot_flags_enumeration["[slot]"]))
if(equip_sound && !muffled_by_belly(user))
playsound(src, equip_sound, 20, preference = /datum/preference/toggle/pickup_sounds)
else if(!muffled_by_belly(user))
@@ -518,7 +518,7 @@
return
//Defines which slots correspond to which slot flags
var/list/global/slot_flags_enumeration = list(
GLOBAL_LIST_INIT(slot_flags_enumeration, list(
"[slot_wear_mask]" = SLOT_MASK,
"[slot_back]" = SLOT_BACK,
"[slot_wear_suit]" = SLOT_OCLOTHING,
@@ -532,7 +532,7 @@ var/list/global/slot_flags_enumeration = list(
"[slot_w_uniform]" = SLOT_ICLOTHING,
"[slot_wear_id]" = SLOT_ID,
"[slot_tie]" = SLOT_TIE,
)
))
//the mob M is attempting to equip this item into the slot passed through as 'slot'. Return 1 if it can do this and 0 if it can't.
//If you are making custom procs but would like to retain partial or complete functionality of this one, include a 'return ..()' to where you want this to happen.
@@ -553,8 +553,8 @@ var/list/global/slot_flags_enumeration = list(
return 0
//First check if the item can be equipped to the desired slot.
if("[slot]" in slot_flags_enumeration)
var/req_flags = slot_flags_enumeration["[slot]"]
if("[slot]" in GLOB.slot_flags_enumeration)
var/req_flags = GLOB.slot_flags_enumeration["[slot]"]
if(!(req_flags & slot_flags))
return 0
@@ -1,4 +1,4 @@
var/global/mob/living/carbon/human/dummy/mannequin/sleevemate_mob
GLOBAL_DATUM(sleevemate_mob, /mob/living/carbon/human/dummy/mannequin)
//SleeveMate!
/obj/item/sleevemate
@@ -295,15 +295,15 @@ var/global/mob/living/carbon/human/dummy/mannequin/sleevemate_mob
return //Uninstalled it?
//Lazzzyyy.
if(!sleevemate_mob)
sleevemate_mob = new()
if(!GLOB.sleevemate_mob)
GLOB.sleevemate_mob = new()
if(!(soulcatcher_pref_flags & SOULCATCHER_ALLOW_CAPTURE))
to_chat(usr,span_notice("[sleevemate_mob] can't be transferred!"))
to_chat(usr,span_notice("[GLOB.sleevemate_mob] can't be transferred!"))
return
put_mind(sleevemate_mob)
SC.catch_mob(sleevemate_mob)
put_mind(GLOB.sleevemate_mob)
SC.catch_mob(GLOB.sleevemate_mob)
to_chat(usr,span_notice("Mind transferred into Soulcatcher!"))
if(href_list["mindupload"])
+4 -3
View File
@@ -5,7 +5,7 @@
#define RMS_STONE 5
#define RMS_RAND 6
var/list/RMS_random_malfunction = list(/obj/item/fbp_backup_cell,
GLOBAL_LIST_INIT(RMS_random_malfunction, list(/obj/item/fbp_backup_cell,
/obj/item/trash/rkibble,
/obj/item/clothing/gloves/bluespace/deluxe,
/obj/item/flame/lighter/supermatter/syndismzippo,
@@ -20,7 +20,8 @@ var/list/RMS_random_malfunction = list(/obj/item/fbp_backup_cell,
/obj/item/clothing/shoes/clown_shoes,
/obj/item/clothing/mask/gas/clown_hat,
/obj/item/pda/clown,
/mob/living/simple_mob/vore/catgirl)
/mob/living/simple_mob/vore/catgirl
))
/obj/item/rms
name = "Rapid Material Synthesizer"
@@ -135,7 +136,7 @@ var/list/RMS_random_malfunction = list(/obj/item/fbp_backup_cell,
if(do_after(user, 5, target = A))
if(overcharge)
if(prob(5)) //5% chance for malfunction
var/thing_to_spawn = pick(RMS_random_malfunction)
var/thing_to_spawn = pick(GLOB.RMS_random_malfunction)
product = new thing_to_spawn
else
product = choose_overcharge(user)
@@ -142,7 +142,7 @@
/obj/item/card/id/Initialize(mapload)
. = ..()
var/datum/job/J = job_master.GetJob(rank)
var/datum/job/J = GLOB.job_master.GetJob(rank)
if(J)
access = J.get_access()
+2 -2
View File
@@ -52,10 +52,10 @@
//Chaplain null rod removes ALL unholy traits.
REMOVE_TRAITS_IN(M, UNHOLY_TRAIT)
if(cult && (M.mind in cult.current_antagonists) && prob(33))
if(GLOB.cult && (M.mind in GLOB.cult.current_antagonists) && prob(33))
to_chat(M, span_danger("The power of [src] clears your mind of the cult's influence!"))
to_chat(user, span_danger("You wave [src] over [M]'s head and see their eyes become clear, their mind returning to normal."))
cult.remove_antagonist(M.mind)
GLOB.cult.remove_antagonist(M.mind)
M.visible_message(span_danger("\The [user] waves \the [src] over \the [M]'s head."))
else
to_chat(user, span_danger("The rod appears to do nothing."))
@@ -170,7 +170,7 @@
new_character.mind.loaded_from_ckey = picked_ckey
new_character.mind.loaded_from_slot = picked_slot
job_master.EquipRank(new_character, JOB_MAINT_LURKER, 1)
GLOB.job_master.EquipRank(new_character, JOB_MAINT_LURKER, 1)
for(var/lang in new_character.client.prefs.alternate_languages)
var/datum/language/chosen_language = GLOB.all_languages[lang]
@@ -131,7 +131,7 @@
new_character.mind.loaded_from_ckey = picked_ckey
new_character.mind.loaded_from_slot = picked_slot
job_master.EquipRank(new_character, JOB_MAINT_LURKER, 1)
GLOB.job_master.EquipRank(new_character, JOB_MAINT_LURKER, 1)
for(var/lang in new_character.client.prefs.alternate_languages)
var/datum/language/chosen_language = GLOB.all_languages[lang]