Vampires can gain blood for a minute from people who succumb

This commit is contained in:
Qwertytoforty
2024-02-19 11:34:41 -05:00
parent 07acb62e5a
commit 50a3cf87fe
4 changed files with 8 additions and 2 deletions
+1
View File
@@ -223,6 +223,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_CAN_VIEW_HEALTH "can_view_health" // Also used for /Stat
#define TRAIT_MAGPULSE "magnetificent" // Used for anything that is magboot related
#define TRAIT_NOSLIP "noslip"
#define TRAIT_RECENTLY_SUCCUMBED "recently_succumbed"
//***** MIND TRAITS *****/
#define TRAIT_HOLY "is_holy" // The mob is holy in regards to religion
+2 -1
View File
@@ -87,7 +87,8 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_BADASS" = TRAIT_BADASS,
"TRAIT_FORCED_STANDING" = TRAIT_FORCED_STANDING,
"TRAIT_NOSLIP" = TRAIT_NOSLIP,
"TRAIT_MAGPULSE" = TRAIT_MAGPULSE
"TRAIT_MAGPULSE" = TRAIT_MAGPULSE,
"TRAIT_RECENTLY_SUCCUMBED " = TRAIT_RECENTLY_SUCCUMBED
),
/datum/mind = list(
@@ -135,7 +135,7 @@
continue
if(H.stat < DEAD)
if(H.stat < DEAD || HAS_TRAIT(H, TRAIT_RECENTLY_SUCCUMBED))
if(H.ckey || H.player_ghosted) //Requires ckey regardless if monkey or humanoid, or the body has been ghosted before it died
blood = min(20, H.blood_volume)
adjust_blood(H, blood * BLOOD_GAINED_MODIFIER)
+4
View File
@@ -320,7 +320,11 @@
else
death()
to_chat(src, "<span class='notice'>You have given up life and succumbed to death.</span>")
ADD_TRAIT(src, TRAIT_RECENTLY_SUCCUMBED, "succumb")
addtimer(CALLBACK(src, PROC_REF(remove_succumbed)), 1 MINUTES)
/mob/living/proc/remove_succumbed()
REMOVE_TRAIT(src, TRAIT_RECENTLY_SUCCUMBED, "succumb")
/mob/living/proc/InCritical()
return (health < HEALTH_THRESHOLD_CRIT && health > HEALTH_THRESHOLD_DEAD && stat == UNCONSCIOUS)