Add support for protocol version 1.21.100 (#12)

This commit is contained in:
Akmal Fairuz
2025-08-13 21:37:46 +07:00
committed by GitHub
parent d3fae5d3be
commit d9d8b0bc75
50 changed files with 9667 additions and 135 deletions

View File

@@ -18,6 +18,8 @@ type CameraInstruction struct {
Target protocol.Optional[protocol.CameraInstructionTarget]
// RemoveTarget can be set to true to remove the current aim assist target.
RemoveTarget protocol.Optional[bool]
// FieldOfView is a camera instruction that updates the field of view for the camera.
FieldOfView protocol.Optional[protocol.CameraInstructionFieldOfView]
}
// ID ...
@@ -33,4 +35,7 @@ func (pk *CameraInstruction) Marshal(io protocol.IO) {
protocol.OptionalMarshaler(io, &pk.Target)
protocol.OptionalFunc(io, &pk.RemoveTarget, io.Bool)
}
if proto.IsProtoGTE(io, proto.ID827) {
protocol.OptionalMarshaler(io, &pk.FieldOfView)
}
}