Archer

Game Action Basics

Notes

Note
To use this package, you need to enable 【Auto Settings】-> 【Built-in Mode】.

Package Name

  • actions

Import

  • import "github.com/moxcomic/Archer/internal/platform/actions"

Interface Methods

NameParametersReturn ValueNotes
NewMajsoulActionsNone*actions.MajsoulMajsoul interface instance

Instance Methods

NameParametersReturn ValueNotes
JoinroomId: int, roomType: intNoneStart matchmaking, roomType is always 0
ReJoinNoneNoneDeprecated
CancelJoinNoneNoneCancel matchmaking
ConfirmNoneNoneDeprecated
BackToHomeNoneNoneDeprecated
HuansanzhangNoneNoneSwap three tiles, only available in this mode
BabeiNoneNoneExecute Babei
Discardtile: string, tsumogiri: boolNoneDiscard a tile, tile is the tile name, tsumogiri indicates if it's the last drawn tile
Riichitile: string, tsumogiri: boolNoneDeclare Riichi, tile is the tile name, tsumogiri indicates if it's the last drawn tile
Chiitile0: string, tile1: stringNoneChii, tile0 and tile1 are the tiles to use for Chii
Pontile0: string, tile1: stringNonePon, tile0 and tile1 are the tiles to use for Pon
Daimingkantile: stringNoneDaimingkan, tile is the tile name
Kakantile: stringNoneKakan, tile is the tile name
Ankantile: stringNoneAnkan, tile is the tile name
RyukyokuNoneNoneNine Terminal Tiles
TsumoNoneNoneTsumo (Self-draw win)
RonNoneNoneRon (Win by discard)
CancelNoneNoneCancel or skip
ComeBackNoneNone"I'm back", called when a player is detected as leaving

Example Code

go
actions.NewMajsoulActions().Discard("1m", true)