Reduces Defib Safe Time: Adds Health HUD Defib Indicator

This commit is contained in:
Fox McCloud
2019-02-07 00:49:24 -05:00
parent 316b52b15b
commit dc09d07d86
6 changed files with 19 additions and 2 deletions
+4 -2
View File
@@ -357,8 +357,8 @@
QDEL_NULL(ghost)
var/tplus = world.time - H.timeofdeath
var/tlimit = 3000 //past this much time the patient is unrecoverable (in deciseconds)
var/tloss = 600 //brain damage starts setting in on the patient after some time left rotting
var/tlimit = DEFIB_TIME_LIMIT * 10 //past this much time the patient is unrecoverable (in deciseconds)
var/tloss = DEFIB_TIME_LOSS * 10 //brain damage starts setting in on the patient after some time left rotting
var/total_burn = 0
var/total_brute = 0
if(do_after(user, 20 * toolspeed, target = M)) //placed on chest and short delay to shock for dramatic effect, revive time is 5sec total
@@ -420,6 +420,8 @@
H.emote("gasp")
if(tplus > tloss)
H.setBrainLoss( max(0, min(99, ((tlimit - tplus) / tlimit * 100))))
H.med_hud_set_health()
H.med_hud_set_status()
defib.deductcharge(revivecost)
add_attack_logs(user, M, "Revived with [src]")
else