1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-28 12:39:41 +00:00

Cancel stagger animation when an attack ends (bug #6869)

This commit is contained in:
Alexei Kotov 2022-07-28 18:21:33 +03:00
parent c54822acf9
commit a2c5161ac4
2 changed files with 6 additions and 0 deletions

View file

@ -132,6 +132,7 @@
Bug #6794: Light sources are attached to mesh bounds centers instead of mesh origins when AttachLight NiNode is missing
Bug #6799: Game crashes if an NPC has no Class attached
Bug #6849: ImageButton texture is not scaled properly
Bug #6869: Hits queue stagger during swing animation
Bug #6895: Removing a negative number of items from a script, makes the script terminate with an error
Bug #6898: Accessing the Quick Inventory menu does not work while in menu mode
Bug #6901: Morrowind.exe soul gem usage discrepancy

View file

@ -1661,6 +1661,11 @@ bool CharacterController::updateState(CharacterState idle)
if (ammunition && mWeaponType == ESM::Weapon::MarksmanCrossbow)
mAnimation->attachArrow();
// Cancel stagger animation at the end of an attack to avoid abrupt transitions
// in favor of a different abrupt transition, like Morrowind
if (mUpperBodyState != UpperCharState_EquipingWeap && isRecovery())
mAnimation->disable(mCurrentHit);
mUpperBodyState = UpperCharState_WeapEquiped;
}
else if(mUpperBodyState == UpperCharState_UnEquipingWeap)