title: While loop won't break on bool C#
body: <p>I don't understand why my while loop won't stop looping when I assign a bool variable (gameEnded) to <code>true</code>.</p>
  
  <pre><code>Board board = new Board();
  bool gameEnded = false;
  while (!gameEnded)
  {
      gameEnded = board.DrawCheck(board); //one of these three methods returns true
      gameEnded = board.WinCheckO(board);
      gameEnded = board.WinCheckX(board);
  
      Render(board);
      bool turnO = false;
      Console.WriteLine("Player X's turn.");
      //... here some code that gets executed right
  }
  </code></pre>
  
  <p>So, gameEnded boolean variable should be assigned a value of true, and the loop, therefore, break. I checked that Check<em>something</em> methods return true.
  The modified version works just fine, that is, breaks the loop.</p>
  
  <pre><code>Board board = new Board();
  bool gameEnded = false;
  while (!gameEnded)
  {
  
      if (board.WinCheckX(board))
       {
           Console.WriteLine("X player won!");
           break;
       }
       else if (board.WinCheckO(board))
       {
           Console.WriteLine("O player won!");
           break;
       }
       else if (board.DrawCheck(board))
       {
           Console.WriteLine("It's a tie!");
           break;
       }
  
      Render(board);
      bool turnO = false;
      Console.WriteLine("Player X's turn.");
          //... here some code that gets executed right
  }
  </code></pre>
  
  <p>Thank you.</p>