From 0febe20a080125e1f8b9ebc470972cf95544da06 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Sat, 2 Mar 2019 13:15:38 +0100 Subject: [PATCH] - fixed: Unmorphing a monster did not clear its UNMORPHED flag. --- src/p_mobj.cpp | 2 ++ wadsrc/static/zscript/actors/player/player_morph.zs | 1 + 2 files changed, 3 insertions(+) diff --git a/src/p_mobj.cpp b/src/p_mobj.cpp index 44e8a97e9..d2c00d2a5 100644 --- a/src/p_mobj.cpp +++ b/src/p_mobj.cpp @@ -7396,5 +7396,7 @@ void PrintMiscActorInfo(AActor *query) Printf("FriendlySeeBlocks: %d\n", query->friendlyseeblocks); Printf("Target: %s\n", query->target ? query->target->GetClass()->TypeName.GetChars() : "-"); Printf("Last enemy: %s\n", query->lastenemy ? query->lastenemy->GetClass()->TypeName.GetChars() : "-"); + auto sn = FState::StaticGetStateName(query->state); + Printf("State:%s, Tics: %d", sn.GetChars(), query->tics); } } diff --git a/wadsrc/static/zscript/actors/player/player_morph.zs b/wadsrc/static/zscript/actors/player/player_morph.zs index 7921d1dce..87ee90ac9 100644 --- a/wadsrc/static/zscript/actors/player/player_morph.zs +++ b/wadsrc/static/zscript/actors/player/player_morph.zs @@ -562,6 +562,7 @@ class MorphedMonster : Actor unmorphed.args[3] = args[3]; unmorphed.args[4] = args[4]; unmorphed.CopyFriendliness (self, true); + unmorphed.bUnmorphed = false; UnmorphedMe = NULL; Substitute(unmorphed); Destroy ();