@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="DiscordProjectSettings">
|
||||
<option name="show" value="PROJECT" />
|
||||
<option name="description" value="" />
|
||||
</component>
|
||||
</project>
|
@ -1,5 +1,4 @@
|
||||
|
||||
#player{
|
||||
-fx-text-fill: #ffffff;
|
||||
|
||||
}
|
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 295 B |
After Width: | Height: | Size: 675 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 862 B |
Before Width: | Height: | Size: 1.6 MiB After Width: | Height: | Size: 1.6 MiB |
Before Width: | Height: | Size: 9.3 KiB After Width: | Height: | Size: 9.3 KiB |
@ -1,21 +1,55 @@
|
||||
package launcher;
|
||||
|
||||
import model.Avatar;
|
||||
import model.Case;
|
||||
|
||||
public class Main {
|
||||
public static void Main (String[] args) {
|
||||
Case depart = new Case(1,10,10,true,false);
|
||||
Avatar avatar1 = new Avatar(1,"Perso1.1.png",0,0);
|
||||
int xdepart = depart.getCoordX();
|
||||
avatar1.setCoordX(xdepart);
|
||||
int ydepart = depart.getCoordY();
|
||||
avatar1.setCoordY(ydepart);
|
||||
int xavatar1 = avatar1.getCoordX();
|
||||
int yavatar1 = avatar1.getCoordY();
|
||||
System.out.println("xavatar1 = " + xavatar1);
|
||||
System.out.println("yavatar1 = " + yavatar1);
|
||||
System.out.println("xdepart = " + xdepart);
|
||||
System.out.println("ydepart = " + ydepart);
|
||||
import javafx.application.Application;
|
||||
import javafx.fxml.FXMLLoader;
|
||||
import javafx.scene.Parent;
|
||||
import javafx.scene.Scene;
|
||||
import javafx.stage.Stage;
|
||||
import model.Database;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.Objects;
|
||||
|
||||
public class Main extends Application {
|
||||
|
||||
private static Database currentd;
|
||||
|
||||
@Override
|
||||
public void start(Stage primaryStage) throws Exception{
|
||||
|
||||
Parent root = FXMLLoader.load(Objects.requireNonNull(getClass().getResource("/fxml/ConfigurationMenu.fxml")));
|
||||
primaryStage.setTitle("Hello World");
|
||||
primaryStage.setScene(new Scene(root, 900, 600));
|
||||
primaryStage.setResizable(false);
|
||||
primaryStage.show();
|
||||
}
|
||||
|
||||
|
||||
public static Database getDatabase(){
|
||||
return currentd;
|
||||
}
|
||||
public static void serialize() throws IOException {
|
||||
try (ObjectOutputStream out = new ObjectOutputStream(new FileOutputStream("database.txt"))) {
|
||||
out.writeObject(currentd);
|
||||
} finally {
|
||||
//System.out.println("Saved!");
|
||||
System.exit(0);
|
||||
}
|
||||
}
|
||||
public static void deserialize() throws ClassNotFoundException, IOException{
|
||||
ObjectInputStream in = null;
|
||||
try {
|
||||
in=new ObjectInputStream (new FileInputStream("database.txt"));
|
||||
currentd=(Database) in.readObject();
|
||||
in.close();
|
||||
}
|
||||
catch (FileNotFoundException | NullPointerException e){
|
||||
currentd=new Database();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static void main(String[] args) {
|
||||
launch(args);
|
||||
}
|
||||
}
|
||||
|
@ -1,14 +1,9 @@
|
||||
package sample;
|
||||
package model;
|
||||
|
||||
import javafx.scene.layout.Pane;
|
||||
import launcher.Main;
|
||||
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.ObjectOutputStream;
|
||||
import java.io.Serializable;
|
||||
import java.text.DateFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
|
||||
public class DataTable implements Serializable {
|
||||
private static int id=0;
|
@ -1,4 +1,4 @@
|
||||
package sample;
|
||||
package model;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.ArrayList;
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<?import com.jfoenix.controls.JFXButton?>
|
||||
<?import javafx.scene.control.*?>
|
||||
<?import javafx.scene.effect.Shadow?>
|
||||
<?import javafx.scene.image.Image?>
|
||||
<?import javafx.scene.image.ImageView?>
|
||||
<?import javafx.scene.layout.AnchorPane?>
|
||||
<?import javafx.scene.paint.*?>
|
||||
<?import javafx.scene.shape.Rectangle?>
|
||||
<?import javafx.scene.text.*?>
|
||||
<?import java.net.URL?>
|
||||
|
||||
<AnchorPane fx:id="levelRoot" xmlns:fx="http://javafx.com/fxml/1" id="pane" maxHeight="-Infinity" maxWidth="-Infinity"
|
||||
minHeight="-Infinity"
|
||||
minWidth="-Infinity" prefHeight="400.0" prefWidth="600.0"
|
||||
xmlns="http://javafx.com/javafx/11" fx:controller="controller.TopPlayerController">
|
||||
<ImageView fitHeight="600.0" fitWidth="1300" layoutX="133.0" layoutY="150.0" pickOnBounds="true" preserveRatio="true"
|
||||
AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
|
||||
AnchorPane.topAnchor="0.0">
|
||||
<Image url="/image/plaine.gif"/>
|
||||
</ImageView>
|
||||
<Rectangle arcHeight="5.0" arcWidth="5.0" height="600.0" layoutX="50" opacity="0.42" stroke="BLACK"
|
||||
strokeType="INSIDE" width="800.0"/>
|
||||
</AnchorPane>
|