BlockToolModificationEvent
Link to blocktoolmodificationevent
The event is not cancelable.
The event does not have a result.
Importing the class
Link to importing-the-class
Importing the class is recommended for events, simply add this line to the top of your script file.
ZenScript Copyimport crafttweaker.neoforge.api.event.block.BlockToolModificationEvent;
Listening to the event
Link to listening-to-the-event
ZenScript Copyevents.register<crafttweaker.neoforge.api.event.block.BlockToolModificationEvent>(event => {
println("BlockToolModificationEvent ran!");
});
Supertype
Link to supertype
BlockToolModificationEvent extends BlockEvent. That means all methods available in BlockEvent are also available in BlockToolModificationEvent
Implemented Interfaces
Link to implemented-interfaces
BlockToolModificationEvent implements the following interfaces. That means all methods defined in these interfaces are also available in BlockToolModificationEvent
Properties
Link to properties
Name | Type | Has Getter | Has Setter | Description |
---|---|---|---|---|
Name context | Type UseOnContext | Has Getter true | Has Setter false | Description |
Name finalState | Type BlockToolModificationEvent | Has Getter true | Has Setter true | Description Sets the transformed state after tool use. If not set, will return the original state. This will be bypassed if canceled, returning null instead. |
Name heldItemStack | Type IItemStack | Has Getter true | Has Setter false | Description |
Name isSimulated | Type boolean | Has Getter true | Has Setter false | Description |
Name player | Type Player | Has Getter true | Has Setter false | Description |
Name toolAction | Type ToolAction | Has Getter true | Has Setter false | Description |