Search code examples
c#unity-game-enginegoogle-cardboardvirtual-reality

How to access the cardboard trigger on google Gvr( in code)? 1.6 version SDK


How to access the cardboard trigger on google Gvr( in code) ? In the earlier version it was GvrViewer.Instance.Triggered


Solution

  • I use Input.GetButtonDown("Fire 1") and it works for me on the latest SDK version (1.6) and latest Unity version (5.6)

    EDIT: Use Input.GetButtonDown("Fire1") if you follow the default naming conventions for input events supported by unity. Please note that there is no space character between "Fire" and "1".

    Otherwise, you might the error - "ArgumentException: Input Button Fire 1 is not setup."