Search Unity

  1. Unity 2020.1 has been released.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

VRSettings.enabled bug?

Discussion in 'AR/VR (XR) Discussion' started by lordubik, May 12, 2017.

  1. lordubik

    lordubik

    Joined:
    Feb 18, 2013
    Posts:
    71
    Hi, (help)
    I don't know if this a bug or am I that I wrong some things...
    but if I disable VR with VRSettings.enabled (set to false), the VR is disable BUT is not possible enable VR again in another game section... is it a bug? on player settings 'Virtual reality supported' is at true.

    Thanks for help!
     
  2. Mistabullit

    Mistabullit

    Joined:
    Aug 14, 2015
    Posts:
    7
    It is difficult to give guidance without a little more understanding of what is going on here. But I will take a few stabs in dark.

    I'm assuming you are doing something like this:

    1 You start playing in VR mode,
    2 You set VRSettings.enabled(false);
    3 You continue playing in some non vr fashion
    4 You set VrSettings.enabled(true), //If you are using a bool variable here, maybe try a debug.log just before this line in order to see what the bool is
    5 The scene remains the same as in step 3.
    6. You run a test script but it returns that VRSettings.enabled is in fact true?

    Have you loadedthedevicebyname? Sometimes this helps.
     
unityunity