diff --git a/src/main/java/com/alttd/hunger_games/config/Config.java b/src/main/java/com/alttd/hunger_games/config/Config.java index 5f6e104..5eceafc 100644 --- a/src/main/java/com/alttd/hunger_games/config/Config.java +++ b/src/main/java/com/alttd/hunger_games/config/Config.java @@ -44,6 +44,7 @@ public class Config extends AbstractConfig { public static Duration SAFE_PHASE = Duration.ofSeconds(30); public static Duration TIME_TO_FINALE = Duration.ofMinutes(5); public static int INITIAL_BORDER_SIZE = 5000; + public static int FINALE_BORDER_SIZE = 48; public static List STAGES = List.of( GameStage.builder().duration(Duration.ofMinutes(5)).worldBorderSize(1000).build(), GameStage.builder().duration(Duration.ofMinutes(5)).worldBorderSize(750).build(), @@ -59,6 +60,7 @@ public class Config extends AbstractConfig { int killPhaseSeconds = config.getInt(prefix, "time-to-finale-seconds", Math.toIntExact(TIME_TO_FINALE.toSeconds())); TIME_TO_FINALE = Duration.ofSeconds(killPhaseSeconds); INITIAL_BORDER_SIZE = config.getInt(prefix, "initial-border-size", INITIAL_BORDER_SIZE); + FINALE_BORDER_SIZE = config.getInt(prefix, "finale-border-size", FINALE_BORDER_SIZE); ConfigurationSection configurationSection = config.getConfigurationSection(prefix + "stages"); if (configurationSection == null) { diff --git a/src/main/java/com/alttd/hunger_games/services/RoundService.java b/src/main/java/com/alttd/hunger_games/services/RoundService.java index 3f6c3b3..9ff9afe 100644 --- a/src/main/java/com/alttd/hunger_games/services/RoundService.java +++ b/src/main/java/com/alttd/hunger_games/services/RoundService.java @@ -1,6 +1,7 @@ package com.alttd.hunger_games.services; import com.alttd.hunger_games.Main; +import com.alttd.hunger_games.config.Config; import com.alttd.hunger_games.config.Messages; import com.alttd.hunger_games.data_objects.DESTINATION; import com.alttd.hunger_games.data_objects.PLAYER_STATE; @@ -136,7 +137,7 @@ public class RoundService implements RoundListener { WorldBorderUtil.resetBorder(); } if (roundState.equals(ROUND_STATE.FINALE)) { - WorldBorderUtil.setSize(60); + WorldBorderUtil.setSize(Config.ROUND.FINALE_BORDER_SIZE); } if (!roundState.equals(ROUND_STATE.ENDED) && !roundState.equals(ROUND_STATE.PLAYER_REGISTRATION)) { Bukkit.broadcast(MiniMessage.miniMessage().deserialize(Messages.GAME.NEXT_STATE, Placeholder.parsed("round", roundState.getHumanReadableName())));