From 416d549568789db9eef0ff11278f6052b2530794 Mon Sep 17 00:00:00 2001 From: scrawl Date: Fri, 5 Dec 2014 22:02:18 +0100 Subject: [PATCH] Fix animation glitch caused by knockdown If the player was knocked down while having no weapon, spell nor fists ready, the animation state would incorrectly shift to "weapon equipped" even though no weapon is equipped. --- apps/openmw/mwmechanics/character.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/openmw/mwmechanics/character.cpp b/apps/openmw/mwmechanics/character.cpp index 2e4f76c1a..46e06f460 100644 --- a/apps/openmw/mwmechanics/character.cpp +++ b/apps/openmw/mwmechanics/character.cpp @@ -1072,7 +1072,8 @@ bool CharacterController::updateWeaponState() } else if (mHitState == CharState_KnockDown) { - mUpperBodyState = UpperCharState_WeapEquiped; + if (mUpperBodyState > UpperCharState_WeapEquiped) + mUpperBodyState = UpperCharState_WeapEquiped; mAnimation->disable(mCurrentWeapon); } }