From fc54a8afd24e593f5e4d7d745a3f9932525cca65 Mon Sep 17 00:00:00 2001 From: Lixfel Date: Sat, 21 May 2022 15:48:05 +0200 Subject: [PATCH] Fix HotbarKit for test arenas Signed-off-by: Lixfel --- .../src/de/steamwar/fightsystem/fight/FightTeam.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/FightSystem_Core/src/de/steamwar/fightsystem/fight/FightTeam.java b/FightSystem_Core/src/de/steamwar/fightsystem/fight/FightTeam.java index 7c28bdb..e76b0fa 100644 --- a/FightSystem_Core/src/de/steamwar/fightsystem/fight/FightTeam.java +++ b/FightSystem_Core/src/de/steamwar/fightsystem/fight/FightTeam.java @@ -68,6 +68,9 @@ public class FightTeam { notReadyKit.setItem(3, "REMOVE_PLAYERS", new ItemBuilder(SWItem.getMaterial("FIREWORK_CHARGE")).removeAllAttributes().build(), GUI::chooseRemove); } + if(Config.test()) + notReadyKit.setItem(1, "CHOOSE_SCHEMATIC", new ItemBuilder(SWItem.getMaterial("CAULDRON_ITEM")).removeAllAttributes().addEnchantment(Enchantment.DURABILITY, 1).build(), GUI::preSchemDialog); + notReadyKit.setItem(4, "TEAM_NOT_READY", new ItemBuilder(SWItem.getDye(10), (short) 10).removeAllAttributes().addEnchantment(Enchantment.DURABILITY, 1).build(), player -> Objects.requireNonNull(Fight.getPlayerTeam(player)).setReady(true)); } private static final HotbarKit chooseSchemKit = new HotbarKit(notReadyKit); @@ -328,7 +331,7 @@ public class FightTeam { leader.setKit(Kit.getKitByName(Config.LeaderDefault)); Player player = leader.getPlayer(); - if(Config.test() || FightState.getFightState() != FightState.POST_SCHEM_SETUP) + if(FightState.getFightState() != FightState.POST_SCHEM_SETUP) chooseSchemKit.loadToPlayer(player); else notReadyKit.loadToPlayer(player);