void Awake() { Debug.Log("Loading NarrationSceneController"); if (instance == null) { instance = this; } else if (instance != this) { Destroy(gameObject); } if (DataManager.instance.CurrentState.CurrentScene == null) { currentScene = new Narration_Intro(); DataManager.instance.CurrentState.CurrentScene = currentScene.SceneName; } else { currentScene = SceneFinder.GetSceneFromName(DataManager.instance.CurrentState.CurrentScene); } }
public void Awake() { Debug.Log("Loading DialogueSceneController"); if (instance == null) { instance = this; } else if (instance != this) { Destroy(gameObject); } if (DataManager.instance.CurrentState.CurrentScene == null) { //Debug.Log("No scene to play. Returning to Title."); //DataManager.instance.LoadNextScene(new TitleScene()); Debug.Log("Playing test scene"); _currentScene = SceneFinder.GetSceneFromName("TestScene"); } else { _currentScene = SceneFinder.GetSceneFromName(DataManager.instance.CurrentState.CurrentScene); } }
public void SetUpOnClick(ISceneClass nextScene, string[][] dialogue) { NextScene = nextScene; Dialogue = dialogue; }
public void LoadNextScene(ISceneClass scene) { CurrentState.CurrentScene = scene.SceneName; SceneManager.LoadScene(scene.SceneType.ToString()); }