diff --git a/.gitignore b/.gitignore index b4a5277..5b93a22 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,7 @@ .idea/ -target/ *.iml + +target/ +client/target/ +core/target/ +server/target/ diff --git a/client/pom.xml b/client/pom.xml new file mode 100644 index 0000000..533748a --- /dev/null +++ b/client/pom.xml @@ -0,0 +1,27 @@ + + + + starship-arena + nl.andrewl + 1.0.0-SNAPSHOT + + 4.0.0 + + nl.andrewl.starship-arena + client + + + 17 + 17 + + + + + nl.andrewl.starship-arena + core + ${project.parent.version} + + + \ No newline at end of file diff --git a/src/main/java/nl/andrewl/starship_arena/StarshipArena.java b/client/src/main/java/nl/andrewl/starship_arena/client/StarshipArenaClient.java similarity index 69% rename from src/main/java/nl/andrewl/starship_arena/StarshipArena.java rename to client/src/main/java/nl/andrewl/starship_arena/client/StarshipArenaClient.java index 2aead94..3ede506 100644 --- a/src/main/java/nl/andrewl/starship_arena/StarshipArena.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/StarshipArenaClient.java @@ -1,13 +1,13 @@ -package nl.andrewl.starship_arena; +package nl.andrewl.starship_arena.client; -import nl.andrewl.starship_arena.model.Arena; -import nl.andrewl.starship_arena.model.Ship; -import nl.andrewl.starship_arena.view.ArenaWindow; +import nl.andrewl.starship_arena.client.model.Arena; +import nl.andrewl.starship_arena.client.model.Ship; +import nl.andrewl.starship_arena.client.view.ArenaWindow; /** * The main executable class which starts the program. */ -public class StarshipArena { +public class StarshipArenaClient { public static void main(String[] args) { Ship s1 = new Ship("/ships/corvette.json"); s1.setVelocity(0, -0.5f); diff --git a/src/main/java/nl/andrewl/starship_arena/control/CameraController.java b/client/src/main/java/nl/andrewl/starship_arena/client/control/CameraController.java similarity index 87% rename from src/main/java/nl/andrewl/starship_arena/control/CameraController.java rename to client/src/main/java/nl/andrewl/starship_arena/client/control/CameraController.java index 0e43d7f..8081213 100644 --- a/src/main/java/nl/andrewl/starship_arena/control/CameraController.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/control/CameraController.java @@ -1,7 +1,7 @@ -package nl.andrewl.starship_arena.control; +package nl.andrewl.starship_arena.client.control; -import nl.andrewl.starship_arena.model.Camera; -import nl.andrewl.starship_arena.model.PhysicsObject; +import nl.andrewl.starship_arena.client.model.Camera; +import nl.andrewl.starship_arena.client.model.PhysicsObject; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; diff --git a/src/main/java/nl/andrewl/starship_arena/control/GameUpdater.java b/client/src/main/java/nl/andrewl/starship_arena/client/control/GameUpdater.java similarity index 92% rename from src/main/java/nl/andrewl/starship_arena/control/GameUpdater.java rename to client/src/main/java/nl/andrewl/starship_arena/client/control/GameUpdater.java index 2097762..6e2503b 100644 --- a/src/main/java/nl/andrewl/starship_arena/control/GameUpdater.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/control/GameUpdater.java @@ -1,7 +1,7 @@ -package nl.andrewl.starship_arena.control; +package nl.andrewl.starship_arena.client.control; -import nl.andrewl.starship_arena.model.Arena; -import nl.andrewl.starship_arena.view.ArenaPanel; +import nl.andrewl.starship_arena.client.model.Arena; +import nl.andrewl.starship_arena.client.view.ArenaPanel; import javax.swing.*; diff --git a/src/main/java/nl/andrewl/starship_arena/model/Arena.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/Arena.java similarity index 89% rename from src/main/java/nl/andrewl/starship_arena/model/Arena.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/Arena.java index 2dd240e..c41c6c2 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/Arena.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/Arena.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model; +package nl.andrewl.starship_arena.client.model; import java.util.ArrayList; import java.util.Collection; diff --git a/src/main/java/nl/andrewl/starship_arena/model/Camera.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/Camera.java similarity index 95% rename from src/main/java/nl/andrewl/starship_arena/model/Camera.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/Camera.java index 37274b0..82ceaec 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/Camera.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/Camera.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model; +package nl.andrewl.starship_arena.client.model; import java.awt.geom.Point2D; diff --git a/src/main/java/nl/andrewl/starship_arena/model/PhysicsObject.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/PhysicsObject.java similarity index 96% rename from src/main/java/nl/andrewl/starship_arena/model/PhysicsObject.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/PhysicsObject.java index 45bca0b..d17d4c8 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/PhysicsObject.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/PhysicsObject.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model; +package nl.andrewl.starship_arena.client.model; import java.awt.geom.Point2D; diff --git a/src/main/java/nl/andrewl/starship_arena/model/Ship.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/Ship.java similarity index 79% rename from src/main/java/nl/andrewl/starship_arena/model/Ship.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/Ship.java index 128a6c5..d690848 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/Ship.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/Ship.java @@ -1,10 +1,10 @@ -package nl.andrewl.starship_arena.model; +package nl.andrewl.starship_arena.client.model; -import nl.andrewl.starship_arena.model.ship.Cockpit; -import nl.andrewl.starship_arena.model.ship.Gun; -import nl.andrewl.starship_arena.model.ship.Panel; -import nl.andrewl.starship_arena.model.ship.ShipComponent; -import nl.andrewl.starship_arena.util.ResourceUtils; +import nl.andrewl.starship_arena.client.model.ship.Cockpit; +import nl.andrewl.starship_arena.client.model.ship.Gun; +import nl.andrewl.starship_arena.client.model.ship.Panel; +import nl.andrewl.starship_arena.client.model.ship.ShipComponent; +import nl.andrewl.starship_arena.core.util.ResourceUtils; import java.awt.*; import java.util.ArrayList; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ShipModel.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ShipModel.java similarity index 94% rename from src/main/java/nl/andrewl/starship_arena/model/ShipModel.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ShipModel.java index 36cccd5..7cbb46f 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ShipModel.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ShipModel.java @@ -1,8 +1,8 @@ -package nl.andrewl.starship_arena.model; +package nl.andrewl.starship_arena.client.model; import com.google.gson.Gson; import com.google.gson.GsonBuilder; -import nl.andrewl.starship_arena.model.ship.*; +import nl.andrewl.starship_arena.client.model.ship.*; import java.util.Collection; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/Cockpit.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Cockpit.java similarity index 68% rename from src/main/java/nl/andrewl/starship_arena/model/ship/Cockpit.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Cockpit.java index 716d20e..02631d0 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/Cockpit.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Cockpit.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; /** * A cockpit represents the control point of the ship. diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/ComponentDeserializer.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ComponentDeserializer.java similarity index 93% rename from src/main/java/nl/andrewl/starship_arena/model/ship/ComponentDeserializer.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ComponentDeserializer.java index 8b30dd6..8335d76 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/ComponentDeserializer.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ComponentDeserializer.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; import com.google.gson.*; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/GeometricComponent.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GeometricComponent.java similarity index 85% rename from src/main/java/nl/andrewl/starship_arena/model/ship/GeometricComponent.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GeometricComponent.java index 20eefc7..ae37d1e 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/GeometricComponent.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GeometricComponent.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; import java.awt.geom.Point2D; import java.util.List; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/Gun.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Gun.java similarity index 95% rename from src/main/java/nl/andrewl/starship_arena/model/ship/Gun.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Gun.java index a079b6b..198b75a 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/Gun.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Gun.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; import java.awt.geom.Point2D; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/GunDeserializer.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GunDeserializer.java similarity index 93% rename from src/main/java/nl/andrewl/starship_arena/model/ship/GunDeserializer.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GunDeserializer.java index d292d17..51d9f17 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/GunDeserializer.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/GunDeserializer.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; import com.google.gson.*; diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/Panel.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Panel.java similarity index 74% rename from src/main/java/nl/andrewl/starship_arena/model/ship/Panel.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Panel.java index d360e00..bccfe4c 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/Panel.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/Panel.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; /** * A simple structural panel that makes up all or part of a ship's body. diff --git a/src/main/java/nl/andrewl/starship_arena/model/ship/ShipComponent.java b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ShipComponent.java similarity index 77% rename from src/main/java/nl/andrewl/starship_arena/model/ship/ShipComponent.java rename to client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ShipComponent.java index 852161f..14c6f90 100644 --- a/src/main/java/nl/andrewl/starship_arena/model/ship/ShipComponent.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/model/ship/ShipComponent.java @@ -1,6 +1,6 @@ -package nl.andrewl.starship_arena.model.ship; +package nl.andrewl.starship_arena.client.model.ship; -import nl.andrewl.starship_arena.model.Ship; +import nl.andrewl.starship_arena.client.model.Ship; /** * Represents the top-level component information for any part of a ship. diff --git a/src/main/java/nl/andrewl/starship_arena/view/ArenaPanel.java b/client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaPanel.java similarity index 87% rename from src/main/java/nl/andrewl/starship_arena/view/ArenaPanel.java rename to client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaPanel.java index f1d5e0b..2c42dd8 100644 --- a/src/main/java/nl/andrewl/starship_arena/view/ArenaPanel.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaPanel.java @@ -1,9 +1,8 @@ -package nl.andrewl.starship_arena.view; +package nl.andrewl.starship_arena.client.view; -import nl.andrewl.starship_arena.control.CameraController; -import nl.andrewl.starship_arena.model.Arena; -import nl.andrewl.starship_arena.model.Camera; -import nl.andrewl.starship_arena.model.PhysicsObject; +import nl.andrewl.starship_arena.client.model.Arena; +import nl.andrewl.starship_arena.client.model.Camera; +import nl.andrewl.starship_arena.client.model.PhysicsObject; import javax.swing.*; import java.awt.*; diff --git a/src/main/java/nl/andrewl/starship_arena/view/ArenaWindow.java b/client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaWindow.java similarity index 80% rename from src/main/java/nl/andrewl/starship_arena/view/ArenaWindow.java rename to client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaWindow.java index 138f3b9..dd96304 100644 --- a/src/main/java/nl/andrewl/starship_arena/view/ArenaWindow.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/view/ArenaWindow.java @@ -1,9 +1,9 @@ -package nl.andrewl.starship_arena.view; +package nl.andrewl.starship_arena.client.view; -import nl.andrewl.starship_arena.control.CameraController; -import nl.andrewl.starship_arena.control.GameUpdater; -import nl.andrewl.starship_arena.model.Arena; -import nl.andrewl.starship_arena.util.ResourceUtils; +import nl.andrewl.starship_arena.client.control.CameraController; +import nl.andrewl.starship_arena.client.control.GameUpdater; +import nl.andrewl.starship_arena.client.model.Arena; +import nl.andrewl.starship_arena.core.util.ResourceUtils; import javax.imageio.ImageIO; import javax.swing.*; diff --git a/src/main/java/nl/andrewl/starship_arena/view/Renderer.java b/client/src/main/java/nl/andrewl/starship_arena/client/view/Renderer.java similarity index 65% rename from src/main/java/nl/andrewl/starship_arena/view/Renderer.java rename to client/src/main/java/nl/andrewl/starship_arena/client/view/Renderer.java index 1f30f88..74fcfa0 100644 --- a/src/main/java/nl/andrewl/starship_arena/view/Renderer.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/view/Renderer.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.view; +package nl.andrewl.starship_arena.client.view; import java.awt.*; diff --git a/src/main/java/nl/andrewl/starship_arena/view/ShipRenderer.java b/client/src/main/java/nl/andrewl/starship_arena/client/view/ShipRenderer.java similarity index 84% rename from src/main/java/nl/andrewl/starship_arena/view/ShipRenderer.java rename to client/src/main/java/nl/andrewl/starship_arena/client/view/ShipRenderer.java index 53fb5a3..b389af3 100644 --- a/src/main/java/nl/andrewl/starship_arena/view/ShipRenderer.java +++ b/client/src/main/java/nl/andrewl/starship_arena/client/view/ShipRenderer.java @@ -1,9 +1,9 @@ -package nl.andrewl.starship_arena.view; +package nl.andrewl.starship_arena.client.view; -import nl.andrewl.starship_arena.model.Ship; -import nl.andrewl.starship_arena.model.ship.Cockpit; -import nl.andrewl.starship_arena.model.ship.GeometricComponent; -import nl.andrewl.starship_arena.model.ship.Gun; +import nl.andrewl.starship_arena.client.model.Ship; +import nl.andrewl.starship_arena.client.model.ship.Cockpit; +import nl.andrewl.starship_arena.client.model.ship.GeometricComponent; +import nl.andrewl.starship_arena.client.model.ship.Gun; import java.awt.*; import java.awt.geom.AffineTransform; diff --git a/core/pom.xml b/core/pom.xml new file mode 100644 index 0000000..23864e0 --- /dev/null +++ b/core/pom.xml @@ -0,0 +1,20 @@ + + + + starship-arena + nl.andrewl + 1.0.0-SNAPSHOT + + 4.0.0 + + nl.andrewl.starship-arena + core + + + 17 + 17 + + + \ No newline at end of file diff --git a/core/src/main/java/nl/andrewl/starship_arena/core/physics/Vec2F.java b/core/src/main/java/nl/andrewl/starship_arena/core/physics/Vec2F.java new file mode 100644 index 0000000..d9ce52b --- /dev/null +++ b/core/src/main/java/nl/andrewl/starship_arena/core/physics/Vec2F.java @@ -0,0 +1,83 @@ +package nl.andrewl.starship_arena.core.physics; + +/** + * Standard 2-dimensional floating-point vector implementation. + */ +public final class Vec2F { + public float x; + public float y; + + public Vec2F(float x, float y) { + this.x = x; + this.y = y; + } + + public Vec2F(float n) { + this(n, n); + } + + public Vec2F() { + this(0); + } + + public Vec2F(Vec2F other) { + this(other.x, other.y); + } + + public float length() { + return (float) Math.sqrt(x * x + y * y); + } + + public float dot(Vec2F other) { + return x * other.x + y * other.y; + } + + public Vec2F add(Vec2F other) { + x += other.x; + y += other.y; + return this; + } + + public Vec2F sub(Vec2F other) { + x -= other.x; + y -= other.y; + return this; + } + + public Vec2F mul(float factor) { + x *= factor; + y *= factor; + return this; + } + + public Vec2F div(float factor) { + x /= factor; + y /= factor; + return this; + } + + public Vec2F normalize() { + return div(length()); + } + + public Vec2F toPolar() { + float r = length(); + float theta = (float) Math.atan2(y, x); + x = r; + y = theta; + return this; + } + + public Vec2F toCartesian() { + float cx = (float) (x * Math.cos(y)); + float cy = (float) (x * Math.sin(y)); + x = cx; + y = cy; + return this; + } + + @Override + public String toString() { + return "[ " + x + ", " + y + " ]"; + } +} diff --git a/src/main/java/nl/andrewl/starship_arena/util/ResourceUtils.java b/core/src/main/java/nl/andrewl/starship_arena/core/util/ResourceUtils.java similarity index 92% rename from src/main/java/nl/andrewl/starship_arena/util/ResourceUtils.java rename to core/src/main/java/nl/andrewl/starship_arena/core/util/ResourceUtils.java index 6d30fb0..721d978 100644 --- a/src/main/java/nl/andrewl/starship_arena/util/ResourceUtils.java +++ b/core/src/main/java/nl/andrewl/starship_arena/core/util/ResourceUtils.java @@ -1,4 +1,4 @@ -package nl.andrewl.starship_arena.util; +package nl.andrewl.starship_arena.core.util; import java.io.IOException; import java.io.InputStream; diff --git a/design/repo_background.jpg b/design/repo_background.jpg new file mode 100644 index 0000000..c3f7cff Binary files /dev/null and b/design/repo_background.jpg differ diff --git a/pom.xml b/pom.xml index 1af812c..e6af771 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,13 @@ nl.andrewl starship-arena + pom 1.0.0-SNAPSHOT + + server + core + client + 17 @@ -30,7 +36,7 @@ - nl.andrewl.starship_arena.StarshipArena + nl.andrewl.StarshipArena diff --git a/server/README.md b/server/README.md new file mode 100644 index 0000000..bc5e31b --- /dev/null +++ b/server/README.md @@ -0,0 +1,24 @@ +# Starship Arena Server + +The server is a program that runs the physics of the arena, and that clients can connect to. Each server specifically has the capability to host one or more arenas simultaneously. Clients may query the server for metadata, like which arenas are available, and their current statuses. + +## Arena Lifecycle + +Within the context of each arena, clients may connect during the so-called "staging" phase before the battle commences. Once all clients are assembled and the arena's settings are established, the arena transitions to the "battle" phase, where players (or AI) will control their spacecraft to achieve the configured objective. Once battle is deemed to be over, the arena transitions to the "analysis" stage, where the server provides detailed analytics and statistics about the battle to players. Spectators may join at any point, as long as the arena is open. + +### Staging +This is the first stage that all arenas start in. It offers the following functionality: +- Players can connect +- Spectators can connect +- Configure arena settings for battle + +### Battle +The main stage for the arena, in which the all "players" (AI or human players) control their respective spacecraft to achieve an objective. It offers the following functionality: +- Battle physics simulation and real-time UDP data updates sent to all connected clients +- Spectators can connect +- Registered players can re-connect if their connection dies for some reason + +### Analysis +After the battle has ended (due to time constraints, objective achieved, etc.), the arena enters the final analysis stage for a set period of time before closing. During the analysis stage, the arena will provide statistics and analysis for each player. It offers the following functionality: +- Player statistics and analysis sent to all players +- All clients can disconnect diff --git a/server/pom.xml b/server/pom.xml new file mode 100644 index 0000000..047266c --- /dev/null +++ b/server/pom.xml @@ -0,0 +1,27 @@ + + + + starship-arena + nl.andrewl + 1.0.0-SNAPSHOT + + 4.0.0 + + nl.andrewl.starship-arena + server + + + 17 + 17 + + + + + nl.andrewl.starship-arena + core + ${project.parent.version} + + + \ No newline at end of file diff --git a/server/src/main/java/nl/andrewl/starship_arena/server/StarshipArenaServer.java b/server/src/main/java/nl/andrewl/starship_arena/server/StarshipArenaServer.java new file mode 100644 index 0000000..aa4adc6 --- /dev/null +++ b/server/src/main/java/nl/andrewl/starship_arena/server/StarshipArenaServer.java @@ -0,0 +1,7 @@ +package nl.andrewl.starship_arena.server; + +public class StarshipArenaServer { + public static void main(String[] args) { + + } +} diff --git a/server/src/main/java/nl/andrewl/starship_arena/server/model/Arena.java b/server/src/main/java/nl/andrewl/starship_arena/server/model/Arena.java new file mode 100644 index 0000000..4a53efc --- /dev/null +++ b/server/src/main/java/nl/andrewl/starship_arena/server/model/Arena.java @@ -0,0 +1,4 @@ +package nl.andrewl.starship_arena.server.model; + +public class Arena { +} diff --git a/src/main/resources/img/icon.png b/src/main/resources/img/icon.png deleted file mode 100644 index b21f0b7..0000000 Binary files a/src/main/resources/img/icon.png and /dev/null differ diff --git a/src/main/resources/ships/corvette.json b/src/main/resources/ships/corvette.json deleted file mode 100644 index bc181c8..0000000 --- a/src/main/resources/ships/corvette.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "name": "Corvette", - "components": [ - { - "type": "panel", - "name": "Main Fuselage", - "mass": 5000, - "points": [ - {"x": 0.3, "y": 0.6}, - {"x": 0.2, "y": 0.1}, - {"x": 0.1, "y": 0.5}, - {"x": 0.2, "y": 0.8}, - {"x": 0.8, "y": 0.8}, - {"x": 0.9, "y": 0.5}, - {"x": 0.8, "y": 0.1}, - {"x": 0.7, "y": 0.6} - ] - }, - { - "type": "panel", - "name": "Front Cargo Bay", - "mass": 1000, - "points": [ - {"x": 0.4, "y": 0.2}, - {"x": 0.35, "y": 0.6}, - {"x": 0.65, "y": 0.6}, - {"x": 0.6, "y": 0.2} - ] - }, - { - "type": "cockpit", - "mass": 800, - "points": [ - {"x": 0.5, "y": 0.0}, - {"x": 0.4, "y": 0.2}, - {"x": 0.6, "y": 0.2} - ] - }, - { - "type": "gun", - "name": "Port-Side Machine Gun", - "mass": 500, - "location": {"x": 0.15, "y": 0.35}, - "rotation": 0, - "minRotation": -160, - "maxRotation": 5, - "barrelWidth": 0.02, - "barrelLength": 0.2 - }, - { - "type": "gun", - "name": "Starboard-Side Machine Gun", - "mass": 500, - "location": {"x": 0.85, "y": 0.35}, - "rotation": 0, - "minRotation": -5, - "maxRotation": 160, - "barrelWidth": 0.02, - "barrelLength": 0.2 - } - ] -} \ No newline at end of file