don't repaint fields after game end

This commit is contained in:
Luca Conte 2024-12-23 23:12:43 +01:00
parent 8dd697bb66
commit 1b08b39105
1 changed files with 1 additions and 0 deletions

View File

@ -174,6 +174,7 @@ public class BoardDisplay extends JPanel {
if(currentShip != null) {
test = currentShip.getVirtualOccupiedPoints(mousePosition, horizontal);
}
if (player == null || player.getBoard() == null) return;
for(int i = 0; i < gridSize; i++) {
for(int j = 0; j < gridSize; j++) {
if(fields[i][j] == null) {