Open Korb opened 1 month ago
Implemented in e551dfce4d0105c35cbe7ebcd74061ae4fda335b. Thanks
When I connected a working Xbox Wireless Controller, the web app settings showed non-clickable text "Gamepads", "Device" and "Map", and nothing more:
For example, the game's main menu offers:
- Kempston
- Sinclair
- Protek
- A.G.F.
- Fuller
- Keyboard
Up — E, O, 7 Down — F, K, 6 Left — M, X, 5 Right — Symbol, Shift, C, 8 Fire — N, V, B, O (0?)
What actions should the player take in order to use the controller in the game in this case?
Mozilla Firefox 132.0b8 (64-bit) Microsoft Windows 10.0.19045.5011 Xbox driver 10.0.19041.3636 (2023-10-19)
Did you press any buttons on the controller while the focus was on the browser window?
Should be something like that:
Did you press any buttons on the controller while the focus was on the browser window?
Sure. I tried the key mapping mode in Renegade, but the app only accepts keyboard key presses, not controller buttons or stick movements. The controller works fine on Steam-games.
Have a look, maybe the Using the Gamepad API article on MDN is useful?
Thanks. Yes, I've read this article.
Just tried it in Firefox 131.0.3 under Windows 11. It works.
I have Xbox Wireless Controller either. I do not have any dedicated driver installed for it though. It's just a generic driver. Probably, I'll have a chance to test it with other configurations later.
Chrome 129.0.6668.59 (Official Build) (64-bit):
Available matching options:
A = 0 (zero) B = N/A X = N/A Y = N/A LB = 5 (five) LSB = N/A LS◀ = 5 (five) LS🔼 = 7 (seven) LS▶ = 8 (eight) LS🔽 = 6 (six) LT = N/A RB = 8 (eight) RSB = N/A RS◀ = N/A RS🔼 = N/A RS▶ = N/A RS🔽 = N/A RT = N/A D-pad◀ = 5 (five) D-pad🔼 = 7 (seven) D-pad▶ = 8 (eight) D-pad🔽 = 6 (six)
A = M B = N/A X = N/A Y = N/A LB = O (letter) LSB = N/A LS◀ = O (letter) LS🔼 = Q LS▶ = O (letter) LS🔽 = A LT = N/A RB = P RSB = N/A RS◀ = N/A RS🔼 = N/A RS▶ = N/A RS🔽 = N/A RT = N/A D-pad◀ = O (letter) D-pad🔼 = Q D-pad▶ = P D-pad🔽 = A
A = BR / Space B = N/A X = N/A Y = N/A LB = O (letter) LSB = N/A LS◀ = O (letter) LS🔼 = Q LS▶ = O (letter) LS🔽 = A LT = N/A RB = P RSB = N/A RS◀ = N/A RS🔼 = N/A RS▶ = N/A RS🔽 = N/A RT = N/A D-pad◀ = O (letter) D-pad🔼 = Q D-pad▶ = P D-pad🔽 = A
If we fix the Mozilla Firefox incompatibility and QAOPM/QAOPSpace bugs, could we create a separate issue for custom controller remapping (rather than the fixed one as it is now)? The possibility of playing Elite with a controller was recently mentioned here, and the idea seems viable. Of course, with the ability to export and import mapping profiles.
I have fixed QAOPM/QAOPSpace layouts. Thanks you.
Speaking of Mozilla Firefox, I didn't figure out why it might not work. I checked a few configurations and browsers behaved strange sometimes. For example, I created a page with minimal code for checking connected gamepads. It detects my gamepad only every other time I refresh the page in Firefox/Win11. This behavior changes if I, for instance, open developer tools or just a new tab in the browser. However, the same page works stably in Firefox/Win10. Futhermore, the emulator itself, which contains similar code, works well in both these configurations for me. I'll continue to test different environments. If I find the root of the problem and it can be solved with client code, I'll do it.
As for custom remapping, I was going to implement it. However, at the moment, I just don't have much time for development. When it becomes easier, I'll get to it.
Currently, the web app's Settings tab contains only the following settings:
Please add the ability to use the hardware game controllers present in the system (Xbox Controller, PlayStation Controller, Nintendo Switch, Generic Controller, and Steam Controller).