Locked Mouse Solution

More
2 years 3 months ago #1 by jazz
Locked Mouse Solution was created by jazz
I was wondering, technically, how does Reshade detect and handle FPS games that lock the mouse, for example Skyrim? I've looked at the source, still unsure of the solution.

Thanks.

Please Log in or Create an account to join the conversation.

More
2 years 3 months ago #2 by crosire
Replied by crosire on topic Locked Mouse Solution
input.cpp => HookSetCursorPosition. As long as input blocking is enabled, this intercepts any attempts of the game to reset the mouse cursor to the center of the screen and ignores them.

Please Log in or Create an account to join the conversation.

More
2 years 2 months ago #3 by Ruuttu
Replied by Ruuttu on topic Locked Mouse Solution
While we're on the subject, this doesn't work for me in Fallout 4.
When in-game (not in some kind of menu) and the overlay is visible, the game still prevents the mouse from exiting a 50% wide and tall region in the center of the screen.

Thus it is currently quite cumbersome to iterate on shader code, as I have to
- (Task switch to game obviously)
- Press ESC to leave gameplay (so that the overlay will work)
- Open overlay
- Click reload
- Close overlay
- Press ESC again to return to gameplay

Irregardless of this issue, I would like to have a hotkey for reloading the shaders :)

Please Log in or Create an account to join the conversation.

More
2 years 2 months ago #4 by crosire
The following user(s) said Thank You: Ruuttu

Please Log in or Create an account to join the conversation.

More
2 years 2 months ago #5 by AssassinsDecree
Replied by AssassinsDecree on topic Locked Mouse Solution
Have this same problem with No Man's Sky Next. Again, what do I do with the code at the link you provided? Sorry I'm clueless.

Please Log in or Create an account to join the conversation.