public static void GameOverWin() { collectedLogs = 0; StaticData.ClearLevel(); StaticData.SetPlayerScore(); SceneManager.LoadScene("GameOverWin"); }
// Update is called once per frame void Update() { timer -= Time.deltaTime; timerText.text = string.Format("{00}", timer); //Victory and Lose Conditions if (timer <= 0) { StaticData.Score = 0; GameOverLose(); } if (collectedLogs >= logsToWin) { StaticData.SetPlayerScore(); StaticData.Score = 0; StaticData.ClearLevel(); GameOverWin(); } }