Mouse not being captured in full screen

Questions about Wine on Linux
Locked
hiigaran
Level 2
Level 2
Posts: 41
Joined: Fri Sep 22, 2017 12:41 am

Mouse not being captured in full screen

Post by hiigaran »

I'm attempting to run Fallout 4 on 4.17, and I've been having trouble getting the mouse to work. It appears as if the mouse is not being captured by the application, whether or not I have the option in winecfg enabled to automatically capture the mouse in full screen applications. I can move the mouse around on the menu, but I cannot click anything. If loading a saved game or starting a new one, moving the mouse will do nothing in-game, when it should be moving the view around.

This has been an issue for the last few versions, though I don't remember when it started. At this point, I'm not even sure if it is the version. In any case, it's a clean wine prefix, with only the prerequisites for the game installed. I've also tried emulating a virtual desktop, though this made no difference. DXVK is also installed, but I've attempted this without it as well, so it doesn't look like it's a contributing factor.

Suggestions?
User avatar
Bob Wya
Level 12
Level 12
Posts: 3068
Joined: Sat Oct 16, 2010 7:40 pm

Re: Mouse not being captured in full screen

Post by Bob Wya »

@hiigaran

Have you followed the recommendations for settings and overrides from:
WineHQ AppDB : Fallout 4 / Steam : WINEPREFIX Post-installation Setup Script (DLL Overrides & Settings) ?

Bob
hiigaran
Level 2
Level 2
Posts: 41
Joined: Fri Sep 22, 2017 12:41 am

Re: Mouse not being captured in full screen

Post by hiigaran »

It mentions something about a mousewarp override, which might be what I need. However, I'm not sure what to do with that. One guide's instructions were to make a .reg file with the following contents:

Code: Select all

REGEDIT4

[\HKEY_CURRENT_USER\Software\Wine\DirectInput]
"MouseWarpOverride"="force"
Then run the following command:

Code: Select all

wine regedit registryfile.reg
This however, gives me the error:

Code: Select all

regedit: Unable to open the registry key '\HKEY_CURRENT_USER\Software\Wine\DirectInput'.
Is there another way to do this?
User avatar
Bob Wya
Level 12
Level 12
Posts: 3068
Joined: Sat Oct 16, 2010 7:40 pm

Re: Mouse not being captured in full screen

Post by Bob Wya »

@ hiigaran

There shouldn't be a backslash before the hive name, in that registry file.

You can set this mouse option with a single Wine command anyway:

Code: Select all

wine reg.exe ADD "HKEY_CURRENT_USER\Software\Wine\DirectInput" "/v" "MouseWarpOverride" "/t" "REG_SZ" "/d" "force"
I presume you've set:

Code: Select all

bBackgroundMouse=1
in both ini files:

Code: Select all

"${WINEPREFIX}/drive_c/users/$USER/My Documents/My Games/Fallout4/Fallout4.ini"
"${GAMEDIR}/Fallout4_Default.ini"
You'd also want:

Code: Select all

winetricks grabfullscreen=y
Bob
Last edited by Bob Wya on Fri Oct 04, 2019 2:18 pm, edited 2 times in total.
hiigaran
Level 2
Level 2
Posts: 41
Joined: Fri Sep 22, 2017 12:41 am

Re: Mouse not being captured in full screen

Post by hiigaran »

Well, the command worked, but it didn't make a difference in-game. Still the same issues.
User avatar
Bob Wya
Level 12
Level 12
Posts: 3068
Joined: Sat Oct 16, 2010 7:40 pm

Re: Mouse not being captured in full screen

Post by Bob Wya »

hiigaran wrote: Fri Oct 04, 2019 1:54 pm Well, the command worked, but it didn't make a difference in-game. Still the same issues.
That registry setting (mouse warping) is generally only going fix the instance where your mouse escapes the main game window (e.g. in a dual monitor setup).
So I'm not surprised it doesn't fix your issue.

Like I said make sure you've correctly setup in the Fallout4 ini files.

You'll probably want to be using wine-staging 4.17 (if you have been tested with vanilla wine)...

Your issue may be related to what-ever Desktop Environment you are using.

Bob
hiigaran
Level 2
Level 2
Posts: 41
Joined: Fri Sep 22, 2017 12:41 am

Re: Mouse not being captured in full screen

Post by hiigaran »

I was meant to type 'commands'. Couldn't find the edit button for my post. The .ini files already had those lines set, as well. Either way, it didn't even stop the mouse from escaping the game window.

As for the package I should be using, can I confirm it's wine-staging, and not winehq-staging, as per the installation instructions here?

DE is GNOME. Fallout 4 used to work before, but perhaps as things updated, something broke?
hiigaran
Level 2
Level 2
Posts: 41
Joined: Fri Sep 22, 2017 12:41 am

Re: Mouse not being captured in full screen

Post by hiigaran »

Quick update on this: Running 4.11, and no issues. Apparently others have been saying there has been an issue with raw mouse inputs or something. No idea what it means, but there's clearly some sort of regression here.
Locked