Esempio n. 1
0
 public void SomeTest()
 {
     bool[,] field         = new bool[3, 3];
     bool[,] expectedField = new bool[3, 3];
     field[2, 2]           = true;
     field = Game.NextStep(field);
     Assert.AreEqual(field, expectedField);
 }
Esempio n. 2
0
 public static void StartGame(bool[,] field, int maxIterations = int.MaxValue)
 {
     for (int i = 0; i < maxIterations; i++)
     {
         Paint(field);
         Thread.Sleep(100);
         field = Game.NextStep(field);
     }
 }
Esempio n. 3
0
        static void Main(string[] args)
        {
            var field = new bool[20, 20];

            field[5, 5] = true;
            field[6, 5] = true;
            field[7, 5] = true;
            while (true)
            {
                Paint(field);
                Thread.Sleep(500);
                field = Game.NextStep(field);
            }
        }