protocol

package
v1.0.58 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Package protocol implements the MatchmakeExtensionMonsterHunterXX protocol

Index

Constants

View Source
const (
	// ProtocolID is the Protocol ID for the Matchmake Extension (Monster Hunter XX) protocol
	ProtocolID = 0x6D

	// MethodUpdateFriendUserProfile is the method ID for the UpdateFriendUserProfile method
	MethodUpdateFriendUserProfile = 0x36

	// MethodGetFriendUserProfiles is the method ID for the GetFriendUserProfiles method
	MethodGetFriendUserProfiles = 0x37

	// MethodAddFriends is the method ID for the AddFriends method
	MethodAddFriends = 0x39

	// MethodRemoveFriend is the method ID for the RemoveFriend method
	MethodRemoveFriend = 0x3A

	// MethodFindCommunityByOwner is the method ID for the FindCommunityByOwner method
	MethodFindCommunityByOwner = 0x3B
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Protocol

type Protocol struct {
	Server *nex.Server
	// contains filtered or unexported fields
}

Protocol stores all the RMC method handlers for the Matchmake Extension (Monster Hunter XX) protocol and listens for requests Embeds the Matchmake Extension protocol

func NewProtocol

func NewProtocol(server *nex.Server) *Protocol

NewProtocol returns a new MatchmakeExtensionMonsterHunterXX protocol

func (*Protocol) AddFriends

func (protocol *Protocol) AddFriends(handler func(err error, packet nex.PacketInterface, callID uint32, pids []uint64) uint32)

AddFriends sets the AddFriends handler function

func (*Protocol) FindCommunityByOwner

func (protocol *Protocol) FindCommunityByOwner(handler func(err error, packet nex.PacketInterface, callID uint32, id uint64, resultRange *nex.ResultRange) uint32)

FindCommunityByOwner sets the FindCommunityByOwner handler function

func (*Protocol) GetFriendUserProfiles

func (protocol *Protocol) GetFriendUserProfiles(handler func(err error, packet nex.PacketInterface, callID uint32, pids []uint64) uint32)

GetFriendUserProfiles sets the GetFriendUserProfiles handler function

func (*Protocol) HandlePacket

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

HandlePacket sends the packet to the correct RMC method handler

func (*Protocol) RemoveFriend

func (protocol *Protocol) RemoveFriend(handler func(err error, packet nex.PacketInterface, callID uint32, pid uint64) uint32)

RemoveFriend sets the RemoveFriend handler function

func (*Protocol) Setup

func (protocol *Protocol) Setup()

Setup initializes the protocol

func (*Protocol) UpdateFriendUserProfile

func (protocol *Protocol) UpdateFriendUserProfile(handler func(err error, packet nex.PacketInterface, callID uint32, param *matchmake_extension_monster_hunter_xx_types.FriendUserParam) uint32)

UpdateFriendUserProfile sets the UpdateFriendUserProfile handler function

Directories

Path Synopsis
Package types implements all the types used by the Matchmake Extension (Monster Hunter XX) protocol
Package types implements all the types used by the Matchmake Extension (Monster Hunter XX) protocol

Jump to

Keyboard shortcuts

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