-
-
Notifications
You must be signed in to change notification settings - Fork 120
Description
Describe the bug
OnHandUpdate condition checks don't account for handData.hand == 0
To Reproduce
Steps to reproduce the behavior:
- Open WebXRInputSystem.cs
- Add console log above "DisableHandRight();" call
Debug.Log("Invalid Hand: "+(handData.hand == 0)); - Make build
- Enable & Disable your hands via emulator or other means
- Notice console prints "Invalid Hand: true"
Expected behavior
No update should occur if OnHandUpdate is called with an invalid hand
e.g. adding a guard clause at the beginning of OnHandUpdate: if (handData.hand == 0) return;
Unity info (please complete the following information):
- Editor version: 6000.0.32f1
- WebXR package version: 0.22.1
- WebXR Interactions version: 0.22.0 (with previous hand event fix)
- OpenUPM
- Input System + XR Interaction Toolkit
- Built-in render pipeline
Desktop (please complete the following information):
- Windows 11
- Chrome
Additional context
I noticed a few spots that default to right hand that should probably check for hand == 2.
I found this while trying to debug a fatal input manager "memory out of bounds" error that was infrequently thrown when Exiting VR in my Quest 3.
Also unrelated but in case you didn't see the tracked pose driver bug claims to have been fixed in InputSystem package 1.13.2 https://issuetracker.unity3d.com/issues/gameobject-is-placed-at-position-0-0-0-when-entering-play-mode-if-using-trackedposedriver