void UpdateCurrentScene() { if (sceneRoot) { // update SceneStreaming system SceneStreamManager.SetCurrentScene(nextSceneName); } }
void Awake() { if (m_instance == null) { m_instance = this; } else if (m_instance != this) { Destroy(gameObject); return; } }
protected override void onTrigger(GameObject interactor) { if (interactor != null) { if (interactor.GetComponent <Attackable>().Alive == false) { return; } Debug.Log("Triggered"); Debug.Log(CurrentPlayerSettings.GetCurrentPlayer()); Debug.Log(interactor); if (CurrentPlayerSettings.GetCurrentPlayer() == interactor) { Debug.Log("Loading scenes"); SceneStreamManager.LoadStreamedScenes(ScenesToLoad); } if (MoveToScene != null) { SceneStreamManager.MoveObjectToScene(interactor, MoveToScene); } } }
public void Start() { SceneStreamManager.SetCurrentScene(startSceneName); Destroy(this); }