mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Properly defines a few global vars (#7948)
Co-authored-by: Selis <selis@xynolabs.com>
This commit is contained in:
@@ -1,13 +1,15 @@
|
||||
var/global_vantag_hud = 0
|
||||
GLOBAL_VAR_INIT(global_vantag_hud, 0)
|
||||
|
||||
/client/proc/toggle_vantag_hud_global(var/mob/target as mob)
|
||||
/client/proc/toggle_vantag_hud_global(mob/target as mob)
|
||||
set category = "Fun"
|
||||
set name = "Toggle Global Event HUD"
|
||||
set desc = "Give everyone the Event HUD."
|
||||
|
||||
global_vantag_hud = !global_vantag_hud
|
||||
if(global_vantag_hud)
|
||||
GLOB.global_vantag_hud = !GLOB.global_vantag_hud
|
||||
if(GLOB.global_vantag_hud)
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
if(L.ckey)
|
||||
L.vantag_hud = TRUE
|
||||
L.recalculate_vis()
|
||||
L.recalculate_vis()
|
||||
|
||||
to_chat(src, "<span class='warning'>Global Event HUD has been turned [GLOB.global_vantag_hud ? "on" : "off"].</span>")
|
||||
|
||||
Reference in New Issue
Block a user