Move arena runtime configuration into GameCore

- Replace FightSystem runtime properties with shared GameConfig
- Update dependent modules, commands, states, and tests
This commit is contained in:
2026-07-24 12:51:03 +02:00
parent f8cda32119
commit 12e085600e
45 changed files with 216 additions and 265 deletions
@@ -20,7 +20,7 @@
package de.steamwar.misslewars;
import de.steamwar.gamecore.ArenaMode;
import de.steamwar.gamecore.config.GameRuntimeProperties;
import de.steamwar.gamecore.GameConfig;
import de.steamwar.sql.Event;
import de.steamwar.sql.EventFight;
import de.steamwar.sql.Team;
@@ -38,8 +38,7 @@ public class Config {
private Config() {
}
public static final GameRuntimeProperties RuntimeProperties = GameRuntimeProperties.load();
public static final ArenaMode mode = ArenaMode.from(RuntimeProperties);
public static final ArenaMode mode = GameConfig.mode;
public static final int ArenaMinX;
public static final int ArenaMaxX;
@@ -113,13 +112,13 @@ public class Config {
BluePortalZ = blue.getInt("PortalZ");
BlueSpawn = new Location(Bukkit.getWorlds().get(0), blue.getDouble("SpawnX"), blue.getDouble("SpawnY"), blue.getDouble("SpawnZ"), (float) blue.getDouble("SpawnYaw"), (float) blue.getDouble("SpawnPitch"));
BlueLeader = RuntimeProperties.getBlueLeader();
RedLeader = RuntimeProperties.getRedLeader();
BlueLeader = GameConfig.BlueLeader;
RedLeader = GameConfig.RedLeader;
Barrier = config.getBoolean("Barrier", false);
Space = config.getBoolean("Space", false);
EventKampfID = RuntimeProperties.getFightId();
EventKampfID = GameConfig.EventKampfID;
if (EventKampfID >= 1) {
EventKampf = EventFight.byId(EventKampfID);
if (EventKampf == null) {