Documentation
¶
Index ¶
- func ColorFromBytes(data io.Reader, input *Color) error
- func GetPackedSize(msgList []Message) int
- func PackMessages(msgList []Message, data io.Writer)
- func SpectrumFromBytes(data io.Reader, input *Spectrum) error
- type CharacterClass
- type CharacterJoinedTeam
- type Color
- type Message
- type MessageType
- type NewCharacterMessage
- type Spectrum
- type TeamRole
- type Vector3Message
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPackedSize ¶ added in v0.3.0
func PackMessages ¶ added in v0.3.0
Types ¶
type CharacterClass ¶ added in v0.2.0
type CharacterClass byte
const ( CharacterClassFighter CharacterClass = 0 CharacterClassWizard CharacterClass = 1 CharacterClassRogue CharacterClass = 2 CharacterClassCleric CharacterClass = 3 )
type CharacterJoinedTeam ¶
type CharacterJoinedTeam struct { CharacterID uint64 TeamName string TeamColors []Color Role TeamRole }
func CharacterJoinedTeamFromBytes ¶
func CharacterJoinedTeamFromBytes(data io.Reader) (*CharacterJoinedTeam, error)
func NewCharacterJoinedTeamDefault ¶ added in v0.2.0
func NewCharacterJoinedTeamDefault() CharacterJoinedTeam
func (CharacterJoinedTeam) GetMessageType ¶
func (output CharacterJoinedTeam) GetMessageType() MessageType
func (CharacterJoinedTeam) GetSizeInBytes ¶
func (output CharacterJoinedTeam) GetSizeInBytes() int
func (CharacterJoinedTeam) WriteBytes ¶
func (output CharacterJoinedTeam) WriteBytes(data io.Writer, tag bool)
type Color ¶
func NewColorDefault ¶ added in v0.2.0
func NewColorDefault() Color
func (Color) WriteBytes ¶
type Message ¶
type Message interface { GetMessageType() MessageType WriteBytes(data io.Writer, tag bool) GetSizeInBytes() int }
type MessageType ¶
type MessageType byte
const ( Vector3MessageType MessageType = 1 NewCharacterMessageType MessageType = 2 CharacterJoinedTeamType MessageType = 3 )
type NewCharacterMessage ¶
type NewCharacterMessage struct { Id uint64 CharacterName string Job CharacterClass Strength uint16 Intelligence uint16 Dexterity uint16 Wisdom uint16 GoldInWallet uint32 Nicknames []string }
func NewCharacterMessageFromBytes ¶
func NewCharacterMessageFromBytes(data io.Reader) (*NewCharacterMessage, error)
func NewNewCharacterMessageDefault ¶ added in v0.2.0
func NewNewCharacterMessageDefault() NewCharacterMessage
func (NewCharacterMessage) GetMessageType ¶
func (output NewCharacterMessage) GetMessageType() MessageType
func (NewCharacterMessage) GetSizeInBytes ¶
func (output NewCharacterMessage) GetSizeInBytes() int
func (NewCharacterMessage) WriteBytes ¶
func (output NewCharacterMessage) WriteBytes(data io.Writer, tag bool)
type Spectrum ¶
func NewSpectrumDefault ¶ added in v0.2.0
func NewSpectrumDefault() Spectrum
func (Spectrum) WriteBytes ¶
type Vector3Message ¶
func NewVector3MessageDefault ¶ added in v0.2.0
func NewVector3MessageDefault() Vector3Message
func Vector3MessageFromBytes ¶
func Vector3MessageFromBytes(data io.Reader) (*Vector3Message, error)
func (Vector3Message) GetMessageType ¶
func (output Vector3Message) GetMessageType() MessageType
func (Vector3Message) GetSizeInBytes ¶
func (output Vector3Message) GetSizeInBytes() int
func (Vector3Message) WriteBytes ¶
func (output Vector3Message) WriteBytes(data io.Writer, tag bool)
Click to show internal directories.
Click to hide internal directories.