Add hasDataCommand and furnaceNbtUsesSnakeCase features - #1260
Merged
Conversation
u9g
added a commit
to PrismarineJS/mineflayer
that referenced
this pull request
Aug 29, 2026
Replaces the hardcoded version comparisons with hasDataCommand and furnaceNbtUsesSnakeCase (PrismarineJS/minecraft-data#1260).
Member
|
Resolve conflicts |
/blockdata was replaced by /data merge block in 1.13, and the furnace block entity's CookTime key was renamed cooking_time_spent in 1.21.4 (1.21.3 still accepts CookTime). Needed by PrismarineJS/mineflayer#3990 to fast-forward a furnace without hardcoding version comparisons.
u9g
added a commit
to PrismarineJS/mineflayer
that referenced
this pull request
Aug 31, 2026
Replaces the hardcoded version comparisons with hasDataCommand and furnaceNbtUsesSnakeCase (PrismarineJS/minecraft-data#1260).
u9g
added a commit
to PrismarineJS/mineflayer
that referenced
this pull request
Sep 4, 2026
Replaces the hardcoded version comparisons with hasDataCommand and furnaceNbtUsesSnakeCase (PrismarineJS/minecraft-data#1260).
u9g
added a commit
to PrismarineJS/mineflayer
that referenced
this pull request
Sep 4, 2026
Replaces the hardcoded version comparisons with hasDataCommand and furnaceNbtUsesSnakeCase (PrismarineJS/minecraft-data#1260).
rom1504
pushed a commit
to PrismarineJS/mineflayer
that referenced
this pull request
Sep 5, 2026
* Speed up furnace external test by fast-forwarding CookTime The furnace test spent ~10s per version waiting out a real 200-tick smelt. Instead, after asserting the smelt has genuinely started (0 < progress < 1), merge CookTime:195s into the furnace block entity and wait for the output slot to populate — the output is still produced by the vanilla tick path, so all assertions are unchanged. Cuts the test from ~12s to ~3s per version, ~4.5 minutes across the matrix. The await runs 250-320ms on every tested version, so it uses a tight 500ms timeout: if the merge silently does nothing (wrong field name or command for a future version), the test fails fast instead of sitting out the real smelt. Verified against real servers on all 28 tested versions (1.21.4+ placement verified on top of PR #3960, which master needs for those versions regardless of this change). * test(furnace): gate the NBT fast-forward on minecraft-data features Replaces the hardcoded version comparisons with hasDataCommand and furnaceNbtUsesSnakeCase (PrismarineJS/minecraft-data#1260).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two features needed by PrismarineJS/mineflayer#3990 so the furnace test can use
bot.supportFeatureinstead of hardcoded version comparisons:hasDataCommand(1.13+):/blockdatawas replaced by/data merge blockin 1.13.furnaceNbtUsesSnakeCase(1.21.4+): the furnace block entity'sCookTimekey becamecooking_time_spentin 1.21.4 (1.21.3 still acceptsCookTime; 1.21.4 does not).Both boundaries were verified against real servers across all 28 versions in mineflayer's CI matrix in that PR.