struct updates

This commit is contained in:
Pin
2023-03-17 22:22:06 -04:00
parent a3fab879a0
commit 4ccd7de4b5

17
server/structs/saprus.go Normal file
View File

@@ -0,0 +1,17 @@
package structs
import (
)
type SaprusHeaderFrame struct {
PacketType uint16
Length uint16
Payload []byte
}
func (c SaprusHeaderFrame) Bytes() []byte {
data := []byte{byte(c.PacketType), byte(c.Length)}
data = append(data, c.Payload...)
return data
}