public Game(Window window) { highScores = new int[10]; TryLoadingHighscores(); SetUpBackground(); mainMenu = new Menu(); mainMenu.InitGame += StartGame; mainMenu.QuitGame += window.CloseAfterFrame; InteractionLogic = new InteractionLogic(); mainMenu.UpdateHighscoreDisplay(highScores); }
private void RefreshHighScores() { AddLastScoreToHighscoreIfQualified(); mainMenu.UpdateHighscoreDisplay(highScores); SaveHighScore(); }