Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Button UI pauses to work when XR rig is active. (new Input System)

Discussion in 'Input System' started by bjornsyse, Dec 30, 2020.

  1. bjornsyse

    bjornsyse

    Joined:
    Mar 28, 2017
    Posts:
    92
    I'm having problems with my Unity UI in conjunction with my XR rig. Menu buttons works until I actively move or put on my Oculus headset and it goes out of standby, then buttons stop working. If I wait for the Oculus headset image to freeze again, something happens with the input devices and UI buttons starts to work again.

    Screengrab: https://dl.dropboxusercontent.com/s/mxd8eq1hqggf8kq/2020-12-30_14-56-39.mp4

    vlc_2020-12-30_15-05-37.jpg
    I am using an EventSystem with a InputSystemUIInputModule script hooked up to the DefaultInputAction ActionsAsset

    Unity_2020-12-30_15-02-18.jpg

    Thankful for any input on how to troubleshoot this.

    Regards

    Björn
     
  2. bjornsyse

    bjornsyse

    Joined:
    Mar 28, 2017
    Posts:
    92
    One additional observation: Even If I remove all XR related rigs from my scene, and not even have a single camera rendering - the UI behaves the same. If I rumble the Oculus headset and have it go out of standby (even though it's not doing anything in the scene) - my UI still stops working and responding to input.

    I have no clue how this all ties together, but it's like the change of whatever devices the system detects make the input system hold. That's the impression at least.
     
  3. bhermer

    bhermer

    Joined:
    Jun 24, 2013
    Posts:
    28
    Hey did you make any progress with this? Getting a similar issue, as well as the screenspace occupied by the vr camera not updating at all once the headset is removed.
     
  4. bjornsyse

    bjornsyse

    Joined:
    Mar 28, 2017
    Posts:
    92
    I just had to revert to the old event system way of doing it.
     
  5. bhermer

    bhermer

    Joined:
    Jun 24, 2013
    Posts:
    28
    Yeah seems to be the only solution at the moment, frustrating
     
  6. Piflik

    Piflik

    Joined:
    Sep 11, 2011
    Posts:
    290
    It seems like the VR system automatically hijacks the UI event system. I managed to fix this issue by selectng "Single Unified Pointer" or "All Pointers As Is" in the Event System's Pointer Behaviour dropdown. By default, it seems Unity can only use a single input device, and apparently the VR Controller takes precedent.
     
    Ensortainment likes this.
  7. Ensortainment

    Ensortainment

    Joined:
    Dec 19, 2020
    Posts:
    14
    I love you. Thank u.