Merge branch 'development' of https://github.com/PTE-SH/ShadowHunterGame into development

This commit is contained in:
Paul Gross 2020-04-17 15:59:33 +02:00
commit 0497631eaf
4 changed files with 52 additions and 30 deletions

View File

@ -10,7 +10,6 @@ import javafx.fxml.Initializable;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.BorderPane;
import javafx.scene.layout.Pane;
import javafx.stage.Stage;
public class MenuController implements Initializable{
@FXML
@ -24,9 +23,8 @@ public class MenuController implements Initializable{
@FXML
public void commencerPartie(MouseEvent mouseEvent) throws IOException{
System.out.println("Bonjouuuuur!");
System.out.println("Passage à l'écran de choix des joueurs");
BorderPane pane = FXMLLoader.load(getClass().getResource("../ressources/Choix_joueur.fxml"));
System.out.println(rootPane);
rootPane.getChildren().setAll(pane);
}

View File

@ -0,0 +1,30 @@
package ihm.controller;
import java.io.IOException;
import java.net.URL;
import java.util.ResourceBundle;
import javafx.fxml.FXML;
import javafx.fxml.FXMLLoader;
import javafx.fxml.Initializable;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.BorderPane;
import javafx.scene.layout.Pane;
public class PlayersController implements Initializable{
@FXML
private BorderPane rootPane;
@Override
public void initialize(URL arg0, ResourceBundle arg1) {
// TODO Auto-generated method stub
}
@FXML
public void commencerJeux(MouseEvent mouseEvent) throws IOException{
System.out.println("Lancement du jeu...");
Pane pane = FXMLLoader.load(getClass().getResource("../ressources/Plateau.fxml"));
rootPane.getChildren().setAll(pane);
}
}

View File

@ -10,9 +10,9 @@
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>
<BorderPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/11.0.1" xmlns:fx="http://javafx.com/fxml/1">
<BorderPane fx:id="rootPane" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="400.0" prefWidth="600.0" styleClass="background" stylesheets="@style/menu.css" xmlns="http://javafx.com/javafx/11.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="ihm.controller.PlayersController">
<bottom>
<Button mnemonicParsing="false" text="Commencer la partie" BorderPane.alignment="CENTER">
<Button fx:id="btnCommencer" mnemonicParsing="false" onMouseClicked="#commencerJeux" styleClass="bouton" stylesheets="@style/menu.css" text="Commencer la partie" BorderPane.alignment="CENTER">
<BorderPane.margin>
<Insets bottom="10.0" />
</BorderPane.margin></Button>
@ -20,17 +20,17 @@
<top>
<VBox alignment="CENTER" prefHeight="119.0" prefWidth="600.0" BorderPane.alignment="CENTER">
<children>
<Label text="Entrez le nom des joueurs">
<Label styleClass="titre" stylesheets="@style/menu.css" text="Entrez le nom des joueurs">
<font>
<Font size="24.0" />
</font>
</Label>
<Label text="(Il faut au moins 4 joueurs)">
<Label styleClass="titre" stylesheets="@style/menu.css" text="(Il faut au moins 4 joueurs)">
<font>
<Font size="18.0" />
</font>
</Label>
<Label text="Cochez la checkbox pour que le joueur soit un joueur virtuel" />
<Label styleClass="titre" stylesheets="@style/menu.css" text="Cochez la checkbox pour que le joueur soit un joueur virtuel" />
</children>
</VBox>
</top>
@ -58,16 +58,16 @@
<children>
<VBox alignment="CENTER" prefHeight="257.0" prefWidth="78.0">
<children>
<Button mnemonicParsing="false" text="+" />
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+" />
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
@ -77,19 +77,19 @@
</VBox>
<VBox alignment="CENTER_LEFT" prefHeight="200.0" prefWidth="100.0">
<children>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<padding>
<Insets top="5.0" />
</padding></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<padding>
<Insets top="15.0" />
</padding></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<padding>
<Insets top="15.0" />
</padding></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<padding>
<Insets top="15.0" />
</padding></CheckBox>
@ -125,16 +125,16 @@
</VBox>
<VBox alignment="CENTER" prefHeight="200.0" prefWidth="100.0">
<children>
<Button mnemonicParsing="false" text="+" />
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+" />
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
<Button mnemonicParsing="false" text="+">
<Button mnemonicParsing="false" styleClass="bouton" stylesheets="@style/menu.css" text="+">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></Button>
@ -142,19 +142,19 @@
</VBox>
<VBox alignment="CENTER_LEFT" prefHeight="200.0" prefWidth="100.0">
<children>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<VBox.margin>
<Insets top="5.0" />
</VBox.margin></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<VBox.margin>
<Insets top="15.0" />
</VBox.margin></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<VBox.margin>
<Insets top="15.0" />
</VBox.margin></CheckBox>
<CheckBox mnemonicParsing="false">
<CheckBox mnemonicParsing="false" stylesheets="@style/menu.css">
<VBox.margin>
<Insets top="15.0" />
</VBox.margin></CheckBox>

View File

@ -180,17 +180,14 @@
<children>
<VBox alignment="CENTER" prefHeight="136.0" prefWidth="17.0">
<children>
<<<<<<< HEAD
<Circle fill="#ff1f1f" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#fccb0a" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#f1ff1f" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#1fff35" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
=======
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
>>>>>>> 88af99848491a78118cac6121fa65e6c2ffd3f56
</children>
</VBox>
<HBox alignment="CENTER" prefHeight="100.0" prefWidth="200.0">
@ -213,17 +210,14 @@
</HBox>
<VBox alignment="CENTER" prefHeight="136.0" prefWidth="19.0">
<children>
<<<<<<< HEAD
<Circle fill="#21e9ff" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#4421ff" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#ff21d8" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="#d521ff" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
=======
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
<Circle fill="DODGERBLUE" radius="8.0" stroke="BLACK" strokeType="INSIDE" />
>>>>>>> 88af99848491a78118cac6121fa65e6c2ffd3f56
</children>
</VBox>
</children>