Skip to content

Changing profile at runtime with MixedRealityToolkit.Instance.ActiveProfile = profileToUse; throws NullReferenceException #10720

@nutmeg15

Description

@nutmeg15

Describe the bug

When attempting to set a profile at runtime by following these instructions, a null reference error is thrown.

To reproduce

Steps to reproduce the behavior:

  1. Configure and save an MRTK profile
  2. Give the script a public MixedRealityToolkitConfigurationProfile named profileToUse
  3. Include MixedRealityToolkit.Instance.ActiveProfile = profileToUse
  4. Set profileToUse to the previously saved MRTK profile in Unity Inspector
  5. Run in play mode to get the error

Expected behavior

The MRTK profile should switch easily.

Screenshots

image

Your setup (please complete the following information)

  • Unity Version 2020.3.36f1
  • MRTK Version v2.7.3.0

Target platform (please complete the following information)

  • Oculus Quest 2

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions