// Update is called once per frame void Update() { if (locationHandler == null) { locationHandler = GameObject.Find("Location").GetComponent <LocationHandler>(); } else if (locationHandler != null && !locationHandler.started) { locationHandler.StartLocation(); } else if (locationHandler.finished && !SteamVR_LoadLevel.loading) { locationIdx++; if (locationIdx < sceneNames.Length) { //Debug.Log("Load scene [" + locationIdx + "]: " + sceneNames[locationIdx]); SteamVR_LoadLevel.Begin(sceneNames[locationIdx]); locationHandler = null; } } }