0
\$\begingroup\$

Update: I originally thought that it was more or less random whether the controller input works or not. I have now found out that it stops working once the game has been started for the first time. Also, the problem is not specific to the Switch Pro Controller.

I can sometimes receive input from my Nintendo Switch Pro Controller after starting unity, but it stops working quickly and most of the time it won't even work at all the moment I start my game for the first time. I use Unity 2021.2 on a Windows 11 machine (but I had the same issue before updating from Windows 10 to 11). I use the new input system in my project, but then I tried with another project based on the same Unity version that does not use the new input system and the exact same issue occured. I tried a SNES style USB gamepad and I get the same results as with the Pro Controller.

What I mean be "receive input" is that I can go to the Input debugger window and see events from the controller. In addition to that, I am able to assign a button to an action in an Input Action Asset using the "Listen" functionality before the game is started.

Outside of Unity the controller works perfectly (e.g. in the Windows menu). I have reinstalled my bluetooth drivers today, which did solve connectivity problems that I was having, too, but the problem described here remained.

Here are screenshots of the windows where I would expect to see my inputs: Input debugger

When I click on "Record Frames" I start seeing events in the bottom pane, but they appear to be from a different device (Device ID is 0, not 4).

And this is the "Listen" button I was talking about: enter image description here

I scratched out the keyboard keys, because those were triggered by me making a screenshot. When pressing a button on the gamepad nothing shows up.

I haven't used the new input system before, neither have I ever successfully used a controller with Unity - so, don't assume I have tried the "obvious", since it might not be obvious to me :-) Thanks for taking the time to read!

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

This is a common issue with the new Input System. Several users have already reported this problem, which apparently has not been resolved. Although reading the documentation, it seems that many of these problems have more to do with the drivers themselves rather than the Input System.

Note that the documentation about Switch controller states the following:

This support does not currently work for Switch Pro controllers connected via wired USB. Instead, the Switch Pro controller must be connected via Bluetooth. This is due to the controller using a proprietary communication protocol on top of HID which does not allow treating the controller like any other HID.

New Input System Gamepad Documentation

Some users say that the problem can be fixed by restarting the computer, but this is not certain. It may or may not work for you, I guess it's worth a try.

Since you mentioned that your Bluetooth driver is buggy, we can't rule out that this could also be the problem, but that would already be out of the question...kind of.

\$\endgroup\$
4
  • \$\begingroup\$ Thank you for bringing these sad, but helpful news! I suppose I'll try the old input manager then. \$\endgroup\$
    – the_clau
    Apr 7, 2022 at 6:26
  • \$\begingroup\$ @the_clau If it's in your budget, you can try ReWired (quite an expensive asset honestly, but definitely worth it) or InControl (less expensive, and will go into 80% off in a few days by the way!). \$\endgroup\$
    – YoshGJ
    Apr 7, 2022 at 7:22
  • \$\begingroup\$ Thanks again! I am definitely willing to pay money for an Asset that makes my life easier, but I at least want to know how to make it work before relying on 3rd party packages. Also, I found out more about my problem (see the updated question). Interestingly, the new input system doesn't seem to be the issue. \$\endgroup\$
    – the_clau
    Apr 8, 2022 at 21:14
  • \$\begingroup\$ Ohh I see. Hmmm, that's odd (well not that much). Still, Unity seems to be the problem. Have you posted on the forum? They're very supportive there, just ask on the Input System subforum, they'll tell you if that's expected behavior or not. \$\endgroup\$
    – YoshGJ
    Apr 8, 2022 at 22:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .