1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-31 06:15:44 +00:00

Fall back to regular death animation if deathknockdown/deathknockout don't exist (Fixes #1870)

This commit is contained in:
scrawl 2014-09-02 15:14:23 +02:00
parent 819234cdfe
commit 84a0d064cd

View file

@ -557,11 +557,11 @@ void CharacterController::playRandomDeath(float startpoint)
{
mDeathState = CharState_SwimDeath;
}
else if (mHitState == CharState_KnockDown)
else if (mHitState == CharState_KnockDown && mAnimation->hasAnimation("deathknockdown"))
{
mDeathState = CharState_DeathKnockDown;
}
else if (mHitState == CharState_KnockOut)
else if (mHitState == CharState_KnockOut && mAnimation->hasAnimation("deathknockout"))
{
mDeathState = CharState_DeathKnockOut;
}