Implemented GUI side of resetting the board
This commit is contained in:
@@ -23,7 +23,6 @@ public class Engine extends Application {
|
||||
private boolean mouseClicked = false;
|
||||
private Point coordinates = new Point();
|
||||
private Stage primaryStage;
|
||||
private MouseEvent mouseEvent;
|
||||
|
||||
public Engine() {
|
||||
setEngine(this);
|
||||
@@ -91,6 +90,9 @@ public class Engine extends Application {
|
||||
System.err.println("Wrong length of gameState string");
|
||||
return;
|
||||
}
|
||||
if (gameState.equals("---------")){
|
||||
grid.getChildren().clear();
|
||||
}
|
||||
for (int i = 0; i < gameState.length(); i++) {
|
||||
int column = i / 3;
|
||||
int row = i % 3;
|
||||
|
||||
Reference in New Issue
Block a user