public void EndGame() { if (dome.IsDead()) { return; } dome.Dead(); _playing = false; // send score to high score site int total = _points * birdSpawner.ReachedWave(); Debug.Log("TODO: high scores?"); //if (HighScores.Instance.myTopScore == null || total > HighScores.Instance.myTopScore.score) // HighScores.Instance.AddNewHighScore(PlayerPrefs.GetString("username"), total, Mathf.CeilToInt(_seconds)); //else // HighScores.Instance.lastScore = new HighScore(PlayerPrefs.GetString("username"), total); ui.settingsButton.SetActive(false); StartCoroutine(DeathSequence()); }