Add clear inventory API to PlayerInventory with a successful count return. Adds BUKKIT-2745
This commit is contained in:
parent
2d5ae73809
commit
0290aee17e
@ -102,5 +102,16 @@ public interface PlayerInventory extends Inventory {
|
|||||||
*/
|
*/
|
||||||
public int getHeldItemSlot();
|
public int getHeldItemSlot();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Clears all matching items from the inventory. Setting either value to -1 will skip it's check,
|
||||||
|
* while setting both to -1 will clear all items in your inventory unconditionally.
|
||||||
|
*
|
||||||
|
* @param id the id of the item you want to clear from the inventory
|
||||||
|
* @param data the data of the item you want to clear from the inventory
|
||||||
|
*
|
||||||
|
* @return The number of items cleared
|
||||||
|
*/
|
||||||
|
public int clear(int id, int data);
|
||||||
|
|
||||||
public HumanEntity getHolder();
|
public HumanEntity getHolder();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user