LivingEntityUseItemFinishEvent
Importing the class
If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.
import crafttweaker.neoforge.api.event.entity.use.LivingEntityUseItemFinishEvent;
Extends
LivingEntityUseItemFinishEvent extends LivingEntityUseItemEvent
.
Listening to the event
This event can be listened to like so:
events.register<crafttweaker.neoforge.api.event.entity.use.LivingEntityUseItemFinishEvent>(event => { println("LivingEntityUseItemFinishEvent ran!");});
Members
Getter
// Finish.duration as intevent.duration
Return Type:
int
Setter
// Finish.duration = (duration as int);event.duration = myInt;
Parameters:
duration: int
Type: int
Getter
// Finish.entity as LivingEntityevent.entity
Return Type:
LivingEntity
Getter
Getter
// Finish.item as IItemStackevent.item
Return Type:
IItemStack
Getter
// Finish.resultStack as IItemStackevent.resultStack
Return Type:
IItemStack
Setter
event.resultStack = myIItemStack;
Parameters:
stack: IItemStack
Type: IItemStack