Adapt framework code for MC 1.21.11 - part 2/3#295
Draft
mj41 wants to merge 1 commit intoTnze:masterfrom
Draft
Conversation
This was referenced Feb 16, 2026
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.
Credits
Co-authored with Claude Opus 4.6 (Anthropic) via GitHub Copilot.
Summary
Hand-written framework changes to support Minecraft 1.21.11 (protocol 774).
Updates bot, server, level, registry, chat/signing, inventory, and component
infrastructure.
This PR contains only human-authored code changes — no auto-generated files.
Depends on PR #294 (tools pipeline). The generated data files follow in PR #296.
Commit
Adapt framework code for MC 1.21.11 — 41 files changed, 1,317 insertions(+),
204 deletions(-)
Changes by Category
Protocol Version
ProtocolVersion: 767 → 774ProtocolVersion: 764 → 774"1.21.11"Protocol Fixes
registry/): AddedExtraRegistriesmap for unknownregistry types sent by 1.21.11 servers.
Registry()returns dynamic registryinstead of nil. Tags handler no longer fatals on unknown registries.
ReadFromalways calls
Put()to maintain ID ordering. Tags gracefully skipout-of-range IDs.
level/palette.go): Removed VarInt data array length prefix —MC 1.21.5+ (protocol 770+) no longer sends it. Reader computes expected long
count from bits-per-entry and container capacity.
bot/basic/events.go): Rewritten for protocol 769+format — TeleportID first, added DX/DY/DZ velocity fields, Flags from
byteto
int32.bot/basic/settings.go): ViewDistance/ChatMode/MainHandwidened from
int8toint, addedParticleStatusfield.level/chunk.go): Encode as typed long arrays insteadof NBT compound for protocol 774+.
level/chunk.go): Removed from bothReadFromandWriteTo(dropped in MC 1.20.2).Chat & Signing
chat/sign/sign.go): AddedChecksumbyte field.Zero value =
IGNORE_CHECKSUM(backward compatible).bot/msg/chat.go): AddedglobalIndex VarIntasfirst field (new in 1.21.11).
chat/sign/sign.go): Fixed value→pointer receiver, addedid - 1decode for wire format,io.ReadFullfor 256-byte signatures.Inventory & Components
bot/screen/screen.go): RewroteReadFrom/WriteToforpost-1.20.5 format. ReadFrom now consumes component data via
component.NewComponent(). WriteTo sendsCount→ItemID→0→0(no customcomponents). Removed NBT field.
bot/screen/screen.go): New handler forClientboundSetPlayerInventorypacket (1.20.5+).level/component/types.go): 541 lines of sharedcomponent types —
EitherHolder,Holder,CompositeHolder,ItemSlot,FilterableText,SoundEvent, etc.bannerpatterns.go,bees.go,blocksattacks.go,blockstate.go,eitherholder.go,kineticweapon.go,profile.go,writtenbookcontent.goattributemodifiers.go,enchantments.go,lodestonetracker.go,suspicioussteweffects.go,tool.go,writablebookcontent.goServer-Side
server/configuration.go): Rewrote from single NBTblob to per-registry packets (1.20.5+ format).
Breaking Changes
Slotstruct: RemovedNBTfield, addedComponentsAdd/ComponentsRemoveTeleportedcallback:flags byte→flags int32ClientboundLoginGameProfilerenamed toClientboundLoginLoginFinishedProtocolVersionchangedRelated