WARNING: Not updating mouse.previousPosition when SeMousePosition() #5962
This could be a sensible change, not sure if it can break anything...
This commit is contained in:
parent
af98e3126e
commit
4640c84920
9 changed files with 2 additions and 10 deletions
|
|
@ -726,7 +726,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -1237,7 +1237,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
|
||||
// NOTE: emscripten not implemented
|
||||
glfwSetCursorPos(platform.handle, CORE.Input.Mouse.currentPosition.x, CORE.Input.Mouse.currentPosition.y);
|
||||
|
|
|
|||
|
|
@ -1526,7 +1526,6 @@ void SetMousePosition(int x, int y)
|
|||
{
|
||||
RGFW_window_moveMouse(platform.window, x, y);
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -1411,7 +1411,6 @@ void SetMousePosition(int x, int y)
|
|||
SDL_WarpMouseInWindow(platform.window, x, y);
|
||||
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -1299,8 +1299,8 @@ void SetMousePosition(int x, int y)
|
|||
if (!CORE.Input.Mouse.cursorLocked)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
TRACELOG(LOG_WARNING, "SetMousePosition not implemented");
|
||||
|
||||
TRACELOG(LOG_WARNING, "SetMousePosition not implemented at platform level");
|
||||
}
|
||||
else TRACELOG(LOG_WARNING, "INPUT: MOUSE: Cursor not enabled");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1042,7 +1042,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -420,7 +420,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -395,7 +395,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
}
|
||||
|
||||
// Set mouse cursor
|
||||
|
|
|
|||
|
|
@ -1047,7 +1047,6 @@ void SetGamepadVibration(int gamepad, float leftMotor, float rightMotor, float d
|
|||
void SetMousePosition(int x, int y)
|
||||
{
|
||||
CORE.Input.Mouse.currentPosition = (Vector2){ (float)x, (float)y };
|
||||
CORE.Input.Mouse.previousPosition = CORE.Input.Mouse.currentPosition;
|
||||
|
||||
if (CORE.Input.Mouse.cursorLocked) CORE.Input.Mouse.lockedPosition = CORE.Input.Mouse.currentPosition;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue