mirror of
https://github.com/StarWishsama/Slimefun4.git
synced 2024-09-20 03:35:51 +00:00
Fixed Talisman of Anvil
Issue was posted in: https://github.com/TheBusyBiscuit/Slimefun4/issues/229
This commit is contained in:
parent
7c69607cbd
commit
07ac226556
@ -70,7 +70,9 @@ public class TalismanListener implements Listener {
|
|||||||
|
|
||||||
@EventHandler
|
@EventHandler
|
||||||
public void onItemBreak(PlayerItemBreakEvent e) {
|
public void onItemBreak(PlayerItemBreakEvent e) {
|
||||||
if (Talisman.checkFor(e, SlimefunItem.getByName("ANVIL_TALISMAN"))) e.getBrokenItem().setAmount(1);
|
if (Talisman.checkFor(e, SlimefunItem.getByName("ANVIL_TALISMAN")))
|
||||||
|
e.getBrokenItem().setDurability((short)0);
|
||||||
|
e.getPlayer().getInventory().addItem(e.getBrokenItem());
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler
|
@EventHandler
|
||||||
|
Loading…
Reference in New Issue
Block a user