Calls the final HUD update later (higher, in mob/death) since stat was not yet DEAD (2) when it was called before.

Also makes all mobs update the HUDs all life() ticks, so people who have ghosted and left a body have correct HUD readings. If this affects performance, sorry? ... It really shouldn't. Only carbons should have real HUDs to update. The rest are tiny little procs.
This commit is contained in:
Arokha Sieyes
2016-05-19 13:30:12 -04:00
parent 7f53a7cf85
commit a50286e5e8
4 changed files with 4 additions and 6 deletions

View File

@@ -85,6 +85,7 @@
dead_mob_list |= src
updateicon()
handle_regular_hud_updates()
if(ticker && ticker.mode)
ticker.mode.check_win()

View File

@@ -31,8 +31,6 @@
BITSET(hud_updateflag, STATUS_HUD)
BITSET(hud_updateflag, LIFE_HUD)
handle_hud_list()
//Handle species-specific deaths.
species.handle_death(src)
animate_tail_stop()

View File

@@ -1555,7 +1555,7 @@
/mob/living/carbon/human/proc/handle_hud_list()
if (BITTEST(hud_updateflag, HEALTH_HUD))
var/image/holder = hud_list[HEALTH_HUD]
if(stat == 2)
if(stat == DEAD)
holder.icon_state = "hudhealth-100" // X_X
else
var/percentage_health = RoundHealth((health-config.health_threshold_crit)/(maxHealth-config.health_threshold_crit)*100)
@@ -1579,7 +1579,7 @@
var/image/holder = hud_list[STATUS_HUD]
var/image/holder2 = hud_list[STATUS_HUD_OOC]
if(stat == 2)
if(stat == DEAD)
holder.icon_state = "huddead"
holder2.icon_state = "huddead"
else if(status_flags & XENO_HOST)

View File

@@ -53,8 +53,7 @@
update_canmove()
if(client)
handle_regular_hud_updates()
handle_regular_hud_updates()
/mob/living/proc/handle_breathing()
return