Fabric API

Fabric API

106M Downloads

Method for getting the mining level of a block

Juuxel opened this issue ยท 4 comments

commented

Edit: current status as of tool attributes 1.1

tool attribute 1.1 added a method to get it, however it is still in impl classes
ToolManagerImpl.entryNullable(block).getMiningLevel()

Old description Currently you have to do some mixin/reflection hacks on `ToolManager.EntryImpl` if you want to get the mining level of a block that uses `FabricBlockSettings.breakByTool(Tag, int)`, so a public method for doing that would be nice.
commented

Resolved by #1629

commented

Did tool attributes v1.1 cover this?

commented

I'll have to check. I know that tool attributes 1.0 didn't include this.

commented

tool attribute 1.1 added a method to get it, however it is still in impl classes
ToolManagerImpl.entryNullable(block).getMiningLevel()