v1

package
v0.0.0-...-0f11903 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MahjongClient

type MahjongClient struct {
	Client      pb.MahjongClient
	ReadyStream pb.Mahjong_ReadyClient
	StartStream pb.Mahjong_StartClient

	Delay time.Duration
	Ctx   context.Context

	P *player.Player

	RoomList []*room.Room
	Room     *room.Room
}

func NewMahjongClient

func NewMahjongClient(ctx context.Context, playerName string, grpcClient pb.MahjongClient) *MahjongClient

func (*MahjongClient) CreateRoom

func (c *MahjongClient) CreateRoom(roomName string) error

func (*MahjongClient) JoinRoom

func (c *MahjongClient) JoinRoom(roomId string) error

func (*MahjongClient) Login

func (c *MahjongClient) Login() error

func (*MahjongClient) Logout

func (c *MahjongClient) Logout() error

func (*MahjongClient) Ping

func (c *MahjongClient) Ping() error

func (*MahjongClient) Ready

func (c *MahjongClient) Ready() error

func (*MahjongClient) RefreshRoom

func (c *MahjongClient) RefreshRoom(roomName string) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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