mirror of
https://github.com/KAMKEEL/CustomNPC-Plus-API.git
synced 2026-11-17 09:55:12 +00:00
Implemented anvil repair and item destroyed events for custom items and linked items
This commit is contained in:
1 parent
c372a031fb
commit
3f0171aafe
1 file changed
+17
@@ -4,6 +4,7 @@ import cpw.mods.fml.common.eventhandler.Cancelable;
|
||||
import noppes.npcs.api.entity.IEntity;
|
||||
import noppes.npcs.api.entity.IPlayer;
|
||||
import noppes.npcs.api.item.IItemCustomizable;
|
||||
import noppes.npcs.api.item.IItemStack;
|
||||
|
||||
public interface IItemEvent extends ICustomNPCsEvent {
|
||||
|
||||
@@ -84,6 +85,22 @@ public interface IItemEvent extends ICustomNPCsEvent {
|
||||
}
|
||||
|
||||
// onBreakEvent if Durability Expires or Consumed
|
||||
interface BreakItem extends IItemEvent {
|
||||
|
||||
IItemStack getBrokenStack();
|
||||
|
||||
IPlayer getPlayer();
|
||||
}
|
||||
|
||||
// onRepairEvent
|
||||
interface RepairItem extends IItemEvent {
|
||||
|
||||
IItemStack getLeft();
|
||||
|
||||
IItemStack getRight();
|
||||
|
||||
IItemStack getOutput();
|
||||
|
||||
float getAnvilBreakChance();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user