diff --git a/Game.java b/Game.java index f778dd4..fe0908b 100644 --- a/Game.java +++ b/Game.java @@ -4,7 +4,7 @@ import javafx.scene.layout.Pane; import javafx.scene.paint.Color; import javafx.scene.control.Label; import javafx.scene.shape.Circle; -import java.util.AbstractList; + /** * * Beschreibung diff --git a/Game.~ava b/Game.~ava index a16df59..f778dd4 100644 --- a/Game.~ava +++ b/Game.~ava @@ -121,7 +121,7 @@ public class Game { public ArrayList getHorizontalCloseChips(int relX, int relY, int ring) { ArrayList result = new ArrayList(); - System.out.println("Target: " + relY); + System.out.println("Target: " + ring); if (relX == 0) { result.add(getChipByPos(1,relY)); result.add(getChipByPos(2,relY)); diff --git a/Muehle.class b/Muehle.class index 0891b00..8bd33b4 100644 Binary files a/Muehle.class and b/Muehle.class differ diff --git a/Muehle.java b/Muehle.java index d8485a0..fb7467e 100644 --- a/Muehle.java +++ b/Muehle.java @@ -13,6 +13,12 @@ import javafx.event.Event; import javafx.event.EventHandler; import javafx.scene.input.MouseEvent; import javafx.scene.shape.Circle; +import javafx.geometry.Pos; +import javafx.scene.layout.VBox; +import javafx.scene.layout.HBox; +import javafx.scene.text.Font; +import javafx.scene.text.FontWeight; +import javafx.scene.layout.BackgroundFill; /** * * Beschreibung @@ -31,11 +37,19 @@ public class Muehle extends Application { public void start(Stage primaryStage) { - Pane root = new Pane(); + VBox root = new VBox(); game = new Game(); + // lTop.setMaxWidth(1080); + HBox label_box = new HBox(lTop); + label_box.setAlignment(Pos.CENTER); + lTop.setFont(Font.font("Roboto",FontWeight.BOLD,40)); + + game_board = draw_game_board(); - root.getChildren().addAll(lTop,game_board); + root.getChildren().addAll(label_box,game_board); + + root.setStyle("-fx-background-color: rgb(255, 190, 0)"); Scene scene = new Scene(root, 1080, 820); diff --git a/Muehle.~ava b/Muehle.~ava index 235302b..fb7467e 100644 --- a/Muehle.~ava +++ b/Muehle.~ava @@ -13,6 +13,12 @@ import javafx.event.Event; import javafx.event.EventHandler; import javafx.scene.input.MouseEvent; import javafx.scene.shape.Circle; +import javafx.geometry.Pos; +import javafx.scene.layout.VBox; +import javafx.scene.layout.HBox; +import javafx.scene.text.Font; +import javafx.scene.text.FontWeight; +import javafx.scene.layout.BackgroundFill; /** * * Beschreibung @@ -31,11 +37,19 @@ public class Muehle extends Application { public void start(Stage primaryStage) { - Pane root = new Pane(); + VBox root = new VBox(); game = new Game(); + // lTop.setMaxWidth(1080); + HBox label_box = new HBox(lTop); + label_box.setAlignment(Pos.CENTER); + lTop.setFont(Font.font("Roboto",FontWeight.BOLD,40)); + + game_board = draw_game_board(); - root.getChildren().addAll(lTop,game_board); + root.getChildren().addAll(label_box,game_board); + + root.setStyle("-fx-background-color: rgb(255, 190, 0)"); Scene scene = new Scene(root, 1080, 820); @@ -159,7 +173,6 @@ public class Muehle extends Application { shapes.add(button.getShape()); } for (int i = 2; i >=0; i--) { - System.out.println("Er" +( i*100 + 360)); MuehleButton button = new MuehleButton(i,1,i,topRightX -230,topLeftY+ i*100 + 360,button_color,game); shapes.add(button.getShape()); }