Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Bug XR Rig offset keeps resetting to 0 automatically after running a scene or building for headset.

Discussion in 'XR Interaction Toolkit and Input' started by ssidhant, Jan 26, 2021.

  1. ssidhant

    ssidhant

    Joined:
    Sep 9, 2019
    Posts:
    8
    I have a simple XR room scale camera rig added to a scene. I am trying to set the camera offset so my headset does not start in the floor. But every time I run the scene or switch scenes or build for an android headset (Vive Focus+ in this case), it resets back to 0 for some reason.
    Before run:
    upload_2021-1-26_11-21-4.png
    After run:
    upload_2021-1-26_11-23-2.png

    I am on Unity 2019.4.18 LTS Am I missing something since I would expect it to persist? I have saved it multiple times in the scene but it keeps resetting to 0.

    Any help would be appreciated.
     
  2. chris-massie

    chris-massie

    Unity Technologies

    Joined:
    Jun 23, 2020
    Posts:
    226
    In earlier versions of the package, the camera offset Y value was modified during OnValidate of the XRRig. This has been changed in newer versions to only happen while in play mode. Upgrading to a newer version should resolve this issue.
     
    ssidhant likes this.