I’ve created a small game in which ten players compete locally. I’ve done this by using JoyToKey to remap several buttons from a number of gamepads to 40 different keystrokes. This works, but has two major drawbacks: 1) Anyone else who would like to play this game will have to set up their own keystroke emulator; 2) I can only use as many buttons across all controllers as I can map onto one keyboard (max of about 5 per controller).
I’ve been looking at the Gamepad extension in order to understand how one uses JavaScript and events to access the states of gamepad button presses, etc. But don’t see where the interface between the extension and the OS is happening in order to get at the button presses.
What is the Gamepad extention using to access controller button states, and what resources do I need to be looking at in order to understand it and create something like it myself?