diff options
| author | Aidan Ross <aross02@fairport.org> | 2023-05-17 09:38:01 -0400 | 
|---|---|---|
| committer | Aidan Ross <aross02@fairport.org> | 2023-05-17 09:38:01 -0400 | 
| commit | c959ad9620eaf2398bf455387e989f3129d4674f (patch) | |
| tree | 0aa4031753fbf1a252a70cea79770258175bb307 | |
| parent | bc7c7d96419a10d85e6b4a2ec5e1a2cbe78de9b1 (diff) | |
| parent | 39a01b860b1d348088202d89ac3e3fa10410f9ed (diff) | |
| download | NPEhero-c959ad9620eaf2398bf455387e989f3129d4674f.tar.gz NPEhero-c959ad9620eaf2398bf455387e989f3129d4674f.tar.bz2 NPEhero-c959ad9620eaf2398bf455387e989f3129d4674f.zip | |
Merge branch 'main' of https://gitlab.sowgro.net/guitarheros/guitarhero into main
| -rw-r--r-- | .vscode/launch.json | 3 | ||||
| -rw-r--r-- | src/gui/LevelSurround.java | 55 | 
2 files changed, 41 insertions, 17 deletions
| diff --git a/.vscode/launch.json b/.vscode/launch.json index 9596ad3..257652c 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -49,7 +49,8 @@              "name": "Driver",              "request": "launch",              "mainClass": "fallTest.Driver", -            "projectName": "GuitarHero" +            "projectName": "GuitarHero", +            "vmArgs": "--module-path lib/linux --add-modules javafx.base,javafx.media,javafx.graphics,javafx.controls,javafx.fxml"          },          {              "type": "java", diff --git a/src/gui/LevelSurround.java b/src/gui/LevelSurround.java index 22fcf97..bf71f2f 100644 --- a/src/gui/LevelSurround.java +++ b/src/gui/LevelSurround.java @@ -39,33 +39,56 @@ public class LevelSurround extends Pane          diff.setText("Easy");          diff.setFill(Color.WHITE); -        VBox textBox = new VBox(); -        textBox.setAlignment(Pos.TOP_RIGHT); -        textBox.getChildren().addAll(title,diff); +        VBox titleTextBox = new VBox(); +        titleTextBox.setAlignment(Pos.TOP_RIGHT); +        titleTextBox.getChildren().addAll(title,diff);          BorderPane topBar = new BorderPane();          topBar.setLeft(buttonBox); -        topBar.setRight(textBox); +        topBar.setRight(titleTextBox);          topBar.setPadding(new Insets(10)); -        Text title = new Text(); -        title.setText("Test level 1"); -        title.setFill(Color.WHITE); -        title.setFont(new Font(50)); -        Text diff = new Text(); -        diff.setText("Easy"); -        diff.setFill(Color.WHITE); +        Text scoreLabel = new Text(); +        scoreLabel.setText("Score:"); +        scoreLabel.setFill(Color.WHITE); + +        Text score = new Text(); +        score.setText("100000"); +        score.setFill(Color.WHITE); +        score.setFont(new Font(50)); + +        VBox scoreTextBox = new VBox(); +        scoreTextBox.setAlignment(Pos.BOTTOM_LEFT); +        scoreTextBox.getChildren().addAll(scoreLabel,score); +        scoreTextBox.setPadding(new Insets(10)); + + +        Text comboLabel = new Text(); +        comboLabel.setText("Combo:"); +        comboLabel.setFill(Color.WHITE); + +        Text combo = new Text(); +        combo.setText("100000"); +        combo.setFill(Color.WHITE); +        combo.setFont(new Font(50)); + +        VBox comboTextBox = new VBox(); +        comboTextBox.setAlignment(Pos.BOTTOM_RIGHT); +        comboTextBox.getChildren().addAll(comboLabel,combo); +        comboTextBox.setPadding(new Insets(10)); -        VBox textBox = new VBox(); -        textBox.setAlignment(Pos.TOP_RIGHT); -        textBox.getChildren().addAll(title,diff); +        Pane game = new Pane(); +        game.minWidthProperty().bind(super.heightProperty().multiply(0.66)); +        game.minHeightProperty().bind(super.heightProperty()); +        game.getStyleClass().add("textBox");          HBox centerBox = new HBox(); -        centerBox.getStyleClass().add("textBox"); +        centerBox.getChildren().addAll(comboTextBox,game, scoreTextBox); +        centerBox.setAlignment(Pos.BOTTOM_CENTER);          StackPane root = new StackPane(); -        root.getChildren().addAll(topBar,centerBox); +        root.getChildren().addAll(centerBox, topBar);          super.getChildren().add(root);          root.minWidthProperty().bind(super.minWidthProperty()); | 
