Closed 1zun4 closed 9 months ago
The reason for this issue is that they introduced writeOptional
, which first writes a boolean and then proceeds to either write the UUID or not.
This causes the UUID to be wrong and the length of the packet being off by 1.
It seems I am stupid enough to use the wrong branch, as this was already fixed by https://github.com/azalea-rs/azalea/blob/1.20.1/azalea-protocol/src/packets/login/serverbound_hello_packet.rs
Was this changed back in 1.20.2? When I understood correctly, the main branch is targeting protocol 764, which is 1.20.2.
Yes, indeed. It was changed back. I will therefore close this issue as I am embarrasing myself.
For my use-case I will have to pass the fitting struct depending on specific protocol number.
So if you try to parse a ServerboundHelloPacket, it will fail due to
Leftover data after reading packet ServerboundHelloPacket: [186]
By disabling the debug assertions
we can get a reading of the packet:
1zun4 (0185ac9d-5ec3-204e-9493-3b3b0b8f6c51) is attempting to join **.**.**.**:25565
.Looking at the UUID, we notice that the UUID was not read correctly.
I will investigate this further and submit a pull request with a fix.