service

package
v0.0.0-...-620f6c9 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetSesionFromContext

func GetSesionFromContext(c context.Context) *Session

Types

type ATGClient

type ATGClient struct {
}

func (*ATGClient) CreateSession

func (c *ATGClient) CreateSession(ctx context.Context, in *SessionInfo, opts ...grpc.CallOption) (*Success, error)

func (*ATGClient) GetGameServerInfo

func (c *ATGClient) GetGameServerInfo(ctx context.Context, in *SessionKey, opts ...grpc.CallOption) (*ServerInfo, error)

func (*ATGClient) GetRoomList

func (c *ATGClient) GetRoomList(ctx context.Context, in *SessionKey, opts ...grpc.CallOption) (*RoomList, error)

type ATGServer

type ATGServer struct {
}

func (*ATGServer) CreateSession

func (s *ATGServer) CreateSession(context.Context, *SessionInfo) (*Success, error)

func (*ATGServer) GetGameServerInfo

func (s *ATGServer) GetGameServerInfo(context.Context, *SessionKey) (*ServerInfo, error)

func (*ATGServer) GetRoomList

func (s *ATGServer) GetRoomList(context.Context, *SessionKey) (*RoomList, error)

type Agent

type Agent struct {
	Uuid int64
}

func NewAgentRpc

func NewAgentRpc() (agent *Agent)

func (*Agent) AquireGameServer

func (a *Agent) AquireGameServer(context.Context, *Empty) (*ServerInfo, error)

allocate room

func (*Agent) AquireOtherAgent

func (a *Agent) AquireOtherAgent(c context.Context, e *Empty) (*ServerInfo, error)

func (*Agent) AquireSessionKey

func (a *Agent) AquireSessionKey(c context.Context, e *Empty) (*SessionKey, error)

func (*Agent) CreateAccount

func (a *Agent) CreateAccount(context.Context, *RegistInput) (*Error, error)

func (*Agent) CreateRoom

func (a *Agent) CreateRoom(context.Context, *RoomSetting) (*Success, error)

func (*Agent) Init

func (a *Agent) Init()

func (*Agent) JoinRoom

func (a *Agent) JoinRoom(context.Context, *ID) (*Success, error)

func (*Agent) Login

func (a *Agent) Login(c context.Context, in *LoginInput) (*UserInfo, error)

func (*Agent) Pipe

func (a *Agent) Pipe(ClientToAgent_PipeServer) error

rpc UpdateRoomInfo(SessionKey) returns (stream RoomInfoView) {}

func (*Agent) RoomReady

func (a *Agent) RoomReady(context.Context, *Empty) (*Success, error)

func (*Agent) SetAccount

func (a *Agent) SetAccount(context.Context, *AttrSetting) (*Success, error)

UserSetting

func (*Agent) SetCharacter

func (a *Agent) SetCharacter(context.Context, *AttrSetting) (*Success, error)

func (*Agent) UpdateHome

func (a *Agent) UpdateHome(*Empty, ClientToAgent_UpdateHomeServer) error

View

func (*Agent) UpdateRoomList

func (a *Agent) UpdateRoomList(*Empty, ClientToAgent_UpdateRoomListServer) error

func (*Agent) UpdateUserList

func (a *Agent) UpdateUserList(*Empty, ClientToAgent_UpdateUserListServer) error

type CTGServer

type CTGServer struct {
}

func (*CTGServer) EnterRoom

func (s *CTGServer) EnterRoom(context.Context, *ServerInfo) (*Success, error)

func (*CTGServer) LeaveRoom

func (s *CTGServer) LeaveRoom(context.Context, *Empty) (*Success, error)

func (*CTGServer) PlayerInput

func (s *CTGServer) PlayerInput(ClientToGame_PlayerInputServer) error

entityManager

func (*CTGServer) UpdateGameFrame

func (s *CTGServer) UpdateGameFrame(*Empty, ClientToGame_UpdateGameFrameServer) error

func (*CTGServer) UpdateRoomPrepareView

func (s *CTGServer) UpdateRoomPrepareView(*Empty, ClientToGame_UpdateRoomPrepareViewServer) error

View

Jump to

Keyboard shortcuts

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