|
|
@ -48,7 +48,6 @@ public class GameLogic { |
|
|
|
// check columns |
|
|
|
for (int i = 0; i < this.board.length; i++) { |
|
|
|
for (int j = 0; j < this.board[0].length; j++) { |
|
|
|
System.out.println(j + ", " + i); |
|
|
|
if(board[j][i] == player) countFields++; |
|
|
|
} |
|
|
|
if(countFields == this.board.length) return finished = true; |
|
|
@ -61,8 +60,9 @@ public class GameLogic { |
|
|
|
for (int j = 0; j < this.board.length; j++) { |
|
|
|
if(board[i][j] == player) countFields++; |
|
|
|
} |
|
|
|
if(countFields == this.board.length) return finished = true; |
|
|
|
countFields = 0; |
|
|
|
} |
|
|
|
if(countFields == this.board.length) finished = true; |
|
|
|
|
|
|
|
return finished; |
|
|
|
} |
|
|
|