Caterpillars and Nymphs that evolve no longer provide blood to vampires and cannot be culted (#26174)

* Makes nymphs and caterpillars immune to being culted after they evolve. Also makes them not give any usuable blood to vampires.

* Improves comments and changes the trait name.

* Update code/__HELPERS/trait_helpers.dm

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
Signed-off-by: Spaghetti-bit <yumyumkillkill@gmail.com>

---------

Signed-off-by: Spaghetti-bit <yumyumkillkill@gmail.com>
Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
Spaghetti-bit
2024-08-02 17:07:33 -07:00
committed by GitHub
parent 137689ff0e
commit 6837ea7333
6 changed files with 9 additions and 4 deletions
@@ -114,7 +114,7 @@ RESTRICT_TYPE(/datum/antagonist/vampire)
owner.current.set_nutrition(min(NUTRITION_LEVEL_WELL_FED, owner.current.nutrition + 5))
continue
if(H.stat != DEAD || H.has_status_effect(STATUS_EFFECT_RECENTLY_SUCCUMBED))
if((H.stat != DEAD || H.has_status_effect(STATUS_EFFECT_RECENTLY_SUCCUMBED)) && !HAS_MIND_TRAIT(H, TRAIT_XENOBIO_SPAWNED_HUMAN))
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)
@@ -130,7 +130,7 @@ RESTRICT_TYPE(/datum/antagonist/vampire)
else
to_chat(owner.current, "<span class='warning'>You have bled your victim dry!</span>")
break
if(!H.ckey && !H.player_ghosted)//Only runs if there is no ckey and the body has not being ghosted while alive
if((!H.ckey && !H.player_ghosted) || HAS_MIND_TRAIT(H, TRAIT_XENOBIO_SPAWNED_HUMAN)) //Only runs if there is no ckey and the body has not being ghosted while alive, also runs if the victim is an evolved caterpillar or diona nymph.
to_chat(owner.current, "<span class='notice'><b>Feeding on [H] reduces your thirst, but you get no usable blood from them.</b></span>")
owner.current.set_nutrition(min(NUTRITION_LEVEL_WELL_FED, owner.current.nutrition + 5))
else
@@ -205,6 +205,8 @@
adult.real_name = adult.name
adult.ckey = ckey
adult.real_name = adult.dna.species.get_random_name() //I hate this being here of all places but unfortunately dna is based on real_name!
// [Nymph -> Diona] is from xenobio (or botany) and does not give vampires usuble blood and cannot be converted by cult.
ADD_TRAIT(adult.mind, TRAIT_XENOBIO_SPAWNED_HUMAN, ROUNDSTART_TRAIT)
for(var/obj/item/W in contents)
unEquip(W)
@@ -83,6 +83,8 @@
// Mind transfer to new worme.
M.transfer_to(adult)
// [Caterpillar -> worme -> nian] is from xenobio (or cargo) and does not give vampires usuble blood and cannot be converted by cult.
ADD_TRAIT(adult.mind, TRAIT_XENOBIO_SPAWNED_HUMAN, ROUNDSTART_TRAIT)
// Worme is placed into cacoon.
adult.forceMove(C)