Skip to content

Prioritize mineable material when multiple matches are found to fix problem of wrong dig time computation#71

Open
NoClipMonster wants to merge 3 commits into
PrismarineJS:mainfrom
NoClipMonster:temp-fix-for-incorrect_for_wooden_tool-material-tag
Open

Prioritize mineable material when multiple matches are found to fix problem of wrong dig time computation#71
NoClipMonster wants to merge 3 commits into
PrismarineJS:mainfrom
NoClipMonster:temp-fix-for-incorrect_for_wooden_tool-material-tag

Conversation

@NoClipMonster
Copy link
Copy Markdown

@NoClipMonster NoClipMonster commented May 25, 2026

Fix implemented and tested only on 1.21.11. Looks like digTime became right. Please tell me if something wrong with this implementation and i don't see it.

…iple matches are found to fix problem of wrong dig time computation
@NoClipMonster NoClipMonster changed the title Enhance BlocksDataGenerator to prioritize mineable material when multiple matches are found to fix problem of wrong dig time computation Prioritize mineable material when multiple matches are found to fix problem of wrong dig time computation May 25, 2026
@VasilisDragon
Copy link
Copy Markdown

Built and ran the generator locally against 1.21.11 with this branch — fixes the failure mode I documented in PrismarineJS/minecraft-data#1193 (where extremeheat pointed out the durable fix belongs in the generator, not in patched output).

Whole-file count of incorrect_for_wooden_tool in the regenerated blocks.json drops from 108 to 0. Spot-check across categories:

Block Before After
diamond_ore incorrect_for_wooden_tool mineable/pickaxe
deepslate_diamond_ore incorrect_for_wooden_tool mineable/pickaxe
copper_block incorrect_for_wooden_tool mineable/pickaxe
iron_block incorrect_for_wooden_tool mineable/pickaxe
obsidian incorrect_for_wooden_tool mineable/pickaxe

harvestTools stays populated, so bot.digTime() now routes through the mineable/pickaxe tier table.

The symptom reproduces across 1.20.5 through 1.21.11; this PR only touches mc/1.21.11/. Surrounding code is identical in the other affected versions, so the 5-line patch should port cleanly. Happy to validate or leave as a follow-up.

Will close PrismarineJS/minecraft-data#1193 once this lands.

@NoClipMonster
Copy link
Copy Markdown
Author

NoClipMonster commented May 27, 2026

Fix implemented on 1.20.5 and higher versions
Waiting for @extremeheat for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants