Xbox gamepad limit? General gamepad support?

This is probably my only real area of concern for this engine, I’m blown away by everything else (the IDE integration, the Nintendo Switch support, the dedicated 2D engine…)

I was searching the forum and the threads I could find on this topic are quite old (2019), looks promising, support for multiple gamepads added (awesome) but I was just wondering;

What’s the current status for gamepad support when it comes to;

  • Supporting all kinds of wacky 3rd party gamepad controllers, or even just Xbox One and PS4 gamepads on PC?
  • That pesky “4 gamepad limit” for Xinput gamepads, the usual option is to fall back on Directinput support

While I don’t expect anything to compete with the level of gamepad suppor that Rewired brings to Unity, I was wondering if there was a page devoted to what current gamepads are tested working on Defold and if the 4 gamepad limit has been addressed? And if not, where these issues may sit in priority list for Defold development?

Gamepads/controllers are supported on all platforms except iOS (we have it in our backlog with low prio).

We have a fairly long list of supported gamepads that can be viewed by opening builtins/input/default.gamepads. The file in raw/text format can also be viewed here:

Note that the bindings are per platform which means that we might lack bindings for a certain controller and platform combination. You can easily add your own bindings using a command line tool we provide.

We also have support for raw gamepad input. This is useful when there is a connected gamepad without an explicit binding.

Documentation: Gamepad input in Defold

We do use Xinput for gamepad detection on Windows so I guess there is a 4 gamepad limit:

This is the first time anyone has raised this issue so it is currently not prioritised at all.

Wow that’s quite the list of gamepads, it’s sounding pretty good actually!

Greater than 4 player games are a more extreme case (and even then, it only affects people who are exclusively using xbox gamepads to go over the 4 gamepad limit) but it was often enough that I was getting complaints about it on my game HopSquash! (even with it’s tiny player base).

But this engine has way more random gamepad layouts than most other engines. Thanks for the quick reply, I’m really looking forward to making some prototypes with Defold.

1 Like

Possibly making a native extension for would enable you to have more than 4 gamepad inputs at once on Windows.

Possibly could use Windows.Gaming.Input (should get you unlimited xbox controller inputs)

I’m not sure if the raw input is actually Raw Input but if it is you could possibly use that too though you may need to use a blank gamepads file to force everything to be raw (not sure).

You will need to do your own testing and research but it does seem like this would be possible if you can do some native extension coding.

1 Like

It still uses Xinput so it is affected by the same limitations in terms of number of simultaneous gamepads.


Thanks guys. Well I will be experimenting anyway, I have a lot of different gamepads and 5 xbox gamepads (big local multiplayer fan), I’ll see what I can find out.


Not yet, I haven’t even started my Defold project! Was just asking a head of time to give myself something to think about.

Local multiplayer is the absolute best. Hope this works out well for you!

Thanks man, yes they are, great for having people over, there’s always something fun to do :slight_smile: