Make items in the Setup Mode toolbox unbreakable.
This makes it unnecessary to set the item durability, which was being done via deprecated API anyway. Partial fix for #406
This commit is contained in:
parent
0fa11eb84f
commit
dd31a11b60
|
@ -203,6 +203,7 @@ public class SetupCommand implements Command, Listener {
|
|||
color("&9Left&r: &r" + left),
|
||||
color("&cRight&r: &r" + right)
|
||||
));
|
||||
meta.setUnbreakable(true);
|
||||
tool.setItemMeta(meta);
|
||||
return tool;
|
||||
}
|
||||
|
@ -245,7 +246,6 @@ public class SetupCommand implements Command, Listener {
|
|||
if (!isTool(tool)) return;
|
||||
|
||||
event.setCancelled(true);
|
||||
tool.setDurability((short) 0);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
|
Loading…
Reference in New Issue