From faa489368ea977aedba599d1fc197db50308c325 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Thu, 15 Feb 2024 21:22:06 +0100 Subject: [PATCH] [MIRROR] Partial fix of heretic shapechanges (#26505) * Partial fix of heretic shapechanges (#81434) ## About The Pull Request Fixes #79713 and partially #80525 - heretics should no longer regain their spells improperly when coming back from a shapeshift. Note: heretics losing their living heart when shapeshifting is an unrelated issue that I wanted to solve in this same PR originally, but it has proven to be more complicated than anticipated. So only spell fix for now. ## Why It's Good For The Game I see bug I kill it. ## Changelog :cl: fix: heretics no longer lose their spells when returning from a shapeshift /:cl: * Partial fix of heretic shapechanges --------- Co-authored-by: ViktorKoL <44502667+ViktorKoL@users.noreply.github.com> --- code/modules/antagonists/heretic/heretic_knowledge.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/modules/antagonists/heretic/heretic_knowledge.dm b/code/modules/antagonists/heretic/heretic_knowledge.dm index cb9f3b75ccc..f2cf7b00047 100644 --- a/code/modules/antagonists/heretic/heretic_knowledge.dm +++ b/code/modules/antagonists/heretic/heretic_knowledge.dm @@ -211,7 +211,8 @@ /datum/heretic_knowledge/spell/on_lose(mob/user, datum/antagonist/heretic/our_heretic) var/datum/action/cooldown/spell/created_spell = created_spell_ref?.resolve() - created_spell?.Remove(user) + if(created_spell?.owner == user) + created_spell.Remove(user) /** * A knowledge subtype for knowledge that can only