Skip to content
Snippets Groups Projects
Commit 23c728b9 authored by Barth Carolin's avatar Barth Carolin
Browse files

Able to change Scenes between Start and Options now

parent 68dbc7e7
No related branches found
No related tags found
No related merge requests found
......@@ -57,16 +57,14 @@ public class StartScreen extends Application {
stages=stage;
stage.setResizable(false);
stage.setTitle("Snake Game");
changeScene("/fxml/welcomeScene.fxml" , "/styles/styles.css");
changeScene("/fxml/start.fxml" , "/styles/styles.css");
log.info("Application started");
// Image icon= new Image(new FileInputStream("src/main/ressources/images...png")); Icon screen
// Image icon= new Image(new FileInputStream("src/main/resources/images...png")); Icon screen
//stage.getIcons().add(icon); Icon screen
stage.show();
}
@FXML
public void openOptions() {
log.info("Clicked :)");
......
......@@ -5,6 +5,6 @@ import javafx.event.ActionEvent;
public class StartScreenController {
public void openOptions(ActionEvent actionEvent) {
StartScreen.changeScene("fxml/OptionsScreen.fxml", "styles/styles.css");
StartScreen.changeScene("/fxml/OptionsScreen.fxml", "/styles/styles.css");
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment