- Home /
Xbox 360 controller number not corresponding to joystick number in axis settings
I'm working on a four player local multiplayer game, which I have recently started demoing at expos: I am using wired Xbox 360 controllers for this, and I have noticed a problem with the mapping between the numbers displayed on the controllers and that of the joystick number assigned to in the axis settings.
The following test illustrates the problem:
Create three sets of axes, one each for joysticks one, two and three, and set up with appropriate scripts to report back on the values being received by each of these.
Plug in two Xbox 360 controllers - the identifier lights around the Xbox button will denote these as controllers 1 & 2
Start the test game: the reporting script shows that controller one is setting the values for the axis mapped to joystick one, and that controller two is setting values from joystick two. Great.
Unplug controller one and plug in back in again - the identifier lights still indicate that this is controller one, but the reporting scripts now show that this controller is setting values for the axis mapped to joystick three! Not good...
Understandably, this has caused considerable confusion for those playing at these shows, and needs resolving before I can even hope to go live.
I have done some searching on here and all I could find was this, which dates back over two years and has not been answered. Has anyone else experienced and/or resolved this issue?
I am using Unity 2017.2
Your answer
Follow this Question
Related Questions
360 Trigger Pressing both Triggers at the same time 1 Answer
Multiple x360 controllers get wrong IDs assigned. 2 Answers
Detecting Controllers 0 Answers
Multiple controller buttons Xbox 360 & PS3 different controllers 1 Answer
XInput for controller/gamepad rumble breaks builds (works fine in editor) 0 Answers