-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Raw Input Flickering Fix | Issue #177 #186
base: develop
Are you sure you want to change the base?
Conversation
… RawMouse resetting when mouse reaches edges of screen,
…ouse actually returns result of SetCursorPos which is BOOL.
auto recenterMouse = Game::CL_MouseEvent(curPos.x, curPos.y, dx, dy); | ||
|
||
ClipCursor(NULL); | ||
if (!Game::CL_MouseEvent(curPos.x, curPos.y, dx, dy)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why check CL_MouseEvent to disable clipping? ClipCursor(NULL) was originally used to prevent clipping in the menu. Does CL_MouseEvent return false in menus and true otherwise?
If so, we should add a comment to clarify. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It returns true when it wants mouse to be recentered.
I see no obvious issue with the code, the get<dvar_t*> thingies are a bit odd but I don't mind them. Confirm to me that everything is working as intended? |
Hello! Here are some issues I noticed during my test: The cursor takes too long to clip back when focus is lost and regained. This delay often cause the cursor to escape the window accidentally while aiming: Screencast.From.2025-01-07.15-05-45.mp4The cursor moves in the background, meaning its position is not fixed. It appears in different positions when switching back and forth between the menu and the game. Occasionally, the cursor position is recalculated, leading to erratic jumps within the menu (0:16s): Screencast.From.2025-01-07.15-09-29.mp4 |
reworked IN_RecenterMouse, Improved focus checks for Raw Input, fixed Raw Input bugs caused by mouse reaching edges of application window rect (#177), also removed useless WM_MOUSEFIRST window message callback.