Documentation
¶
Overview ¶
Code generated by GopherMc/generator. DO NOT EDIT. See generator/main.go for more details.
Code generated by GopherMc/generator. DO NOT EDIT. See generator/main.go for more details.
Index ¶
- Constants
- Variables
- func GetPacketID(v Version, s State, d Direction, p Packet) (int32, bool)
- func OfflineUUID(username string) uuid.UUID
- func ReadBool(r io.Reader) (bool, error)
- func ReadByte(r io.Reader) (byte, error)
- func ReadBytes(r io.Reader) ([]byte, error)
- func ReadLong(r io.Reader) (int64, error)
- func ReadString(r io.Reader) (string, error)
- func ReadStringUUID(r io.Reader) (uuid.UUID, error)
- func ReadUShort(r io.Reader) (uint16, error)
- func ReadUUID(r io.Reader) (uuid.UUID, error)
- func ReadVarInt(r io.Reader) (int32, error)
- func WriteBool(w io.Writer, v bool) error
- func WriteByte(w io.Writer, b byte) error
- func WriteByteSlice(w io.Writer, data []byte) error
- func WriteLong(w io.Writer, v int64) error
- func WriteString(w io.Writer, value string) error
- func WriteUShort(w io.Writer, v uint16) error
- func WriteVarInt(w io.Writer, value int32) error
- type ClientSettings
- type ClientboundChatMessage
- type ClientboundConfigKeepAlive
- type ClientboundConfigPing
- type ClientboundCookieRequest
- type ClientboundCustomPayload
- type ClientboundDisconnect
- type ClientboundFeatureFlags
- type ClientboundFinishConfiguration
- type ClientboundJoinGame
- type ClientboundKeepAlive
- type ClientboundLoginSuccess
- type ClientboundPong
- type ClientboundRegistryData
- type ClientboundSelectKnownPacks
- type ClientboundSetCompression
- type ClientboundStatusResponse
- type ClientboundUpdateTags
- type Conn
- type CustomPayload
- type CustomPayloadData
- type Definition
- type Direction
- type KnownPack
- type Packet
- type PacketFactory
- type PlayerPosition
- type RegistryTag
- type ServerboundChatMessage
- type ServerboundClientSettings
- type ServerboundConfigKeepAlive
- type ServerboundConfigPong
- type ServerboundCookieResponse
- type ServerboundCustomPayload
- type ServerboundFinishConfiguration
- type ServerboundHandshake
- type ServerboundKeepAlive
- type ServerboundLoginAcknowledged
- type ServerboundLoginStart
- type ServerboundPing
- type ServerboundPlayerPosition
- type ServerboundSelectKnownPacks
- type ServerboundStatusRequest
- type State
- type Tag
- type Version
Constants ¶
View Source
const ( MaxVarIntSize = 5 MaxPacketDataSize = 2097152 )
View Source
const First = V1_7
View Source
const Latest = V1_21_9
Variables ¶
View Source
var ErrUnknownPacket = errors.New("unknown packet")
View Source
var (
Versions []Version
)
Functions ¶
func OfflineUUID ¶
Types ¶
type ClientSettings ¶
type ClientboundChatMessage ¶
type ClientboundChatMessage struct {
Component component.ChatComponent
Sender string
}
type ClientboundConfigKeepAlive ¶
type ClientboundConfigKeepAlive struct{ ID int64 }
type ClientboundConfigPing ¶
type ClientboundConfigPing struct{ ID int32 }
type ClientboundCookieRequest ¶
type ClientboundCookieRequest struct {
Key string
}
type ClientboundCustomPayload ¶
type ClientboundCustomPayload struct{ CustomPayloadData }
type ClientboundDisconnect ¶
type ClientboundDisconnect struct{ Reason string }
type ClientboundFeatureFlags ¶
type ClientboundFeatureFlags struct {
Features []string
}
type ClientboundFinishConfiguration ¶
type ClientboundFinishConfiguration struct{}
type ClientboundJoinGame ¶
type ClientboundJoinGame struct{}
type ClientboundKeepAlive ¶
type ClientboundKeepAlive struct{ ID int64 }
type ClientboundLoginSuccess ¶
type ClientboundPong ¶
type ClientboundPong struct{ Payload int64 }
type ClientboundRegistryData ¶
type ClientboundSelectKnownPacks ¶
type ClientboundSelectKnownPacks struct {
Packs []KnownPack
}
type ClientboundSetCompression ¶
type ClientboundSetCompression struct{ Threshold int32 }
type ClientboundStatusResponse ¶
type ClientboundStatusResponse struct{ JSONResponse string }
type ClientboundUpdateTags ¶
type ClientboundUpdateTags struct {
Tags []RegistryTag
}
type CustomPayload ¶
type CustomPayloadData ¶
type Definition ¶
type Definition struct {
ProtocolVersion int32
PacketNames map[State]map[Direction]map[int32]string
PacketIDs map[State]map[Direction]map[string]int32
}
func GetDefinition ¶
func GetDefinition(v Version) *Definition
type PacketFactory ¶
type PacketFactory func() Packet
type PlayerPosition ¶
type RegistryTag ¶
type ServerboundChatMessage ¶
type ServerboundChatMessage struct {
Message string
PrivateKey *rsa.PrivateKey
UUID uuid.UUID
}
type ServerboundClientSettings ¶
type ServerboundClientSettings struct {
ClientSettings
}
type ServerboundConfigKeepAlive ¶
type ServerboundConfigKeepAlive struct{ ID int64 }
type ServerboundConfigPong ¶
type ServerboundConfigPong struct{ ID int32 }
type ServerboundCookieResponse ¶
type ServerboundCustomPayload ¶
type ServerboundCustomPayload struct{ CustomPayloadData }
type ServerboundFinishConfiguration ¶
type ServerboundFinishConfiguration struct{}
type ServerboundHandshake ¶
type ServerboundHandshake struct {
ProtocolVersion int32
ServerAddress string
ServerPort uint16
NextState State
}
type ServerboundKeepAlive ¶
type ServerboundKeepAlive struct{ ID int64 }
type ServerboundLoginAcknowledged ¶
type ServerboundLoginAcknowledged struct{}
type ServerboundLoginStart ¶
type ServerboundPing ¶
type ServerboundPing struct{ Payload int64 }
type ServerboundPlayerPosition ¶
type ServerboundSelectKnownPacks ¶
type ServerboundSelectKnownPacks struct {
Packs []KnownPack
}
type ServerboundStatusRequest ¶
type ServerboundStatusRequest struct{}
type Version ¶
type Version int
const ( V1_7 Version = iota V1_8 Version = iota V1_9 Version = iota V1_9_2 Version = iota V1_9_4 Version = iota V1_10 Version = iota V1_11 Version = iota V1_12 Version = iota V1_12_1 Version = iota V1_12_2 Version = iota V1_13 Version = iota V1_13_1 Version = iota V1_13_2 Version = iota V1_14 Version = iota V1_14_1 Version = iota V1_14_3 Version = iota V1_14_4 Version = iota V1_15 Version = iota V1_15_1 Version = iota V1_15_2 Version = iota V1_16 Version = iota V1_16_1 Version = iota V1_16_2 Version = iota V1_17 Version = iota V1_17_1 Version = iota V1_18 Version = iota V1_18_2 Version = iota V1_19 Version = iota V1_19_2 Version = iota V1_19_3 Version = iota V1_19_4 Version = iota V1_20 Version = iota V1_20_2 Version = iota V1_20_3 Version = iota V1_20_5 Version = iota V1_21_1 Version = iota V1_21_3 Version = iota V1_21_4 Version = iota V1_21_5 Version = iota V1_21_6 Version = iota V1_21_8 Version = iota V1_21_9 Version = iota )
func VersionFromString ¶
Click to show internal directories.
Click to hide internal directories.