diff --git a/FightSystem_Core/src/config.yml b/FightSystem_Core/src/config.yml index f87f00c..711d1d2 100644 --- a/FightSystem_Core/src/config.yml +++ b/FightSystem_Core/src/config.yml @@ -45,6 +45,8 @@ Arena: DisableSnowMelt: false # defaults to false if missing # Allow leaving the arena area as spectator Leaveable: false # defaults to false if missing + # Allow missiles to fly to the enemy and not stop at the schem border. + AllowMissiles: false # defaults to true if EnterStages are present otherwise 'false' Schematic: # The size of the schematics @@ -104,6 +106,7 @@ WinConditions: # defaults to none if missing # - WHITELIST_PERCENT # - RELATIVE_PERCENT # - POINTS + # - POINTS_AIRSHIP # - WATER_TECH_KO # - TIME_TECH_KO diff --git a/FightSystem_Core/src/de/steamwar/fightsystem/Config.java b/FightSystem_Core/src/de/steamwar/fightsystem/Config.java index 0bc6775..86026c6 100644 --- a/FightSystem_Core/src/de/steamwar/fightsystem/Config.java +++ b/FightSystem_Core/src/de/steamwar/fightsystem/Config.java @@ -75,6 +75,7 @@ public class Config { public static final boolean GroundWalkable; public static final boolean DisableSnowMelt; public static final boolean ArenaLeaveable; + public static final boolean AllowMissiles; //schematic parameter public static final boolean RanksEnabled; @@ -194,6 +195,7 @@ public class Config { PercentBlocks = Collections.unmodifiableSet(config.getStringList("WinConditionParams.Blocks").stream().map(Material::valueOf).collect(Collectors.toSet())); EnterStages = Collections.unmodifiableList(config.getIntegerList("EnterStages")); + AllowMissiles = config.getBoolean("Arena.AllowMissiles", !EnterStages.isEmpty()); KitFile = config.getString("Kits.File", "kits.yml"); MemberDefault = config.getString("Kits.MemberDefault", "default"); diff --git a/FightSystem_Core/src/de/steamwar/fightsystem/listener/PistonListener.java b/FightSystem_Core/src/de/steamwar/fightsystem/listener/PistonListener.java index 43848ba..7aba189 100644 --- a/FightSystem_Core/src/de/steamwar/fightsystem/listener/PistonListener.java +++ b/FightSystem_Core/src/de/steamwar/fightsystem/listener/PistonListener.java @@ -36,8 +36,8 @@ public class PistonListener implements Listener { public PistonListener() { //Wenn Entern aktiv ist, sollen Raketen etc. entern können if(!ArenaMode.Check.contains(Config.mode)) { - new StateDependentListener(Config.EnterStages.isEmpty(), FightState.All, this); - new StateDependentListener(!Config.EnterStages.isEmpty(), FightState.Setup, this); + new StateDependentListener(!Config.AllowMissiles, FightState.All, this); + new StateDependentListener(Config.AllowMissiles, FightState.Setup, this); } }