Before you begin, ensure you have met the following requirements:
- You have installed the latest version of Java Development Kit (JDK 17) and Java Runtime Environment (JRE 17).
- You have a Windows/Linux/Mac machine. This guide is OS-agnostic.
- You have installed Maven.
- You have installed JavaFX.
To install JDK 17 and JRE 17, follow these steps:
- Visit the official Oracle download page.
- Download the appropriate JDK 17 and JRE 17 according to your operating system.
- Run the installer and follow the instructions.
To install Maven, follow these steps:
- Visit the official Apache Maven download page.
- Download the binary zip archive.
- Extract the archive to your desired location.
- Add the
bin
directory of the created directoryapache-maven-3.x.y
to thePATH
environment variable.
To install JavaFX, follow these steps:
- Visit the official OpenJFX download page.
- Download the appropriate JavaFX SDK according to your operating system.
- Extract the archive to your desired location.
- Set the
PATH_TO_FX
environment variable to thelib
directory of the extracted archive.
To run a JavaFX program, navigate to your project directory and run the following command:
mvn javafx:run
To run the Server for our Roborally Project, run the following command (cmd):
mvn exec:java -Dexec.mainClass="dk.dtu.compute.se.pisd.roborallyserver.Server"
To compile the game and server together, run the following command (powershell):
mvn clean package -Pgame; mvn package -Pserver