CMetaree: Set locomotion type to crouched if deactivated in InActive()

v0-00 sets this locomotion type when the deactivation flag is set.
This commit is contained in:
Lioncash 2020-02-07 19:27:23 -05:00
parent 61f9adfa70
commit 1edcbf7ec6
1 changed files with 3 additions and 2 deletions

View File

@ -153,8 +153,9 @@ void CMetaree::Active(CStateManager& mgr, EStateMsg msg, float) {
void CMetaree::InActive(CStateManager&, EStateMsg msg, float) { void CMetaree::InActive(CStateManager&, EStateMsg msg, float) {
if (msg == EStateMsg::Activate) { if (msg == EStateMsg::Activate) {
if (!x5ca_26_deactivated) const auto locomotionType = x5ca_26_deactivated ? pas::ELocomotionType::Crouch
x450_bodyController->SetLocomotionType(pas::ELocomotionType::Relaxed); : pas::ELocomotionType::Relaxed;
x450_bodyController->SetLocomotionType(locomotionType);
} else if (msg == EStateMsg::Deactivate) { } else if (msg == EStateMsg::Deactivate) {
x5ca_26_deactivated = true; x5ca_26_deactivated = true;
} }