Gaze Input Trigger to New Scene

Hey guys! I’m am completely new to coding and unity
Currently using Unity 5.6.2 with GoogleVR v. 1.6
I created two 360 video scenes and a quad as a trigger but I don’t know how to put in gaze input trigger to a new scene.
I was just wondering if someone can help me on where to start!
Thank you!

Well you should really start with the Scripting Tutorials or you’re gonna have a real bad time trying to develop for VR.

In this case I’m guessing you probably need a Raycast.

You could accomplish it like this:

RaycastHit hit;

if(Physics.Raycast(transform.position, transform.forward, out hit, 5f))
{
    if(hit.collider.name == "Gaze Quad")
    {
        // The camera is looking at the quad
    }
}

That example alone though, uses static methods, the out parameter modifier, vectors, floats, reference/value types, local/global scope and conditional branching. All of these have their quirks and intricacies and can trip you up when you’re a beginner.

Thank you! I’ve been watching tutorials and was able to combine change scene scripts and gaze scripts to make it work!