dispatcherclient

package
Version: v0.1.3 Latest Latest
Warning

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

Go to latest
Published: May 30, 2018 License: Apache-2.0 Imports: 13 Imported by: 70

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DispatcherClient

type DispatcherClient struct {
	*proto.GoWorldConnection
	// contains filtered or unexported fields
}

DispatcherClient is a client connection to the dispatcher

func (*DispatcherClient) Close

func (dc *DispatcherClient) Close() error

Close the dispatcher client

type DispatcherClientType

type DispatcherClientType int
const (
	GameDispatcherClientType DispatcherClientType = 1 + iota
	GateDispatcherClientType
)

type DispatcherConnMgr

type DispatcherConnMgr struct {
	// contains filtered or unexported fields
}

func NewDispatcherConnMgr

func NewDispatcherConnMgr(gid uint16, dctype DispatcherClientType, dispid uint16, isRestoreGame, isBanBootEntity bool, delegate IDispatcherClientDelegate) *DispatcherConnMgr

func (*DispatcherConnMgr) Connect

func (dcm *DispatcherConnMgr) Connect()

Initialize the dispatcher client, only called by engine

func (*DispatcherConnMgr) GetDispatcherClientForSend

func (dcm *DispatcherConnMgr) GetDispatcherClientForSend() *DispatcherClient

GetDispatcherClientForSend returns the current dispatcher client for sending messages

func (*DispatcherConnMgr) String

func (dcm *DispatcherConnMgr) String() string

type IDispatcherClientDelegate

type IDispatcherClientDelegate interface {
	HandleDispatcherClientPacket(msgtype proto.MsgType, packet *netutil.Packet)
	HandleDispatcherClientDisconnect()
}

IDispatcherClientDelegate defines functions that should be implemented by dispatcher clients

Jump to

Keyboard shortcuts

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