public static void GoToDeathScene() { CCSimpleAudioEngine.SharedEngine.StopBackgroundMusic(true); var scene = new DeathScene(mainWindow); director.ReplaceScene(scene); }
public void RestartLevel() { FindObjectOfType <AudioManager> ().PlayAudio("Menu Out"); if (SceneManager.GetActiveScene().buildIndex == 1) { SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex); } else if (SceneManager.GetActiveScene().buildIndex == 2) { if (Checkpoint.check != null) { DeathScene.SetActive(false); Checkpoint.check.RespawnPlayer(); Cursor.visible = false; } else { SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex); } } }
public void Death() { Cursor.visible = true; DeathScene.SetActive(true); }