WebXR Hand Tracking default meshes not visible because they are attached to wrong scene

Repro: https://playground.babylonjs.com/#9K3MRA#2076

When you call scene.createDefaultXRExperienceAsync and the user device has hand tracking, the default hand models are not guaranteed to load into that same scene if more than one scene exists.

This is because the attach method of WebXRHandTracking uses EngineStore.LastCreatedScene

Observed: the hand meshes are not visible; though general hand tracking interaction works normally

Expected: any effects of scene.createDefaultXRExperienceAsync would apply to that same scene

2 Likes