postProcessMiningSpeed

float postProcessMiningSpeed(Tag<Item> tag, BlockState state, ItemStack stack, @Nullable() LivingEntity user, float currentSpeed, boolean isEffective)

Post process the mining speed, this takes place after the mining speed has been calculated.

This allows bypassing the regular computation formula.

Return

the speed after post processing

Parameters

tag

The tool tag the item stack is handled by

state

The block to mine

stack

The item stack being used to mine the block

user

The current user of the tool, or null if there isn't any

currentSpeed

The mining speed before post process

isEffective

whether the tool has been handled

Sources

jvm source
Link copied to clipboard