@@ -45,13 +45,13 @@ public class Kit implements IKit, ConfigData {
4545 private HashSet <Arena > arenas ;
4646 private ItemStack icon ;
4747 private HashMap <KitRule , Boolean > rules ;
48- private int queue , playing , slot , kitEditorSlot ;
48+ private int queue , playing , slot , kitEditorSlot , leaderboardSlot ;
4949 private double health ;
5050 private List <PotionEffect > potionEffects ;
5151 private double damageMultiplier ;
5252
5353 public Kit (String name , String displayName , List <ItemStack > items , HashSet <Arena > arenas , ItemStack icon ,
54- HashMap <KitRule , Boolean > rules , int slot , double health , int kitEditorSlot ,
54+ HashMap <KitRule , Boolean > rules , int slot , double health , int kitEditorSlot , int leaderboardSlot ,
5555 List <PotionEffect > potionEffects , double damageMultiplier ) {
5656 this .name = name ;
5757 this .displayName = displayName ;
@@ -64,6 +64,7 @@ public Kit(String name, String displayName, List<ItemStack> items, HashSet<Arena
6464 this .slot = slot ;
6565 this .health = health ;
6666 this .kitEditorSlot = kitEditorSlot ;
67+ this .leaderboardSlot = leaderboardSlot ;
6768 this .potionEffects = potionEffects ;
6869 this .damageMultiplier = damageMultiplier ;
6970
@@ -82,6 +83,7 @@ public Kit(String name, Player player) {
8283 this .slot = KitService .get ().kits .size () + 1 ;
8384 this .health = 20 ;
8485 this .kitEditorSlot = slot ;
86+ this .leaderboardSlot = slot ;
8587 this .damageMultiplier = 1.0 ;
8688
8789 this .potionEffects = new ArrayList <>();
@@ -109,6 +111,7 @@ public Kit(String name, List<ItemStack> items, ItemStack icon) {
109111 this .slot = KitService .get ().kits .size () + 1 ;
110112 this .health = 20 ;
111113 this .kitEditorSlot = slot ;
114+ this .leaderboardSlot = slot ;
112115 this .potionEffects = new ArrayList <>();
113116 this .damageMultiplier = 1.0 ;
114117
@@ -176,6 +179,7 @@ public void write(ConfigurationSection s) {
176179 s .set ("slot" , slot );
177180 s .set ("health" , health );
178181 s .set ("kitEditor-slot" , kitEditorSlot );
182+ s .set ("leaderboard-slot" , leaderboardSlot );
179183 s .set ("damage-multiplier" , damageMultiplier );
180184 for (Map .Entry <KitRule , Boolean > e : rules .entrySet ()) {
181185 s .set (e .getKey ().getSaveName (), e .getValue ());
@@ -187,6 +191,7 @@ public static Kit read(String name, ConfigurationSection s) {
187191 List <ItemStack > items = ItemUtils .deserialize (s .getString ("items" , "" ));
188192 int slot = s .getInt ("slot" , KitService .get ().kits .size () + 1 );
189193 int kitEditorSlot = s .getInt ("kitEditor-slot" , slot );
194+ int leaderboardSlot = s .getInt ("leaderboard-slot" , slot );
190195 double health = s .getDouble ("health" , 20 );
191196 double damageMultiplier = s .getDouble ("damage-multiplier" , 1.0 );
192197
@@ -212,7 +217,7 @@ public static Kit read(String name, ConfigurationSection s) {
212217 }
213218
214219 return new Kit (name , s .getString ("displayName" , name ), items , arenas , icon , rules ,
215- slot , health , kitEditorSlot , potionEffects , damageMultiplier );
220+ slot , health , kitEditorSlot , leaderboardSlot , potionEffects , damageMultiplier );
216221 }
217222
218223 public boolean is (KitRule kitRule ) {
0 commit comments