13.10
This commit is contained in:
@@ -4,7 +4,7 @@ import javafx.scene.layout.Pane;
|
|||||||
import javafx.scene.paint.Color;
|
import javafx.scene.paint.Color;
|
||||||
import javafx.scene.control.Label;
|
import javafx.scene.control.Label;
|
||||||
import javafx.scene.shape.Circle;
|
import javafx.scene.shape.Circle;
|
||||||
import java.util.AbstractList;
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* Beschreibung
|
* Beschreibung
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ public class Game {
|
|||||||
|
|
||||||
public ArrayList<Chip> getHorizontalCloseChips(int relX, int relY, int ring) {
|
public ArrayList<Chip> getHorizontalCloseChips(int relX, int relY, int ring) {
|
||||||
ArrayList<Chip> result = new ArrayList<Chip>();
|
ArrayList<Chip> result = new ArrayList<Chip>();
|
||||||
System.out.println("Target: " + relY);
|
System.out.println("Target: " + ring);
|
||||||
if (relX == 0) {
|
if (relX == 0) {
|
||||||
result.add(getChipByPos(1,relY));
|
result.add(getChipByPos(1,relY));
|
||||||
result.add(getChipByPos(2,relY));
|
result.add(getChipByPos(2,relY));
|
||||||
|
|||||||
BIN
Muehle.class
BIN
Muehle.class
Binary file not shown.
18
Muehle.java
18
Muehle.java
@@ -13,6 +13,12 @@ import javafx.event.Event;
|
|||||||
import javafx.event.EventHandler;
|
import javafx.event.EventHandler;
|
||||||
import javafx.scene.input.MouseEvent;
|
import javafx.scene.input.MouseEvent;
|
||||||
import javafx.scene.shape.Circle;
|
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
|
* Beschreibung
|
||||||
@@ -31,11 +37,19 @@ public class Muehle extends Application {
|
|||||||
public void start(Stage primaryStage) {
|
public void start(Stage primaryStage) {
|
||||||
|
|
||||||
|
|
||||||
Pane root = new Pane();
|
VBox root = new VBox();
|
||||||
game = new Game();
|
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();
|
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);
|
Scene scene = new Scene(root, 1080, 820);
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
19
Muehle.~ava
19
Muehle.~ava
@@ -13,6 +13,12 @@ import javafx.event.Event;
|
|||||||
import javafx.event.EventHandler;
|
import javafx.event.EventHandler;
|
||||||
import javafx.scene.input.MouseEvent;
|
import javafx.scene.input.MouseEvent;
|
||||||
import javafx.scene.shape.Circle;
|
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
|
* Beschreibung
|
||||||
@@ -31,11 +37,19 @@ public class Muehle extends Application {
|
|||||||
public void start(Stage primaryStage) {
|
public void start(Stage primaryStage) {
|
||||||
|
|
||||||
|
|
||||||
Pane root = new Pane();
|
VBox root = new VBox();
|
||||||
game = new Game();
|
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();
|
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);
|
Scene scene = new Scene(root, 1080, 820);
|
||||||
|
|
||||||
|
|
||||||
@@ -159,7 +173,6 @@ public class Muehle extends Application {
|
|||||||
shapes.add(button.getShape());
|
shapes.add(button.getShape());
|
||||||
}
|
}
|
||||||
for (int i = 2; i >=0; i--) {
|
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);
|
MuehleButton button = new MuehleButton(i,1,i,topRightX -230,topLeftY+ i*100 + 360,button_color,game);
|
||||||
shapes.add(button.getShape());
|
shapes.add(button.getShape());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user