Description
I have a requirement to poll gamepad data to handle button and joystock inputs. Polling it externally is clunky as I have to make dynamic callbacks when a controller connects.
I was forced to patch to the controller to override the update method to handle gamepad data. And it provides individual events for gamepad controls.
https://github.com/danrossi/three-xr-controller/blob/main/src/XRController.js#L132
If an update event or callback is provided on the controller individual gamepad data can be handled.
Or integrate this code as a feature in examples
https://github.com/danrossi/three-xr-controller/blob/main/src/XRController.js#L79
Solution
An event provided on the update method of the WebXRController or an event on the XRControllerModel but its not obvious which button is active in that.
Alternatives
na
Additional context
No response