Fix lower body blocking animation priority (bug #5656)

pull/3021/head
Alexei Dobrohotov 4 years ago
parent 7d16b6f26c
commit 7da8479d25

@ -58,6 +58,7 @@
Bug #5622: Can't properly interact with the console when in pause menu
Bug #5639: Tooltips cover Messageboxes
Bug #5644: Summon effects running on the player during game initialization cause crashes
Bug #5656: Sneaking characters block hits while standing
Feature #390: 3rd person look "over the shoulder"
Feature #2386: Distant Statics in the form of Object Paging
Feature #4894: Consider actors as obstacles for pathfinding

@ -270,6 +270,7 @@ void CharacterController::refreshHitRecoilAnims(CharacterState& idle)
mCurrentHit = "shield";
MWRender::Animation::AnimPriority priorityBlock (Priority_Hit);
priorityBlock[MWRender::Animation::BoneGroup_LeftArm] = Priority_Block;
priorityBlock[MWRender::Animation::BoneGroup_LowerBody] = Priority_WeaponLowerBody;
mAnimation->play(mCurrentHit, priorityBlock, MWRender::Animation::BlendMask_All, true, 1, "block start", "block stop", 0.0f, 0);
}
@ -289,6 +290,8 @@ void CharacterController::refreshHitRecoilAnims(CharacterState& idle)
mUpperBodyState = UpperCharState_Nothing;
}
}
if (mHitState != CharState_None)
idle = CharState_None;
}
else if(!mAnimation->isPlaying(mCurrentHit))
{
@ -308,8 +311,6 @@ void CharacterController::refreshHitRecoilAnims(CharacterState& idle)
mAnimation->disable(mCurrentHit);
mAnimation->play(mCurrentHit, Priority_Knockdown, MWRender::Animation::BlendMask_All, true, 1, "loop stop", "stop", 0.0f, 0);
}
if (mHitState != CharState_None)
idle = CharState_None;
}
void CharacterController::refreshJumpAnims(const std::string& weapShortGroup, JumpingState jump, CharacterState& idle, bool force)

Loading…
Cancel
Save