protocol

package
v2.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package protocol implements the RankingMarioKart8 protocol

Package protocol implements the RankingMarioKart8 protocol

Package protocol implements the RankingMarioKart8 protocol

Package protocol implements the RankingMarioKart8 protocol

Index

Constants

View Source
const (
	// ProtocolID is the Protocol ID for the Ranking (Mario Kart 8) protocol
	ProtocolID = 0x70

	// MethodGetCompetitionRankingScore is the method ID for the GetCompetitionRankingScore method
	MethodGetCompetitionRankingScore = 0xE

	// MethodUploadCompetitionRankingScore is the method ID for the UploadCompetitionRankingScore method
	MethodUploadCompetitionRankingScore = 0xF

	// MethodGetCompetitionInfo is the method ID for the GetCompetitionInfo method
	MethodGetCompetitionInfo = 0x10
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Protocol

type Protocol struct {
	GetCompetitionRankingScore    func(err error, packet nex.PacketInterface, callID uint32, packetPayload []byte) (*nex.RMCMessage, *nex.Error)
	UploadCompetitionRankingScore func(err error, packet nex.PacketInterface, callID uint32, param *ranking_mario_kart8_types.CompetitionRankingUploadScoreParam) (*nex.RMCMessage, *nex.Error)
	GetCompetitionInfo            func(err error, packet nex.PacketInterface, callID uint32, param *ranking_mario_kart8_types.CompetitionRankingInfoGetParam) (*nex.RMCMessage, *nex.Error)
	// contains filtered or unexported fields
}

Protocol stores all the RMC method handlers for the Ranking (Mario Kart 8) protocol and listens for requests Embeds the Ranking protocol

func NewProtocol

func NewProtocol(endpoint nex.EndpointInterface) *Protocol

NewProtocol returns a new RankingMarioKart8 protocol

func (*Protocol) HandlePacket

func (protocol *Protocol) HandlePacket(packet nex.PacketInterface)

HandlePacket sends the packet to the correct RMC method handler

Directories

Path Synopsis
Package types implements all the types used by the Ranking protocol
Package types implements all the types used by the Ranking protocol

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL