Do not interrupt scripted animations by death animation (bug #4286)

0.6.3
Andrei Kortunov 7 years ago
parent d0619cfb35
commit a42c663fd7

@ -728,6 +728,14 @@ void CharacterController::playRandomDeath(float startpoint)
MWBase::Environment::get().getWorld()->useDeathCamera();
}
// Do not interrupt scripted animation by death
if (!mAnimQueue.empty())
{
AnimationQueueEntry& first = mAnimQueue.front();
if (first.mPersist && isAnimPlaying(first.mGroup))
return;
}
if(mHitState == CharState_SwimKnockDown && mAnimation->hasAnimation("swimdeathknockdown"))
{
mDeathState = CharState_SwimDeathKnockDown;

Loading…
Cancel
Save