Cursor not locking with --force-grab-cursor in cs2

Hi. I have an issue with counter strike 2 when using gamescope. The mouse will not lock properly, and will move over to my other screen while i am in the game. I am using these launch parameters gamescope -w 1080 -h 1080 --force-grab-cursor --fullscreen -S stretch -- %command%
I am using the newest version of gnome with wayland.

Welcome to the community! :vulcan_salute: :enos_flag:

Two questions:

  1. What happens if you remove --fullscreen and/or -S stretch?
  2. What happens if you don’t use gamescope at all?

I discovered recently that games have in the last few months started to work better with Wayland, even without gamescope, so you may not actually need it.

Hi. Without --fullscreen i got a streched non fullscreen window, and i could not fullscreen it within the game. Without -S stretch i got a fullscreened window with black bars, and mouse was offset by the length of the black bars. I kinda need gamescope to stretch my window from a 1080x1080 to a 1920x1080 resolution, its just personal preference.

That’s not even considered a preference, really. Just an expectation and default.

The idea I was trying to mention is removing gamescope from the launch options may fix the issue, as it does with Cyberpunk 2077. Different game, but similar mechanics.

Based on your initial post, it sounds like a multi-monitor setup, so I’m guessing this wouldn’t be an issue if it were one monitor. Of course, you may need more than one monitor, but removing one while gaming should be an option I imagine.

This may sound stupid, but try using capital W and capital H as oppose to lowercase.

And also if you wanna clean the launch options, use -f instead of --fullscreen.

Currently I do not have any issues with the command, but I also use it at the end of my launch options as such:

gamemoderun gamemode -W 2301 -H 1440 -S stretch -f --force-grab-cursor -- %command%

For your sake you’ll just replace the W and H with 1080 1080.

1 Like

That didnt work

What version are you running on gamescope?

gamescope -version