Skip to content

Commit

Permalink
Included the viewing of player positions on console.
Browse files Browse the repository at this point in the history
  • Loading branch information
redleek committed Dec 6, 2014
1 parent 807f0b4 commit 42305c5
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion TacticalSpaceCheeseRacer/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,17 @@ static void PrintAllPositions()
Console.WriteLine("{0}. {1} - {2}", playercount + 1, players[playercount].name, players[playercount].position);
}
}

/// <summary>
/// Macro to clear the console to make it more visualy appealing and display
/// all important information such as positions of all the players.
/// </summary>
static void ResetConsole()
{
Console.Clear();
PrintAllPositions();
Console.WriteLine();
}
#endregion

#region Gameplay Functions
Expand Down Expand Up @@ -495,7 +506,7 @@ static void Main(string[] args)

Console.Write("Press enter to continue...");
Console.ReadLine();
Console.WriteLine();
ResetConsole();
}
} while (!gamewon);

Expand Down

0 comments on commit 42305c5

Please sign in to comment.