Fixen kleiner Bugs
This commit is contained in:
parent
8f8f5a5f96
commit
337285ea29
Happy_Bird
.gradle
7.1.1
buildOutputCleanup
build
classes/java/main/com/example/happy_bird
libs
resources/main/com/example/happy_bird
tmp/compileJava
src/main/java/com/example/happy_bird
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -7,4 +7,13 @@
|
|||||||
|
|
||||||
<StackPane prefHeight="800.0" prefWidth="700.0" xmlns="http://javafx.com/javafx/11.0.2" xmlns:fx="http://javafx.com/fxml/1" fx:controller="com.example.happy_bird.HappyBird" back >
|
<StackPane prefHeight="800.0" prefWidth="700.0" xmlns="http://javafx.com/javafx/11.0.2" xmlns:fx="http://javafx.com/fxml/1" fx:controller="com.example.happy_bird.HappyBird" back >
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
|
=======
|
||||||
|
<ImageView>
|
||||||
|
<image>
|
||||||
|
<Image url="@pics/Background.png"></Image>
|
||||||
|
</image>
|
||||||
|
</ImageView>
|
||||||
|
|
||||||
|
>>>>>>> 5db5b6bb195a2b7d1296e7d3f9b98d6c75dba2c2
|
||||||
</StackPane>
|
</StackPane>
|
||||||
|
Binary file not shown.
@ -69,9 +69,9 @@ public class HappyBirdMain extends Application {
|
|||||||
Button startButton = new Button("START");
|
Button startButton = new Button("START");
|
||||||
Button highscoresButton = new Button("HIGHSCORES");
|
Button highscoresButton = new Button("HIGHSCORES");
|
||||||
Button settingsButton = new Button("EINSTELLUNGEN");
|
Button settingsButton = new Button("EINSTELLUNGEN");
|
||||||
Button spielStarten = new Button("SPIEL STARTEN");
|
Button startGame = new Button("SPIEL STARTEN");
|
||||||
|
|
||||||
Button buttons[] = {startButton, highscoresButton, settingsButton, spielStarten};
|
Button buttons[] = {startButton, highscoresButton, settingsButton, startGame};
|
||||||
Button menuButton = new Button("ZURÜCK");
|
Button menuButton = new Button("ZURÜCK");
|
||||||
menuButton.setStyle("-fx-background-color: #e86000; " +
|
menuButton.setStyle("-fx-background-color: #e86000; " +
|
||||||
"-fx-text-fill: #FFFFFF; " +
|
"-fx-text-fill: #FFFFFF; " +
|
||||||
@ -86,8 +86,7 @@ public class HappyBirdMain extends Application {
|
|||||||
menuButton.setLayoutX(575);
|
menuButton.setLayoutX(575);
|
||||||
menuButton.setLayoutY(625);
|
menuButton.setLayoutY(625);
|
||||||
menuButton.setVisible(false);
|
menuButton.setVisible(false);
|
||||||
|
startGame.setVisible(false);
|
||||||
Button buttons[] = {startButton, highscoresButton, settingsButton};
|
|
||||||
|
|
||||||
int yPosition = 225;
|
int yPosition = 225;
|
||||||
for (Button button : buttons) {
|
for (Button button : buttons) {
|
||||||
@ -107,14 +106,7 @@ public class HappyBirdMain extends Application {
|
|||||||
"-fx-background-radius: 20px;");
|
"-fx-background-radius: 20px;");
|
||||||
}
|
}
|
||||||
|
|
||||||
spielStarten.setVisible(false);
|
startGame.setVisible(false);
|
||||||
|
|
||||||
startButton.setOnAction(event -> {
|
|
||||||
headline.setText("Start");
|
|
||||||
for(Button button : buttons) {
|
|
||||||
button.setVisible(false);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
Label nameLabel = new Label("Name:");
|
Label nameLabel = new Label("Name:");
|
||||||
Label acronymLabel = new Label("Kürzel:");
|
Label acronymLabel = new Label("Kürzel:");
|
||||||
@ -139,6 +131,7 @@ public class HappyBirdMain extends Application {
|
|||||||
yPositionStartLabels += 150;
|
yPositionStartLabels += 150;
|
||||||
|
|
||||||
pane.getChildren().add(label);
|
pane.getChildren().add(label);
|
||||||
|
label.setVisible(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
TextField name = new TextField();
|
TextField name = new TextField();
|
||||||
@ -157,15 +150,31 @@ public class HappyBirdMain extends Application {
|
|||||||
yPositionInputFields += 150;
|
yPositionInputFields += 150;
|
||||||
|
|
||||||
pane.getChildren().add(feld);
|
pane.getChildren().add(feld);
|
||||||
|
feld.setVisible(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
spielStarten.setVisible(true);
|
startButton.setOnAction(event -> {
|
||||||
|
headline.setText("Start");
|
||||||
|
for(Button button : buttons) {
|
||||||
|
button.setVisible(false);
|
||||||
|
|
||||||
spielStarten.setLayoutY(520);
|
}
|
||||||
|
|
||||||
|
startGame.setVisible(true);
|
||||||
|
menuButton.setVisible(true);
|
||||||
|
startGame.setLayoutY(520);
|
||||||
|
|
||||||
|
for(TextField feld : inputFields) {
|
||||||
|
feld.setVisible(true);
|
||||||
|
}
|
||||||
|
for (Label label : startLabels )
|
||||||
|
{
|
||||||
|
label.setVisible(true);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
startButton.setOnAction(event -> {});
|
startGame.setOnAction(event -> {});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -221,6 +230,14 @@ public class HappyBirdMain extends Application {
|
|||||||
menuButton.setVisible(false);
|
menuButton.setVisible(false);
|
||||||
soundSlider.setVisible(false);
|
soundSlider.setVisible(false);
|
||||||
soundLabel.setVisible(false);
|
soundLabel.setVisible(false);
|
||||||
|
startGame.setVisible(false);
|
||||||
|
for(TextField feld : inputFields) {
|
||||||
|
feld.setVisible(false);
|
||||||
|
}
|
||||||
|
for (Label label : startLabels )
|
||||||
|
{
|
||||||
|
label.setVisible(false);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
stage.show();
|
stage.show();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user