MCPcopy Create free account
hub / github.com/ZeppelinMC/Zeppelin / Encode

Method Encode

protocol/net/packet/play/setPlayerRotation.go:19–27  ·  view source on GitHub ↗
(w encoding.Writer)

Source from the content-addressed store, hash-verified

17}
18
19func (s *SetPlayerRotation) Encode(w encoding.Writer) error {
20 if err := w.Float(s.Yaw); err != nil {
21 return err
22 }
23 if err := w.Float(s.Pitch); err != nil {
24 return err
25 }
26 return w.Bool(s.OnGround)
27}
28
29func (s *SetPlayerRotation) Decode(r encoding.Reader) error {
30 if err := r.Float(&s.Yaw); err != nil {

Callers

nothing calls this directly

Calls 2

FloatMethod · 0.45
BoolMethod · 0.45

Tested by

no test coverage detected