ItemDamageEvent

The Item Damage Event is an event called when an item should be damaged less or more than usual because of an enchantment.

Description
The ItemDamageEvent is a class that adds three local variables: the old damage that should've been done to the item, the new damage that should apply to the item, and the item itself.

Constructor
ItemDamageEvent(Player who, EnchantmentLevel enchantment, ItemStack item, int oldDamage, int newDamage)
 * // Player who - the player holding the item being damaged
 * // EnchantmentLevel enchantment - the enchantment and level modifying the damage
 * // ItemStack item - the item being damaged
 * // int oldDamage - the original damage to the item
 * // int newDamage - the final damage to the item

Implements
None

Extends
ESPlayerEvent

ItemStack getItem
Gets the item being damaged

int getOldDamage
Gets the original damage to the item

int getNewDamage
Gets the new damage to the item

void setNewDamage(int newDamage)
Sets the new damage of the item to the specified value