public void StartGame() { State = GameState.StartGame; PanelMainMenu.Play("Close"); PanelGamePlay.Play("Open"); Score = 0; ScoreTxt.text = ""; }
public void GameOver() { State = GameState.GameOver; PanelGameOver.Play("Open"); PanelGamePlay.Play("Close"); ScoreGame.text = Mathf.Round(Score).ToString(); foreach (Transform t in ObstacleParent) { Destroy(t.gameObject); } UpdateHigthScore(); }