OptionalblockList of block material names that can be broken by this instrument. Defined by ToolAPI.registerTool,
OptionalbrokenNumeric ID of the item that replaces tool item when it's broken. By default the tool disappears.
OptionalcalcFunction used to recalculate block destroy time based on some custom logic.
Tool item.
Coordinates where the block is being broken.
Block that is being broken.
Some time properties that can be used to calculate destroy time for the tool and block.
Base destroy time of the block.
Tool material devider.
Divider applied due to efficiency enchantment.
Default block destroy time, calculated as base / divider / modifier.
OptionalenchantData: EnchantDataTool's enchant data.
OptionaldamageBase damage of the instrument, is added to the material damage to calculate the tool's final damage.
Optional InternalisIf true, the tool is vanilla Minecraft tool. Generally used within
Core Engine code and should not be used within mods until you really
know what you're doing.
OptionalisIf true, breaking blocks with this tool makes it break 2x faster, otherwise attacking mobs breaks tool 2x faster.
OptionalmodifyFunction that is used to change enchant data object before all the calculations. Can be used to add some enchantment properties, such as silk touch, efficiency, unbreaking or fortune.
Tool's enchant data.
Tool item.
Optionalcoords: ItemUseCoordinatesCoordinates where the block is being broken. Passed only if the block is destroyed.
Optionalblock: TileDestroyed block data. Passed only if the block is destroyed.
OptionalonFunction that is called when players attacks some entity with the tool.
Tool item.
Unique numeric ID of the entity that is attacked.
Entity UID of the player that attacked victim.
true if default damage should not be applied to the instrument,
false otherwise.
OptionalonFunction that is called when the instrument is broken.
Tool item.
true if default breaking behavior (replacing by brokenId item)
should not be applied.
OptionalonFunction that is called when the block is destroyed.
Tool item.
Coordinates where the block is destroyed.
Block that is destroyed.
Entity UID of the player that destroyed the block.
true if default damage should not be applied to the instrument,
false otherwise.
OptionalonFunction that is called when the block that has a destroy function is destroyed.
Coordinates where the block is destroyed.
An item in player's hand.
Block that was destroyed.
BlockSource object of the world where the block was destroyed.
Entity UID of the player that destroyed the block.
OptionaltoolProperties of the tool material. Defined by ToolAPI.registerTool,
Copyright © 2024 Nernar. Copyright © 2020 #mineprogramming. Built with ❤ and TypeDoc.
Object containing additional parameters and functions used by Core Engine to work with the tool.