From d96a9401441c39ee2dd2bf6aa86575a3559471b0 Mon Sep 17 00:00:00 2001 From: Smell of curry <75345244+smell-of-curry@users.noreply.github.com> Date: Sun, 4 Aug 2024 12:49:50 -0700 Subject: [PATCH] packet/player_auth_input.go: Fix marshal order (#256) --- minecraft/protocol/packet/player_auth_input.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/minecraft/protocol/packet/player_auth_input.go b/minecraft/protocol/packet/player_auth_input.go index b70fec1b..ae4c210a 100644 --- a/minecraft/protocol/packet/player_auth_input.go +++ b/minecraft/protocol/packet/player_auth_input.go @@ -161,15 +161,15 @@ func (pk *PlayerAuthInput) Marshal(io protocol.IO) { if pk.InputData&InputFlagPerformItemStackRequest != 0 { protocol.Single(io, &pk.ItemStackRequest) } - + + if pk.InputData&InputFlagPerformBlockActions != 0 { + protocol.SliceVarint32Length(io, &pk.BlockActions) + } + if pk.InputData&InputFlagClientPredictedVehicle != 0 { io.Vec2(&pk.VehicleRotation) io.Varint64(&pk.ClientPredictedVehicle) } - if pk.InputData&InputFlagPerformBlockActions != 0 { - protocol.SliceVarint32Length(io, &pk.BlockActions) - } - io.Vec2(&pk.AnalogueMoveVector) }