ValveSoftware / csgo-osx-linux

Counter-Strike: Global Offensive
http://counter-strike.net
787 stars 69 forks source link

Buy menu focustrap / buy menu performance. #3835

Open justpie opened 2 months ago

justpie commented 2 months ago

Your system information

if on Linux, please include Steam -> Help -> Steam Runtime Diagnostics in the gist. gist

Please describe your issue in as much detail as possible:

When opening the buy menu the game loses the mouse focustrap. During the start of a round if I press my buy key, the menu opens and shows my mouse. This will allow me to move my mouse outside my game window and navigate to my secondary monitor. If I click anywhere outside the game menu, it minimizes the game to my desktop.

Edit:: This appears to happen anytime my mouse is visible in the game. Launch screen, Buy Menu, Right clicking on the in game scoreboard.

I also noticed that there is a significant drop in performance when my buy menu is open. Perhaps it may be related to the VLK issue in #3803?

bauernjunges commented 2 months ago

Using launch options SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS=0 %command% will prevent the game from minimizing. The only solution for mouse grab known to me is using gamescope, which adds more latency sadly.

justpie commented 2 months ago

I tried adding "SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS", while the game doesn't minimize, it causes me to lose sound randomly. I'm thinking when I lose sound, my system somehow thinks that my game is minimized due to the command above.

bauernjunges commented 2 months ago

I'm using steam flatpak on KDE with wayland and pipewire and i never experienced that kind of phenomena.

This game mutes on focus loss ofc. As for why you lose focus, only you can tell us.

justpie commented 1 month ago

Adding the following as a launch command has helped menu performance. However, it still seems studder occasionally when hovering over different buy options.

-novid -high -nojoy +fps_max 0 +cl_cmdrate 128 +cl_forcepreload 1