Skip to content

fix: netease v860 codec helper should inherit v844 for correct gamerule encoding#288

Merged
smartcmd merged 1 commit into
AllayMC:mainfrom
lt-name:fix/netease-v860-gamerule-codec
Jul 5, 2026
Merged

fix: netease v860 codec helper should inherit v844 for correct gamerule encoding#288
smartcmd merged 1 commit into
AllayMC:mainfrom
lt-name:fix/netease-v860-gamerule-codec

Conversation

@lt-name

@lt-name lt-name commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

NetEase 1.21.124 maps to vanilla v860, whose GameRulesChangedPacket serializes integer game rules with readIntLE/writeIntLE (introduced in BedrockCodecHelper_v844). The NetEase helper previously inherited from BedrockCodecHelper_v776, which fell back to the v440 implementation using VarInts.readUnsignedInt/writeUnsignedInt.

This mismatch caused 'Invalid gamerule type received' when decoding any integer game rule (e.g. maxcommandchainlength), as the bytes were misinterpreted.

Switch the parent to BedrockCodecHelper_v844 to align with vanilla v860/v844 behavior. The existing readLargeVarIntFlags overrides are preserved.

…le encoding

NetEase 1.21.124 maps to vanilla v860, whose GameRulesChangedPacket
serializes integer game rules with readIntLE/writeIntLE (introduced in
BedrockCodecHelper_v844). The NetEase helper previously inherited from
BedrockCodecHelper_v776, which fell back to the v440 implementation
using VarInts.readUnsignedInt/writeUnsignedInt.

This mismatch caused 'Invalid gamerule type received' when decoding any
integer game rule (e.g. maxcommandchainlength), as the bytes were
misinterpreted.

Switch the parent to BedrockCodecHelper_v844 to align with vanilla
v860/v844 behavior. The existing readLargeVarIntFlags overrides are
preserved.
@smartcmd
smartcmd merged commit 9c1c4a9 into AllayMC:main Jul 5, 2026
1 check passed
@lt-name
lt-name deleted the fix/netease-v860-gamerule-codec branch July 5, 2026 12:57
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