diff --git a/src/backend/Board.java b/src/backend/Board.java index 7125824..c4de5a4 100644 --- a/src/backend/Board.java +++ b/src/backend/Board.java @@ -242,9 +242,6 @@ return false; } return lastMove; } - - - /** * Reverts the board state back one move. */ @@ -266,10 +263,10 @@ return false; } } // 3) Restore all other game‐state fields - this.chosenPiece = prev.chosenPiece; - this.turnNumber = prev.turnNumber; - this.isTurnWhite = prev.isTurnWhite; - this.lastMove = prev.lastMove; + this.chosenPiece = prev.chosenPiece; + this.turnNumber= prev.turnNumber; + this.isTurnWhite= prev.isTurnWhite; + this.lastMove= prev.lastMove; this.highlightedSquares = new ArrayList<>(prev.highlightedSquares); // 4) **Critical**: reset each Piece’s own coordinates to match its array slot