Browse Source

Tic Tac Toe updated 0Win method to print that Player 0 wins

remotes/origin/develop
fdai6040 2 years ago
parent
commit
55ce78fab6
  1. 5
      src/main/java/src/TicTacToeGame.java

5
src/main/java/src/TicTacToeGame.java

@ -145,6 +145,11 @@ public class TicTacToeGame implements ActionListener {
bton[i1].setBackground(Color.PINK); bton[i1].setBackground(Color.PINK);
bton[i2].setBackground(Color.PINK); bton[i2].setBackground(Color.PINK);
for (int j = 0; j < 9; j++)
{
bton[j].setEnabled(false);
}
textfield.setText("Player O Wins");
} }
//method if player X wins //method if player X wins

Loading…
Cancel
Save