EntityLivingEquipmentChange
Link to entitylivingequipmentchange
EntityLivingEquipmentChangeEvent is fired when the Equipment of a Entity changes. This also includes entities joining the World, as well as being cloned.
slot
contains the affected IEntityEquipmentSlot.
item
contains the IItemStack that is equipped now.
olditem
contains the IItemStack that was equipped before the EquipmentChange happend.
Event Class
Link to event-class
You will need to cast the event in the function header as this class:
crafttweaker.event.EntityLivingEquipmentChangeEvent
You can, of course, also import the class before and use that name then.
Event interface extensions
Link to event-interface-extensions
EntityLivingEquipmentChangeEvent implements the following interfaces and are able to call all of their methods/getters/setters as well:
ZenGetters/ZenSetters
Link to zengetterszensetters
The following information can be retrieved from the event:
ZenGetter | ZenSetter | Type |
---|---|---|
ZenGetter newItem | ZenSetter | Type IItemStack |
ZenGetter oldItem | ZenSetter | Type IItemStack |
ZenGetter slot | ZenSetter | Type IEntityEquipmentSlot |
ZenGetters/ZenSetters/ZenMethods from extensions
Link to zengetterszensetterszenmethods-from-extensions
The following information can be retrieved/set during the event:
ZenGetter | ZenSetter | Type |
---|---|---|
ZenGetter entityLivingBase | ZenSetter | Type IEntityLivingBase |