WebXR Emulator controller has wrong button mapping

This is a follow up of: [XR] Trigger and Squeeze buttons are swapped when using WebXR Emulator · Issue #12826 · BabylonJS/Babylon.js · GitHub

Hey, @RaananW I think I found the bug, seems to me that the oculus-touch-legacy is wrongly assigned to the WebXR Emulator controller.

In that profile, the trigger is assigned to index 1 instead of 0, causing the issue. I have the fix in place but since I am not a javascript/typescript expert, I am still struggling to build babylonjs locally.

I will open a PR as soon as I can test it.

I actually answered in the github issue. This is an issue with the emulator and not babylon. We automatically assign profiles based on what the device/environment provides us. Unless you found an issue in the code where we are doing something wrong, you will need to ask the emulator devs to fix it. AFAIK it is not being actively developed, so this might take some time.

Sorry, haven’t answered regarding the PR - if you have a fix, please go ahead and submit it! I will be happy to review it :slight_smile: