Improves strange reagent feedback/desc, fixes missing delay/ghost notification (#42086)

* Improves strange reagent feedback/desc

* fixes ghost notify and intended delay

* removes !M
This commit is contained in:
81Denton
2018-12-28 11:11:27 +01:00
committed by Jordie
parent 7d09136d79
commit a91b4e6dbd
@@ -782,7 +782,7 @@
/datum/reagent/medicine/strange_reagent
name = "Strange Reagent"
id = "strange_reagent"
description = "A miracle drug capable of bringing the dead back to life. Only functions if the target has less than 100 brute and burn damage (independent of one another), and causes slight damage to the living."
description = "A miracle drug capable of bringing the dead back to life. Only functions when applied by patch or spray, if the target has less than 100 brute and burn damage (independent of one another) and hasn't been husked. Causes slight damage to the living."
reagent_state = LIQUID
color = "#A0E85E"
metabolization_rate = 0.5 * REAGENTS_METABOLISM
@@ -790,23 +790,22 @@
/datum/reagent/medicine/strange_reagent/reaction_mob(mob/living/carbon/human/M, method=TOUCH, reac_volume)
if(M.stat == DEAD)
if(M.getBruteLoss() >= 100 || M.getFireLoss() >= 100 || M.has_trait(TRAIT_HUSK))
if(M.suiciding || M.hellbound) //they are never coming back
M.visible_message("<span class='warning'>[M]'s body does not react...</span>")
return
if(M.getBruteLoss() >= 100 || M.getFireLoss() >= 100 || M.has_trait(TRAIT_HUSK)) //body is too damaged to be revived
M.visible_message("<span class='warning'>[M]'s body convulses a bit, and then falls still once more.</span>")
return
M.visible_message("<span class='warning'>[M]'s body convulses a bit.</span>")
if(!M.suiciding && !M.hellbound)
if(!M)
return
if(M.notify_ghost_cloning(source = M))
spawn (100) //so the ghost has time to re-enter
return
else
M.adjustOxyLoss(-20, 0)
M.adjustToxLoss(-20, 0)
M.updatehealth()
if(M.revive())
M.emote("gasp")
log_combat(M, M, "revived", src)
else
M.visible_message("<span class='warning'>[M]'s body starts convulsing!</span>")
M.notify_ghost_cloning(source = M)
sleep(100) //so the ghost has time to re-enter
M.adjustOxyLoss(-20, 0)
M.adjustToxLoss(-20, 0)
M.updatehealth()
if(M.revive())
M.emote("gasp")
log_combat(M, M, "revived", src)
..()
/datum/reagent/medicine/strange_reagent/on_mob_life(mob/living/carbon/M)