mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-17 10:03:50 +01:00
Removes ghosts from the HUDs when they get deleted (#17218)
This commit is contained in:
@@ -92,6 +92,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
..()
|
||||
|
||||
/mob/dead/observer/Destroy()
|
||||
toggle_all_huds_off()
|
||||
if(ghostimage)
|
||||
GLOB.ghost_images -= ghostimage
|
||||
QDEL_NULL(ghostimage)
|
||||
@@ -348,6 +349,17 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
for(var/datum/atom_hud/antag/H in GLOB.huds)
|
||||
H.add_hud_to(src)
|
||||
|
||||
/**
|
||||
* Toggles off all HUDs for the ghost player.
|
||||
*/
|
||||
/mob/dead/observer/proc/toggle_all_huds_off()
|
||||
remove_the_hud(DATA_HUD_DIAGNOSTIC_ADVANCED)
|
||||
remove_the_hud(DATA_HUD_SECURITY_ADVANCED)
|
||||
remove_the_hud(DATA_HUD_MEDICAL_ADVANCED)
|
||||
antagHUD = FALSE
|
||||
for(var/datum/atom_hud/antag/H in GLOB.huds)
|
||||
H.remove_hud_from(src)
|
||||
|
||||
/mob/dead/observer/proc/set_radiation_view(enabled)
|
||||
if (enabled)
|
||||
seerads = TRUE
|
||||
|
||||
Reference in New Issue
Block a user