Final changes
This commit is contained in:
@ -102,7 +102,7 @@ namespace Memory.Cmd
|
||||
// Print the players score to the console then loop over highscores to print those aswell
|
||||
Console.WriteLine($"Your score: {game.Scoring.Points}\nTop 10 Highscores:");
|
||||
List<Score> highscores = game.ScoreHandler.GetTopScores();
|
||||
for (int i = 0; i < highscores.Count; i++)
|
||||
for (int i = 0; i < Math.Min(Game.LEADERBOARDSIZE, highscores.Count); i++)
|
||||
{
|
||||
Score score = highscores[i];
|
||||
Console.WriteLine($"{i+1}. {score.Name}: {score.Points}");
|
||||
|
Reference in New Issue
Block a user