- Home /
Xbox usb controller button in WebGL
I wonder if there is anyone that have tried using Xbox usb game pads in WebGL and made the buttons work?
The joystick axis works perfectly fine in WebGL but I have no clue how to make the buttons work. It feels like I have tried everything. I just need some hope.
(Of course everything works as intended in the editor, but not when building, then only the keyboard and joy-axis works).
Have anyone of you tried this and if that's the case could you point me in some direction or even provide some sample code of how you did it?
The only thing that has worked so far is InputManager.anyKeyDown which gives me some kind of input at least, but how to be able to get a specific button is still a mystery.
Answer by Schubkraft · May 04, 2015 at 09:39 AM
This is a bug http://issuetracker.unity3d.com/issues/input-dot-getbutton-does-not-catch-joystick-buttons and will be fixed for 5.1.
Your answer
Follow this Question
Related Questions
[XBOX][CONTROLLER][INPUT] Xbox controller "Console/Guide" button not mapped in unity 1 Answer
Xbox 360 gamepad numbers mixed up 0 Answers
Xbox One controller on iOS spams GetKeyUp and GetKeyDown every frame while a button is pressed 0 Answers
Xbox controller issue on using OVRGamepadController on mac 0 Answers
XInput for controller/gamepad rumble breaks builds (works fine in editor) 0 Answers