public class ItemTransformEvent extends Event implements Cancellable
Constructor and Description |
---|
ItemTransformEvent(Item item,
short newTypeID,
int newStacksize) |
Modifier and Type | Method and Description |
---|---|
Item |
getItem()
Gets the item that's about to transform.
|
int |
getNewStacksize() |
short |
getNewTypeID()
Gets the new target item type ID.
|
boolean |
isCancelled()
Determines if the event is cancelled.
|
void |
setCancelled(boolean cancel)
Cancels this event.
|
void |
setNewStacksize(int newStacksize) |
void |
setNewTypeID(short newTypeID) |
public ItemTransformEvent(Item item, short newTypeID, int newStacksize)
public Item getItem()
public short getNewTypeID()
getItem()
returns a raw steak, getNewTypeID()
usually returns the type ID of a cooked steak).public int getNewStacksize()
public void setNewTypeID(short newTypeID)
public void setNewStacksize(int newStacksize)
public boolean isCancelled()
Cancellable
isCancelled
in interface Cancellable
public void setCancelled(boolean cancel)
Cancellable
setCancelled
in interface Cancellable
cancel
- set to true if you want to cancel this event.