mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-22 23:26:40 -08:00
Moving pause location to the end of iteration.
This commit is contained in:
@@ -107,9 +107,6 @@ void ProcessSimulation()
|
|||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
if (pauseBetweenIterations > TimeSpan.Zero)
|
|
||||||
Thread.Sleep(pauseBetweenIterations);
|
|
||||||
|
|
||||||
Console.WriteLine($"GENERATION: {simulation.Generation}\tPOPULATION: {simulation.Population}");
|
Console.WriteLine($"GENERATION: {simulation.Generation}\tPOPULATION: {simulation.Population}");
|
||||||
if (isInvalid)
|
if (isInvalid)
|
||||||
Console.WriteLine("INVALID!");
|
Console.WriteLine("INVALID!");
|
||||||
@@ -242,6 +239,9 @@ void ProcessSimulation()
|
|||||||
minY--;
|
minY--;
|
||||||
maxX++;
|
maxX++;
|
||||||
maxY++;
|
maxY++;
|
||||||
|
|
||||||
|
if (pauseBetweenIterations > TimeSpan.Zero)
|
||||||
|
Thread.Sleep(pauseBetweenIterations);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user