Skip to content

Commit

Permalink
Fix mouse movement on 3D
Browse files Browse the repository at this point in the history
  • Loading branch information
ubkp committed Oct 16, 2023
1 parent b227db1 commit 6f3afc1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/rcore_desktop_sdl.c
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,9 @@ void PollInputEvents(void)
CORE.Input.Mouse.currentWheelMove.x = 0;
CORE.Input.Mouse.currentWheelMove.y = 0;

// Register previous mouse position
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;

// Reset last gamepad button/axis registered state
CORE.Input.Gamepad.lastButtonPressed = GAMEPAD_BUTTON_UNKNOWN;
for (int i = 0; i < MAX_GAMEPADS; i++) CORE.Input.Gamepad.axisCount[i] = 0;
Expand Down

0 comments on commit 6f3afc1

Please sign in to comment.