Skip to content

Commit

Permalink
protocol/bitset.go: Rename usages of Test() to Load()
Browse files Browse the repository at this point in the history
  • Loading branch information
TwistedAsylumMC committed Nov 25, 2024
1 parent 64ce0e3 commit af2083f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions minecraft/protocol/packet/player_auth_input.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,19 +178,19 @@ func (pk *PlayerAuthInput) Marshal(io protocol.IO) {
io.Varuint64(&pk.Tick)
io.Vec3(&pk.Delta)

if pk.InputData.Test(InputFlagPerformItemInteraction) {
if pk.InputData.Load(InputFlagPerformItemInteraction) {
io.PlayerInventoryAction(&pk.ItemInteractionData)
}

if pk.InputData.Test(InputFlagPerformItemStackRequest) {
if pk.InputData.Load(InputFlagPerformItemStackRequest) {
protocol.Single(io, &pk.ItemStackRequest)
}

if pk.InputData.Test(InputFlagPerformBlockActions) {
if pk.InputData.Load(InputFlagPerformBlockActions) {
protocol.SliceVarint32Length(io, &pk.BlockActions)
}

if pk.InputData.Test(InputFlagClientPredictedVehicle) {
if pk.InputData.Load(InputFlagClientPredictedVehicle) {
io.Vec2(&pk.VehicleRotation)
io.Varint64(&pk.ClientPredictedVehicle)
}
Expand Down

0 comments on commit af2083f

Please sign in to comment.