Gamepad not detected in Electron launcher on Steam Deck
Proton version: Experimental (but also 9.0-3 and 8.0-5) Device: Steam Deck (LCD) Steam OS version: 3.5.19 (also 3.4.10)
Hi. We have a launcher written in Electron. After upgrading Electron to a newer version, launcher doesn't detect gamepads (including the Steam Deck built-in buttons/joysticks/etc) when running on Steam Deck while using Proton. The last version of Electron where it works is 26.6.10. While the issue is related to Electron, I don't think it can be blamed as it works fine without Proton.
It works fine in the following scenarios:
- Running native Linux version on Steam Deck (without Proton)
- Running with Proton on Linux computer with Ubuntu 22.04.5
- Running without Proton on Windows computer
For handling gamepads we use https://developer.mozilla.org/en-US/docs/Web/API/Gamepad_API
For now we are holding off the update but eventually, we want to start using the new Electron and we might loose the Steam Deck Compatibility badge for one of our games.
Hi. I have same issue. I'm using Electron 26.2.1.0 as any above 26 doesn't work. It's not only Steam Deck but also Windows and Steam. No direct input is recognised no Xbox Pad/Dualsense/any pad and Steam Deck controllers. I'm using Phaser 2 default input + Electron. I'm forced to stick with build 26 to make it works. Any new posts on Electron github are straight removed with explanation: "The Electron team is small and generally doesn't have enough bandwidth to triage third-party code. Please file an issue with the specific program using Electron Because we treat our issues list as the team's backlog, we close issues that are questions since they don't represent a task needing to be completed. For most questions about Electron there are a lot of options."
I've been trying to figure this one out all day. It seems like the gamepad api works only very occasionally. It happened to work for me the first time I tried it, so naturally this left me scratching my head about what I did that caused it to break. In the end it suddenly started working again and right after a I restarted the app it broke again.
Not sure what this means but hopefully the fact that it works occasionally could be of help.
For me never works above Electeon v 26. The solution is to disable steam input then it works fine. Did U try it?
I tried about everything haha. If you're talking about windows, I managed to get my DS2 to work once I got the steam overlay working. These two flags caused the overlay to start working for me.
app.commandLine.appendSwitch("in-process-gpu");
app.commandLine.appendSwitch("disable-direct-composition");
How these to switches are related to steam input... I don't know. But it seems like even mouse input (through the DS2 touchpad) is broken without this. So my guess is that the steam overlay is somehow required for steam input to work.
As for the steam deck, disabling steam input there doesn't work. I don't think you can even disable steam input since the UI seems to indicate that steam input is required for both the steam controller and remote play.
I have those lines
app.commandLine.appendSwitch("in-process-gpu"); app.commandLine.appendSwitch("disable-direct-composition"); but controller still doesn't work once Steam Input is enabled.
On Steam Deck there's no issue with electron if work's without Proton nativeley.
I had this exact same problem. I sent in a Steam ticket about this, along with other minor issues I was having.
The response I got back was essentially that it's "an issue with Electron due to older versions working." They did say that it's possible that they could update Proton to improve compatibility, but since Electron is such a minor use-case runtime builder, it's not a high enough priority to allocate resources towards it.
I had to capitulate and just use the WSL (Windows Subsystem for Linux) to build Linux / Steam Deck builds. Then just add the --no-sandbox executable parameter to avoid the "Sandbox Wars" between Electron and the Steam Runtime environments causing major launch issues.