From 35a4ec76e420ed1d0e49ab1387b660d776b42f24 Mon Sep 17 00:00:00 2001 From: THarries <timonharries@googlemail.com> Date: Sun, 12 Jan 2025 18:35:15 +0100 Subject: [PATCH] fixed checkForWin board function --- src/logic/Board.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/logic/Board.java b/src/logic/Board.java index 819e85c..df523d2 100644 --- a/src/logic/Board.java +++ b/src/logic/Board.java @@ -61,7 +61,7 @@ public class Board{ } //checks diagonals //second try to get the fix pushed - if((gameboard[0][0] == gameboard[1][1] && gameboard[0][0] == gameboard[2][2]) || (gameboard[0][2] == gameboard[1][1] && gameboard[1][1] != '#') && gameboard[0][2] == gameboard[2][0] ) { + if((gameboard[0][0] == gameboard[1][1] && gameboard[0][0] == gameboard[2][2] && gameboard[1][1] != '#') || (gameboard[0][2] == gameboard[1][1] && gameboard[0][2] == gameboard[2][0] && gameboard[1][1] != '#')) { this.setWinner(gameboard[1][1]); return true; } -- GitLab