Add comments

This commit is contained in:
KaseToatz1337
2024-11-07 10:18:20 +01:00
parent 32055107ab
commit 4c01b5ae79
5 changed files with 43 additions and 11 deletions

View File

@ -12,6 +12,7 @@ namespace Memory.Cmd
{
Game game = new(new ScoreHandler(), name, 10);
CmdGame cmdGame = new(game);
// While the game isn't finished ask for a card index then attempt to click the card
while (!game.IsFinished())
{
cmdGame.Redraw();
@ -24,6 +25,7 @@ namespace Memory.Cmd
}
Console.Clear();
cmdGame.WriteScores();
// Ask if the player wants to play again, if not break out of the loop and the program is finished
if (!CmdGame.ShouldReplay())
{
break;