mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-23 15:50:20 +00:00
Fix reversed strafe directions while swimming
Water strafe used opposite sign convention from land movement. Land: strafeLeft += right, strafeRight -= right. Water was: strafeLeft -= right, strafeRight += right. Now matches land.
This commit is contained in:
parent
3d6e3993d2
commit
923260c90c
1 changed files with 2 additions and 2 deletions
|
|
@ -519,8 +519,8 @@ void CameraController::update(float deltaTime) {
|
|||
glm::vec3 swimMove(0.0f);
|
||||
if (nowForward) swimMove += swimForward;
|
||||
if (nowBackward) swimMove -= swimForward;
|
||||
if (nowStrafeLeft) swimMove -= swimRight;
|
||||
if (nowStrafeRight) swimMove += swimRight;
|
||||
if (nowStrafeLeft) swimMove += swimRight;
|
||||
if (nowStrafeRight) swimMove -= swimRight;
|
||||
|
||||
if (glm::length(swimMove) > 0.001f) {
|
||||
swimMove = glm::normalize(swimMove);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue