From 5f7a4cb32b96ced7896577b04f9b58ee32d69ad2 Mon Sep 17 00:00:00 2001 From: "version-bump[github-action]" <41898282+version-bump[github-action]@users.noreply.github.com> Date: Sat, 7 Feb 2026 15:09:44 +0000 Subject: [PATCH 1/8] Bump version from 2.1.7 to 2.1.7-SNAPSHOT0 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 9e66936..2472b43 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ plugily.projects thebridge - 2.1.7 + 2.1.7-SNAPSHOT0 TheBridge From ed4ec90505cbbaf04d58fda15ea8c30a9f94cecc Mon Sep 17 00:00:00 2001 From: Tigerpanzer_02 <37453987+Tigerpanzer02@users.noreply.github.com> Date: Wed, 13 May 2026 23:40:32 +0200 Subject: [PATCH 2/8] Fixed block recreation on bridge on legacy versions (colouring) --- .../java/plugily/projects/thebridge/arena/Arena.java | 9 ++++----- .../plugily/projects/thebridge/arena/ArenaEvents.java | 3 ++- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/java/plugily/projects/thebridge/arena/Arena.java b/src/main/java/plugily/projects/thebridge/arena/Arena.java index 5cfe8c9..d46336b 100644 --- a/src/main/java/plugily/projects/thebridge/arena/Arena.java +++ b/src/main/java/plugily/projects/thebridge/arena/Arena.java @@ -25,7 +25,6 @@ import org.bukkit.block.Block; import org.bukkit.entity.Player; import org.bukkit.potion.PotionEffect; -import org.bukkit.potion.PotionEffectType; import org.jetbrains.annotations.Nullable; import plugily.projects.minigamesbox.api.arena.IArenaState; import plugily.projects.minigamesbox.classic.arena.PluginArena; @@ -63,7 +62,7 @@ public class Arena extends PluginArena { private final ArrayList placedBlocks = new ArrayList<>(); private List bridgeCuboid; - private final HashMap brokenBlocks = new HashMap<>(); + private final HashMap brokenBlocks = new HashMap<>(); private final HashMap hits = new HashMap<>(); private int resetRound = 0; @@ -350,10 +349,10 @@ public void addBridgeCuboid(Cuboid cuboid) { this.bridgeCuboid.add(cuboid); } - public HashMap getBrokenBlocks() { + public HashMap getBrokenBlocks() { return brokenBlocks; } - public void addBrokenBlock(Location location, Material material) { + public void addBrokenBlock(Location location, XMaterial material) { this.brokenBlocks.put(location, material); } @@ -365,7 +364,7 @@ public void resetPlacedBlocks() { } public void resetBrokenBlocks() { - brokenBlocks.forEach((location, material) -> XBlock.setType(location.getBlock(), XMaterial.matchXMaterial(material))); + brokenBlocks.forEach((location, material) -> XBlock.setType(location.getBlock(), material)); brokenBlocks.clear(); } diff --git a/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java b/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java index 667f03c..30ea17e 100644 --- a/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java +++ b/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java @@ -44,6 +44,7 @@ import plugily.projects.minigamesbox.classic.utils.version.VersionUtils; import plugily.projects.minigamesbox.classic.utils.version.events.api.PlugilyEntityPickupItemEvent; import plugily.projects.minigamesbox.classic.utils.version.events.api.PlugilyPlayerPickupArrow; +import plugily.projects.minigamesbox.classic.utils.version.xseries.XBlock; import plugily.projects.minigamesbox.classic.utils.version.xseries.XMaterial; import plugily.projects.minigamesbox.classic.utils.version.xseries.XSound; import plugily.projects.thebridge.Main; @@ -114,7 +115,7 @@ public void onBlockBreakEvent(BlockBreakEvent event) { // Only add blocks to the list if the block is not found to be in the broken blocks list // Making it so that resetting placed blocks and resetting broken blocks will not tamper with each other if(!arena.getBrokenBlocks().containsKey(event.getBlock().getLocation())) { - arena.addBrokenBlock(event.getBlock().getLocation(), event.getBlock().getType()); + arena.addBrokenBlock(event.getBlock().getLocation(), XBlock.getType(event.getBlock())); } } else { new MessageBuilder("IN_GAME_MESSAGES_ARENA_BUILD_BREAK") From 0b420b42c6cd404d72f8cc2963470b0159d38372 Mon Sep 17 00:00:00 2001 From: Tigerpanzer_02 <37453987+Tigerpanzer02@users.noreply.github.com> Date: Wed, 13 May 2026 23:40:56 +0200 Subject: [PATCH 3/8] Fixed ICCE InventoryView --- .../java/plugily/projects/thebridge/arena/ArenaEvents.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java b/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java index 30ea17e..3add4f5 100644 --- a/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java +++ b/src/main/java/plugily/projects/thebridge/arena/ArenaEvents.java @@ -47,6 +47,7 @@ import plugily.projects.minigamesbox.classic.utils.version.xseries.XBlock; import plugily.projects.minigamesbox.classic.utils.version.xseries.XMaterial; import plugily.projects.minigamesbox.classic.utils.version.xseries.XSound; +import plugily.projects.minigamesbox.classic.utils.version.xseries.inventory.XInventoryView; import plugily.projects.thebridge.Main; import plugily.projects.thebridge.arena.base.Base; import plugily.projects.thebridge.arena.managers.ScoreboardManager; @@ -614,8 +615,8 @@ public void onItemMove(InventoryClickEvent event) { if(plugin.getArenaRegistry().getArena(((Player) event.getWhoClicked())).getArenaState() != IArenaState.IN_GAME) { if(event.getClickedInventory() == event.getWhoClicked().getInventory()) { - if(event.getView().getType() == InventoryType.CRAFTING - || event.getView().getType() == InventoryType.PLAYER) { + if(XInventoryView.of(event.getView()).getType() == InventoryType.CRAFTING + || XInventoryView.of(event.getView()).getType() == InventoryType.PLAYER) { event.setResult(Event.Result.DENY); } } From 6ebe6168ca85c3ad7ffbcf85a9dfe66cd0412fbd Mon Sep 17 00:00:00 2001 From: Tigerpanzer_02 <37453987+Tigerpanzer02@users.noreply.github.com> Date: Wed, 13 May 2026 23:41:37 +0200 Subject: [PATCH 4/8] Adjusted setting of how blocks are getting replaced in inventory to fix legacy coloured issues --- .../java/plugily/projects/thebridge/kits/KitUtils.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/java/plugily/projects/thebridge/kits/KitUtils.java b/src/main/java/plugily/projects/thebridge/kits/KitUtils.java index f65b583..d9e46ae 100644 --- a/src/main/java/plugily/projects/thebridge/kits/KitUtils.java +++ b/src/main/java/plugily/projects/thebridge/kits/KitUtils.java @@ -27,15 +27,17 @@ public static ItemStack handleItem(PluginMain plugin, Player player, ItemStack i plugin.getDebugger().performance("Kit", "Arena {0} Handle item method called for player {1} item stack {2}.", arena.getId(), player, itemStack); // Replaces white terracotta with coloured terracotta if the player is in a team - if(itemStack.getType().equals(XMaterial.matchXMaterial(plugin.getConfig().getString("Kit.Colored-Block-Replace-Material", "WHITE_WOOL")).orElse(XMaterial.WHITE_WOOL).parseMaterial())) { + if(XMaterial.matchXMaterial(plugin.getConfig().getString("Kit.Colored-Block-Replace-Material", "WHITE_WOOL")).orElse(XMaterial.WHITE_WOOL).isSimilar(itemStack)) { Optional material = XMaterial.matchXMaterial(arena.getBase(player).getMaterialColor().toUpperCase() + "_" + plugin.getConfig().getString("Kit.Colored-Block-Material", "WOOL")); - material.ifPresent(xMaterial -> itemStack.setType(Objects.requireNonNull(xMaterial.parseMaterial()))); + material.ifPresent(xMaterial -> { + xMaterial.setType(itemStack); + }); plugin.getDebugger().performance("Kit", "Arena {0} Changing coloured block to {1}.", arena.getId(), arena.getBase(player).getMaterialColor().toUpperCase() + "_" + plugin.getConfig().getString("Kit.Colored-Block-Material", "WOOL")); return itemStack; } // Replaces leather armour with the coloured leather armour if the player is in a team - if(itemStack.getType().equals(XMaterial.LEATHER_HELMET.parseMaterial()) || itemStack.getType().equals(XMaterial.LEATHER_CHESTPLATE.parseMaterial()) || itemStack.getType().equals(XMaterial.LEATHER_LEGGINGS.parseMaterial()) || itemStack.getType().equals(XMaterial.LEATHER_BOOTS.parseMaterial())) { + if(XMaterial.LEATHER_HELMET.isSimilar(itemStack) || XMaterial.LEATHER_CHESTPLATE.isSimilar(itemStack) || XMaterial.LEATHER_LEGGINGS.isSimilar(itemStack) || XMaterial.LEATHER_BOOTS.isSimilar(itemStack)) { LeatherArmorMeta itemMeta = (LeatherArmorMeta) itemStack.getItemMeta(); assert itemMeta != null; itemMeta.setColor(ColorUtil.fromChatColor(ChatColor.valueOf(arena.getBase(player).getColor().toUpperCase()))); From 78e24665b5dec5c0a9ff22e57205db52c036cf2f Mon Sep 17 00:00:00 2001 From: Tigerpanzer_02 <37453987+Tigerpanzer02@users.noreply.github.com> Date: Thu, 14 May 2026 00:04:15 +0200 Subject: [PATCH 5/8] Updated Minigamesbox & CHANGELOG.md --- .github/CHANGELOG.md | 6 +++ pom.xml | 2 +- .../handlers/setup/components/BasePage.java | 41 ++++++++++++------- 3 files changed, 33 insertions(+), 16 deletions(-) diff --git a/.github/CHANGELOG.md b/.github/CHANGELOG.md index 4d759bf..179c9aa 100644 --- a/.github/CHANGELOG.md +++ b/.github/CHANGELOG.md @@ -1,3 +1,9 @@ +### 2.1.8 Release (13.05.2026) +* Fixed block replacement (on bridge) and in inventory for legacy versions +* Fixed InventoryView Error +* Added a Base Validation check on Arena Border if already present +* Updated to MinigamesBox 1.4.6 + ### 2.1.7 Release (17.01.2026) * Updated to MinigamesBox 1.4.5 diff --git a/pom.xml b/pom.xml index 2472b43..de618b8 100644 --- a/pom.xml +++ b/pom.xml @@ -58,7 +58,7 @@ plugily.projects MiniGamesBox-Classic - 1.4.5 + 1.4.6 compile true diff --git a/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java b/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java index fc7bca8..845d548 100644 --- a/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java +++ b/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java @@ -69,7 +69,7 @@ public Prompt acceptInput(ConversationContext context, String input) { NormalFastInv pagedGui = new BasePage(9, setupInventory.getPlugin().getPluginMessagePrefix() + "Base Editor Menu", setupInventory); pagedGui.open(setupInventory.getPlayer()); return Prompt.END_OF_CONVERSATION; - } catch (IllegalArgumentException ignored) { + } catch(IllegalArgumentException ignored) { context.getForWhom().sendRawMessage(new MessageBuilder("&cTry again. This is not an color!").prefix().build()); return Prompt.END_OF_CONVERSATION; } @@ -77,7 +77,7 @@ public Prompt acceptInput(ConversationContext context, String input) { }).buildFor((Player) event.getWhoClicked()); })); - LocationSelectorItem baseCorners = new LocationSelectorItem(setupInventory, new ItemBuilder(XMaterial.BEDROCK.parseMaterial()), "Base", "Set the corners of one base", "bases." + getId(setupInventory.getPlayer()) + ".baselocation"); + LocationSelectorItem baseCorners = new LocationSelectorItem(setupInventory, new ItemBuilder(XMaterial.BEDROCK.parseMaterial()), "Base", "Set the corners of one base", "bases." + getId(setupInventory.getPlayer()) + ".baselocation"); setItem(1, baseCorners); //portal in mid function? LocationSerializer.saveLoc(setupInventory.getPlugin(), setupInventory.getConfig(), "arenas", "instances." + setupInventory.getArenaKey() + ".bases." + getId(setupInventory.getPlayer()) + ".portalhologram", new Cuboid(selection.getFirstPos(), selection.getSecondPos()).getCenter().add(0, 2, 0)); @@ -103,30 +103,41 @@ public Prompt acceptInput(ConversationContext context, String input) { .lore(ChatColor.GREEN + "Click to finish & save the setup of this base") .build(), event -> { String path = "instances." + setupInventory.getArenaKey() + ".bases." + getId(setupInventory.getPlayer()); - if (setupInventory.getConfig().get(path + ".baselocation.1") == null) { + if(setupInventory.getConfig().get(path + ".baselocation.1") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure base location properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if (setupInventory.getConfig().get(path + ".portallocation.1") == null) { + if(setupInventory.getConfig().get(path + ".portallocation.1") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure portal location properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if (setupInventory.getConfig().get(path + ".spawnpoint") == null) { + if(setupInventory.getConfig().get(path + ".spawnpoint") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure spawnpoint properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if (setupInventory.getConfig().get(path + ".respawnpoint") == null) { + if(setupInventory.getConfig().get(path + ".respawnpoint") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure respawnpoint properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if (setupInventory.getConfig().get(path + ".color") == null) { + if(setupInventory.getConfig().get(path + ".color") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure color properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if (setupInventory.getConfig().get(path + ".portalhologram") == null) { + if(setupInventory.getConfig().get(path + ".portalhologram") == null) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure portalhologram properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } + if(setupInventory.getConfig().get(path + ".portalhologram") == null) { + new MessageBuilder("&c&l✘ &cBase validation failed! Please configure portalhologram properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); + return; + } + if(setupInventory.getConfig().getString(path + ".arenalocation.1") != null && setupInventory.getConfig().getString(path + ".arenalocation.2") != null) { + Cuboid arenaBorder = new Cuboid(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".arenalocation.1", "world,364.0,63.0,-72.0,0.0,0.0")), LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".arenalocation.2", "world,364.0,63.0,-72.0,0.0,0.0"))); + if(!(arenaBorder.isIn(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".baselocation.1"))) && arenaBorder.isIn(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".baselocation.2"))))) { + new MessageBuilder("&c&l✘ &cBase validation failed! Please set your base cuboids (baselocation.1 and baselocation.2) inside your arena cuboid!").prefix().player(setupInventory.getPlayer()).sendPlayer(); + return; + } + } new MessageBuilder("&a&l✔ &aValidation succeeded! Registering new base: " + getId(setupInventory.getPlayer())).prefix().player(setupInventory.getPlayer()).sendPlayer(); setupInventory.setConfig("bases." + getId(setupInventory.getPlayer()) + ".isdone", true); Base base = new Base( @@ -139,13 +150,13 @@ public Prompt acceptInput(ConversationContext context, String input) { LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".portallocation.2")), setupInventory.getConfig().getInt(path + ".maximumsize") ); - if (setupInventory.getConfig().get(path + ".cagelocation.1") != null && setupInventory.getConfig().get(path + ".cagelocation.2") != null) { + if(setupInventory.getConfig().get(path + ".cagelocation.1") != null && setupInventory.getConfig().get(path + ".cagelocation.2") != null) { base.setCageCuboid(new Cuboid(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".cagelocation.1")), LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".cagelocation.2")))); } Arena arena = (Arena) setupInventory.getPlugin().getArenaRegistry().getArena(setupInventory.getArenaKey()); arena.addBase(base); ArmorStandHologram portal = new ArmorStandHologram(setupInventory.getPlugin().getBukkitHelper().getBlockCenter(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".portalhologram")))); - for (String str : setupInventory.getPlugin().getLanguageManager().getLanguageMessage(setupInventory.getPlugin().getMessageManager().getPath("IN_GAME_MESSAGES_ARENA_PORTAL_HOLOGRAM")).split(";")) { + for(String str : setupInventory.getPlugin().getLanguageManager().getLanguageMessage(setupInventory.getPlugin().getMessageManager().getPath("IN_GAME_MESSAGES_ARENA_PORTAL_HOLOGRAM")).split(";")) { portal.appendLine(str.replace("%arena_base_color_formatted%", base.getFormattedColor())); } base.setArmorStandHologram(portal); @@ -167,14 +178,14 @@ String getPromptText(ConversationContext context) { @Override public Prompt acceptInput(ConversationContext context, String input) { - if (!NumberUtils.isInteger(input)) { + if(!NumberUtils.isInteger(input)) { context.getForWhom().sendRawMessage(new MessageBuilder("&cTry again. Its not a number!").prefix().build()); return Prompt.END_OF_CONVERSATION; } int number = Integer.parseInt(input); - if (setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases") != null) { - if (number >= setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases").getKeys(false).size()) { + if(setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases") != null) { + if(number >= setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases").getKeys(false).size()) { context.getForWhom().sendRawMessage(new MessageBuilder("&cTry again. The number is higher than bases that you have!").prefix().build()); return Prompt.END_OF_CONVERSATION; } @@ -195,9 +206,9 @@ public Prompt acceptInput(ConversationContext context, String input) { public int getId(Player player) { - if (!BaseUtilities.check(player)) { + if(!BaseUtilities.check(player)) { int id = 0; - if (setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases") != null) { + if(setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases") != null) { id = setupInventory.getConfig().getConfigurationSection("instances." + setupInventory.getArenaKey() + ".bases").getKeys(false).size(); } BaseUtilities.getBaseId().put(player, id); From a48982aa21eafff5a5ee8348c2c01c332d66a3fe Mon Sep 17 00:00:00 2001 From: "version-bump[github-action]" <41898282+version-bump[github-action]@users.noreply.github.com> Date: Wed, 13 May 2026 22:03:45 +0000 Subject: [PATCH 6/8] Bump version from 2.1.7-SNAPSHOT0 to 2.1.7-SNAPSHOT1 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index de618b8..4b672fe 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ plugily.projects thebridge - 2.1.7-SNAPSHOT0 + 2.1.7-SNAPSHOT1 TheBridge From 159ac65c83b7aab7d07a34fd4854c6869baccec4 Mon Sep 17 00:00:00 2001 From: Tigerpanzer_02 <37453987+Tigerpanzer02@users.noreply.github.com> Date: Thu, 14 May 2026 10:44:57 +0200 Subject: [PATCH 7/8] Added more information for arena cuboid setup --- .../handlers/setup/LocationCategory.java | 17 ++++++++++++++++- .../handlers/setup/components/BasePage.java | 6 +++--- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/main/java/plugily/projects/thebridge/handlers/setup/LocationCategory.java b/src/main/java/plugily/projects/thebridge/handlers/setup/LocationCategory.java index a695040..e003f5f 100644 --- a/src/main/java/plugily/projects/thebridge/handlers/setup/LocationCategory.java +++ b/src/main/java/plugily/projects/thebridge/handlers/setup/LocationCategory.java @@ -20,10 +20,13 @@ package plugily.projects.thebridge.handlers.setup; +import plugily.projects.minigamesbox.classic.handlers.language.MessageBuilder; import plugily.projects.minigamesbox.classic.handlers.setup.categories.PluginLocationCategory; import plugily.projects.minigamesbox.classic.handlers.setup.items.category.LocationItem; import plugily.projects.minigamesbox.classic.handlers.setup.items.category.LocationSelectorItem; +import plugily.projects.minigamesbox.classic.utils.dimensional.Cuboid; import plugily.projects.minigamesbox.classic.utils.helper.ItemBuilder; +import plugily.projects.minigamesbox.classic.utils.serialization.LocationSerializer; import plugily.projects.minigamesbox.classic.utils.version.xseries.XMaterial; import plugily.projects.minigamesbox.inventory.normal.NormalFastInv; @@ -42,7 +45,19 @@ public void addItems(NormalFastInv gui) { gui.setItem((getInventoryLine() * 9) + 4, midLocation); getItemList().add(midLocation); - LocationSelectorItem arenaBorder = new LocationSelectorItem(getSetupInventory(), new ItemBuilder(XMaterial.BEDROCK.parseMaterial()), "Arena", "Location where all bases and lines are in \n (players will be able to build inside) \n MAKE SURE TO SET IT OUTSIDE \n OF THE BASES WHICH YOU SET BEFORE!", "arenalocation"); + LocationSelectorItem arenaBorder = new LocationSelectorItem(getSetupInventory(), new ItemBuilder(XMaterial.BEDROCK.parseMaterial()), "Arena Cuboid/Border", "Location where all bases and lines are in \n (players will be able to build inside) \n MAKE SURE TO SET IT OUTSIDE \n OF THE BASES (Baselocations) WHICH YOU SET BEFORE!", "arenalocation", inventoryClickEvent -> { + String path = "instances." + getSetupInventory().getArenaKey(); + if(getSetupInventory().getConfig().getString(path + ".arenalocation.1") != null && getSetupInventory().getConfig().getString(path + ".arenalocation.2") != null) { + Cuboid arenaCuboid = new Cuboid(LocationSerializer.getLocation(getSetupInventory().getConfig().getString(path + ".arenalocation.1", "world,364.0,63.0,-72.0,0.0,0.0")), LocationSerializer.getLocation(getSetupInventory().getConfig().getString(path + ".arenalocation.2", "world,364.0,63.0,-72.0,0.0,0.0"))); + for(String bases : getSetupInventory().getConfig().getConfigurationSection("instances." + getSetupInventory().getArenaKey() + ".bases").getKeys(false)) { + if(getSetupInventory().getConfig().getString(path + "." + bases + ".baselocation.1") != null && getSetupInventory().getConfig().getString(path + "." + bases + ".baselocation.2") != null) { + if(!(arenaCuboid.isIn(LocationSerializer.getLocation(getSetupInventory().getConfig().getString(path + "." + bases + ".baselocation.1"))) && arenaCuboid.isIn(LocationSerializer.getLocation(getSetupInventory().getConfig().getString(path + "." + bases + ".baselocation.2"))))) { + new MessageBuilder("&c&l✘ &cArena validation failed! Please set your arena cuboids outside your base cuboids! The arena needs to be bigger than your bases locations! The following base is not inside the arena cuboid: " + bases).prefix().player(getSetupInventory().getPlayer()).sendPlayer(); + } + } + } + } + }); gui.setItem((getInventoryLine() * 9) + 5, arenaBorder); getItemList().add(arenaBorder); } diff --git a/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java b/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java index 845d548..e1962f3 100644 --- a/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java +++ b/src/main/java/plugily/projects/thebridge/handlers/setup/components/BasePage.java @@ -131,10 +131,10 @@ public Prompt acceptInput(ConversationContext context, String input) { new MessageBuilder("&c&l✘ &cBase validation failed! Please configure portalhologram properly!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } - if(setupInventory.getConfig().getString(path + ".arenalocation.1") != null && setupInventory.getConfig().getString(path + ".arenalocation.2") != null) { - Cuboid arenaBorder = new Cuboid(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".arenalocation.1", "world,364.0,63.0,-72.0,0.0,0.0")), LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".arenalocation.2", "world,364.0,63.0,-72.0,0.0,0.0"))); + if(setupInventory.getConfig().getString("instances." + setupInventory.getArenaKey() + ".arenalocation.1") != null && setupInventory.getConfig().getString("instances." + setupInventory.getArenaKey() + ".arenalocation.2") != null) { + Cuboid arenaBorder = new Cuboid(LocationSerializer.getLocation(setupInventory.getConfig().getString("instances." + setupInventory.getArenaKey() + ".arenalocation.1", "world,364.0,63.0,-72.0,0.0,0.0")), LocationSerializer.getLocation(setupInventory.getConfig().getString("instances." + setupInventory.getArenaKey() + ".arenalocation.2", "world,364.0,63.0,-72.0,0.0,0.0"))); if(!(arenaBorder.isIn(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".baselocation.1"))) && arenaBorder.isIn(LocationSerializer.getLocation(setupInventory.getConfig().getString(path + ".baselocation.2"))))) { - new MessageBuilder("&c&l✘ &cBase validation failed! Please set your base cuboids (baselocation.1 and baselocation.2) inside your arena cuboid!").prefix().player(setupInventory.getPlayer()).sendPlayer(); + new MessageBuilder("&c&l✘ &cBase validation failed! Please set your base cuboids (baselocation.1 and baselocation.2) inside your arena cuboid (Main Setup Menu of Arena -> Arena)!").prefix().player(setupInventory.getPlayer()).sendPlayer(); return; } } From 8d2444c3edf150a1bb74451b8e97eb028a4208b6 Mon Sep 17 00:00:00 2001 From: "version-bump[github-action]" <41898282+version-bump[github-action]@users.noreply.github.com> Date: Thu, 14 May 2026 08:44:22 +0000 Subject: [PATCH 8/8] Bump version from 2.1.7-SNAPSHOT1 to 2.1.7-SNAPSHOT2 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 4b672fe..7614866 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ plugily.projects thebridge - 2.1.7-SNAPSHOT1 + 2.1.7-SNAPSHOT2 TheBridge