Fixed crashes with the A_CrispyPlayer and A_HandLower action functions

Simply using FindPSprite in those functions wouldn't be enough because if a mod is using the firehands layer when they are called this would go very wrong
This commit is contained in:
Leonard2 2016-06-18 10:48:13 +02:00
commit 05d1df3571
2 changed files with 23 additions and 5 deletions

View file

@ -231,6 +231,9 @@ DPSprite *player_t::GetPSprite(PSPLayers layer)
}
if (layer == PSP_STRIFEHANDS)
{
// Some of the old hacks rely on this layer coming from the FireHands state.
// This is the ONLY time a psprite's state is actually null.
pspr->State = nullptr;
pspr->y = WEAPONTOP;
}