Match LegoNavController::ProcessKeyboardInput (#1298)

This commit is contained in:
Christian Semmler
2024-12-28 10:30:07 -07:00
committed by GitHub
parent e4e8ad6da5
commit a97934e188

View File

@@ -582,29 +582,33 @@ MxResult LegoNavController::ProcessKeyboardInput()
m_unk0x6c = TRUE; m_unk0x6c = TRUE;
MxS32 hMax; MxS32 hMax;
if ((keyFlags & LegoInputManager::c_leftOrRight) == LegoInputManager::c_left) { switch (keyFlags & LegoInputManager::c_leftOrRight) {
case LegoInputManager::c_left:
hMax = 0; hMax = 0;
} break;
else if ((keyFlags & LegoInputManager::c_leftOrRight) == LegoInputManager::c_right) { case LegoInputManager::c_right:
hMax = m_hMax; hMax = m_hMax;
} break;
else { default:
m_targetRotationalVel = 0.0; m_targetRotationalVel = 0.0;
m_rotationalAccel = m_maxRotationalDeccel; m_rotationalAccel = m_maxRotationalDeccel;
bool1 = TRUE; bool1 = TRUE;
break;
} }
MxS32 vMax; MxS32 vMax;
if ((keyFlags & LegoInputManager::c_upOrDown) == LegoInputManager::c_up) { switch (keyFlags & LegoInputManager::c_upOrDown) {
case LegoInputManager::c_up:
vMax = 0; vMax = 0;
} break;
else if ((keyFlags & LegoInputManager::c_upOrDown) == LegoInputManager::c_down) { case LegoInputManager::c_down:
vMax = m_vMax; vMax = m_vMax;
} break;
else { default:
m_targetLinearVel = 0.0; m_targetLinearVel = 0.0;
m_linearAccel = m_maxLinearDeccel; m_linearAccel = m_maxLinearDeccel;
bool2 = TRUE; bool2 = TRUE;
break;
} }
MxFloat val = keyFlags & LegoInputManager::c_bit5 ? 1.0f : 4.0f; MxFloat val = keyFlags & LegoInputManager::c_bit5 ? 1.0f : 4.0f;