Skip to content

Controllers shown at original place after teleporting in VR. #5423

@rahsingh-ms

Description

@rahsingh-ms

Describe the bug

We are using the WindowsMixedRealityControllers for our App's VR version and when we attempt to teleport in our app, We can see camera hands at the original position.

To reproduce

Steps to reproduce the behavior:

  1. Open VR app on Windows
  2. Try teleporting/moving the main camera to some other location
  3. We can see controllers left behind at original position.

Describe the solution:

This issue is happening because of an error in WindowsMixedRealityController.cs class.
In the function
private async void CreateControllerModelFromPlatformSDK(uint interactionSourceId)

when the GLTF is found from platfor, while creating the gameobject for controller visualization, we are not adding it to under MixedRealityPlayspace but it is getting added directly to root scene which is causing the issue of seeing controllers at original position after teleportation.

image

The fix is in the BaseController.cs file.
In the function:
protected virtual bool TryRenderControllerModel(Type controllerType, InputSourceType inputSourceType)

we add MixedRealityPlayspace.AddChild(controllerObject.transform);

This line should actually be moved inside TryAddControllerModelToSceneHierarchy function

so that even if we use the platform controller visualization, they will be correctly added to under MixedRealityPlaySpace game object.

Your Setup (please complete the following information)

issue on mrtk_development branch

Target Platform (please complete the following information)

  • WMR immersive

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions