Why are my controller inputs ignored?

Godot Version

Godot Stable 4.3

Question

So in my Godot project I’ve set up a bunch of InputMaps and assigned keyboard and joypad events to each of them.
Now the keyboard inputs work just fine but the joypads input that are in the same InputMaps don’t even though the controller connects correctly. Why?

I am using a wired Switch Pro Controller and I tried both the portable and steam version of godot but no luck.

It shouldn’t an issue with my code since I have tried the joypad demo but still the same behavior happens : the controller connects fine but no inputs are recognized.

Are you input map entries for joypad input’s device set to all

Yes they are.

Have you tried printing all input events while the controller is being used? Wondering if its being recognized at all by Godot, but missing the action designation.

Godot uses a 3rd party database, but should try and defualt to some input designation if a model is not in the database.

Or maybe its just not supported at all

I have noticed that when you have a controller disabled on game launch and then hot plug it, no GUI input events work for the controller. But when the game launches with the controller active, the GUI input events work just fine. Really odd behavior. Will try to make a minimum repo soon to demo this. I’m open to it being user error but I feel this might be a bug with Godot.

Ok so I was able to figure this out.

It turns out that when the controller is hot plugged, it no longer is “Device 0” as far as Godot can tell. Many of the default “ui_*” actions are mapped to “Device 0” rather than “All Devices” this is why hot plugging a controller after game start up resulting in items like the (xbox controller) A button being able to select UI buttons but the joysticks from that same controller are unable to allow me to select different buttons to press.

The solution:

Go into your Input map settings and type “ui_” or filter by event “joypad axis” make sure that all actions that accept a Joypad Axis are set to “All Devices”.

1 Like