Makes health analyzer show an actual percentage of the analyzed mob's health. Also fixes the span in time of death.

This commit is contained in:
kingofkosmos
2016-02-03 20:55:24 +02:00
parent 213d324d5f
commit 92dfa8df98
+3 -3
View File
@@ -121,7 +121,7 @@ MASS SPECTROMETER
var/tox_loss = M.getToxLoss()
var/fire_loss = M.getFireLoss()
var/brute_loss = M.getBruteLoss()
var/mob_status = (M.stat > 1 ? "<span class='alert'><b>Deceased</b></span>" : "<b>[M.health] % healthy</b>")
var/mob_status = (M.stat > 1 ? "<span class='alert'><b>Deceased</b></span>" : "<b>[round(M.health/M.maxHealth,0.01)*100] % healthy</b>")
if(M.status_flags & FAKEDEATH)
mob_status = "<span class='alert'>Deceased</span>"
@@ -172,7 +172,7 @@ MASS SPECTROMETER
// Time of death
if(M.tod && (M.stat == DEAD || (M.status_flags & FAKEDEATH)))
user << "<span class='info'>Time of Death:</span> [M.tod]"
user << "<span class='info'>Time of Death: [M.tod]</span>"
for(var/datum/disease/D in M.viruses)
if(!(D.visibility_flags & HIDDEN_SCANNER))
@@ -409,7 +409,7 @@ MASS SPECTROMETER
else if (T.nutrition < T.get_hunger_nutrition())
user << "<span class='warning'>Warning: slime is hungry</span>"
user << "Electric change strength: [T.powerlevel]"
user << "Health: [T.health]"
user << "Health: [round(T.health/T.maxHealth,0.01)*100]"
if (T.slime_mutation[4] == T.colour)
user << "This slime does not evolve any further."
else