Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIRROR] No longer stuck inside legion when you revive #1025

Merged
merged 1 commit into from
Dec 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions code/modules/mob/living/basic/lavaland/legion/legion.dm
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
. = ..()
if (gone != stored_mob)
return
UnregisterSignal(stored_mob, COMSIG_LIVING_REVIVE)
ai_controller.clear_blackboard_key(BB_LEGION_CORPSE)
stored_mob.remove_status_effect(/datum/status_effect/grouped/stasis, STASIS_LEGION_EATEN)
stored_mob.add_mood_event(MOOD_CATEGORY_LEGION_CORE, /datum/mood_event/healsbadman/long_term) // This will still probably mostly be gone before you are alive
Expand All @@ -72,6 +73,7 @@
consumed.extinguish_mob()
consumed.fully_heal(HEAL_DAMAGE)
consumed.apply_status_effect(/datum/status_effect/grouped/stasis, STASIS_LEGION_EATEN)
RegisterSignal(consumed, COMSIG_LIVING_REVIVE, PROC_REF(on_consumed_revive))
consumed.forceMove(src)
ai_controller?.set_blackboard_key(BB_LEGION_CORPSE, consumed)
ai_controller?.set_blackboard_key(BB_LEGION_RECENT_LINES, consumed.copy_recent_speech(line_chance = 80))
Expand All @@ -84,6 +86,11 @@
cancer.Insert(consumed, special = TRUE, drop_if_replaced = FALSE)

/// A Legion which only drops skeletons instead of corpses which might have fun loot, so it cannot be farmed

/mob/living/basic/mining/legion/proc/on_consumed_revive(full_heal_flags)
SIGNAL_HANDLER
gib()

/mob/living/basic/mining/legion/spawner_made
corpse_type = /obj/effect/mob_spawn/corpse/human/legioninfested/skeleton/charred

Expand Down
7 changes: 4 additions & 3 deletions code/modules/mob/living/death.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,20 @@
**/
/mob/living/proc/gib(drop_bitflags=NONE)
var/prev_lying = lying_angle
if(stat != DEAD)
death(TRUE)
spawn_gibs(drop_bitflags)

if(!prev_lying)
gib_animation()

if(stat != DEAD)
death(TRUE)

ghostize()
spill_organs(drop_bitflags)

if(drop_bitflags & DROP_BODYPARTS)
spread_bodyparts(drop_bitflags)

spawn_gibs(drop_bitflags)
SEND_SIGNAL(src, COMSIG_LIVING_GIBBED, drop_bitflags)
qdel(src)

Expand Down
Loading