https://bugs.winehq.org/show_bug.cgi?id=52408
Bug ID: 52408 Summary: Number of gamepads limited and multiple gamepads broken Product: Wine Version: 7.0-rc6 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: xinput Assignee: wine-bugs@winehq.org Reporter: tomashnyk@gmail.com Distribution: ---
I first discussed this here: https://forum.winehq.org/viewtopic.php?f=8&t=36088 but eventually came to a conclusion this is a bug. It has two sides:
1) Wine will only register 4 gamepads even if more are connected.
2) When multiple gamepads are connected, Wine loses atleast some of their input.
Ad 1). I used Gamepad Tool from https://generalarcade.com/gamepadtool/ to check how many gamepads are connected. I used (unknowingly) kbct: https://github.com/samvel1024/kbct to create 4 virtual gamepads in addition to my real one. I am sure there are other ways to add more gamepads, either just connecting them physically or somehow fakeing them. With KBCT, one just needs to add an appropriate number of devices to grab. Kbct will produce a fake gamepad for each grabbed device, as it will list each device as being able to emit basically all keys linux knows, including gamepad keys. So a minimal config.yaml would be on my system like this:
- keyboards: ["Logitech K800", "AT Translated Set 2 keyboard", "Logitech MX Vertical", "ThinkPad Extra Buttons"]
- one just needs to list some devices available when running evtest.
This bug is not about kbct - that is just a way to trigger this bug, which I believe is presetn in Wine. Linux otherwise does not have any problem detecting moredevices.
2) When I reduced the number of faked devices to two (and one real one), my game (Worms WMD) would register just the left axis of the gamepad and not other controls. Curiously, when I tried GamePad tool, it would register the presses. No idea how Windows would behave, but I do not see a reason why the game would not be able to use multiple gamepads.