Updated 'PlayerData' class.

Updated the 'PlayerData' class by updating the 'Piece' creation inside the constructor.
This commit is contained in:
Daniel Grigencha
2024-12-03 00:50:53 +01:00
parent 1870d4fe0e
commit 3a02edb944

View File

@@ -39,7 +39,7 @@ public PlayerData(Color color) {
waitingArea = new Piece[Resources.MAX_PIECES]; waitingArea = new Piece[Resources.MAX_PIECES];
for (int i = 0; i < Resources.MAX_PIECES; i++) { for (int i = 0; i < Resources.MAX_PIECES; i++) {
homeNodes[i] = new HomeNode(); homeNodes[i] = new HomeNode();
pieces[i] = new Piece(color, PieceState.WAITING, i); pieces[i] = new Piece(color, PieceState.WAITING);
waitingArea[i] = pieces[i]; waitingArea[i] = pieces[i];
} }
} }