[TGUI] Adds a HUD management UI for ghosts (#16302)

* ghost hud panel

* changes up UI a bit, fix conflicts

* no resizable
This commit is contained in:
SteelSlayer
2021-07-13 08:19:41 -05:00
committed by GitHub
parent e98d81ac46
commit 5124f5ef7e
10 changed files with 147 additions and 89 deletions
+2 -5
View File
@@ -278,11 +278,9 @@
var/action=""
if(config.antag_hud_allowed)
for(var/mob/dead/observer/g in get_ghosts())
if(!g.client.holder) //Remove the verb from non-admin ghosts
g.verbs -= /mob/dead/observer/verb/toggle_antagHUD
if(g.antagHUD)
g.antagHUD = FALSE // Disable it on those that have it enabled
g.has_enabled_antagHUD = 2 // We'll allow them to respawn
g.has_enabled_antagHUD = FALSE // We'll allow them to respawn
to_chat(g, "<span class='danger'>The Administrator has disabled AntagHUD </span>")
config.antag_hud_allowed = 0
to_chat(src, "<span class='danger'>AntagHUD usage has been disabled</span>")
@@ -290,7 +288,6 @@
else
for(var/mob/dead/observer/g in get_ghosts())
if(!g.client.holder) // Add the verb back for all non-admin ghosts
g.verbs += /mob/dead/observer/verb/toggle_antagHUD
to_chat(g, "<span class='boldnotice'>The Administrator has enabled AntagHUD </span>")// Notify all observers they can now use AntagHUD
config.antag_hud_allowed = 1
@@ -321,7 +318,7 @@
to_chat(g, "<span class='danger'>The administrator has placed restrictions on joining the round if you use AntagHUD</span>")
to_chat(g, "<span class='danger'>Your AntagHUD has been disabled, you may choose to re-enabled it but will be under restrictions </span>")
g.antagHUD = FALSE
g.has_enabled_antagHUD = 0
g.has_enabled_antagHUD = FALSE
action = "placed restrictions"
config.antag_hud_restricted = 1
to_chat(src, "<span class='danger'>AntagHUD restrictions have been enabled</span>")