Tool
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.api.item.component.Tool;
Members
Getter
// Tool.damagePerBlock as intmyTool.damagePerBlock
Return Type:
int
Getter
// Tool.defaultMiningSpeed as floatmyTool.defaultMiningSpeed
Return Type:
float
getMiningSpeed(state as BlockState) as float
myTool.getMiningSpeed(myBlockState);
Parameters:
state: BlockState
Type: BlockState
Return Type:
float
isCorrectForDrops(state as BlockState) as bool
myTool.isCorrectForDrops(myBlockState);
Parameters:
state: BlockState
Type: BlockState
Return Type:
bool
static of(rules as List<Rule>, defaultMiningSpeed as float, damagePerBlock as int) as Tool