Clone kit items when given to players so the kit doesn't end up edited.
This commit is contained in:
parent
e95baae80a
commit
350ccac983
|
@ -276,7 +276,7 @@ public class KitHandler {
|
||||||
plugin.getGuiManager().showGUI(player, new AnimatedKitGui(plugin, player, kit, item.getItem()));
|
plugin.getGuiManager().showGUI(player, new AnimatedKitGui(plugin, player, kit, item.getItem()));
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
ItemStack parseStack = item.getContent().process(player);
|
ItemStack parseStack = item.getContent().process(player).clone();
|
||||||
if (!(item.getContent() instanceof KitContentEconomy || item.getContent() instanceof KitContentCommand)) {
|
if (!(item.getContent() instanceof KitContentEconomy || item.getContent() instanceof KitContentCommand)) {
|
||||||
if (Settings.AUTO_EQUIP_ARMOR.getBoolean() && ArmorType.equip(player, parseStack)) {
|
if (Settings.AUTO_EQUIP_ARMOR.getBoolean() && ArmorType.equip(player, parseStack)) {
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Reference in New Issue