...
1 package bgammon
2
3 type Command string
4
5 const (
6 CommandLogin = "login"
7 CommandLoginJSON = "loginjson"
8 CommandRegister = "register"
9 CommandRegisterJSON = "registerjson"
10 CommandResetPassword = "resetpassword"
11 CommandPassword = "password"
12 CommandSet = "set"
13 CommandReplay = "replay"
14 CommandHistory = "history"
15 CommandHelp = "help"
16 CommandJSON = "json"
17 CommandSay = "say"
18 CommandList = "list"
19 CommandCreate = "create"
20 CommandJoin = "join"
21 CommandLeave = "leave"
22 CommandDouble = "double"
23 CommandResign = "resign"
24 CommandRoll = "roll"
25 CommandMove = "move"
26 CommandReset = "reset"
27 CommandOk = "ok"
28 CommandRematch = "rematch"
29 CommandBoard = "board"
30 CommandPong = "pong"
31 CommandDisconnect = "disconnect"
32 )
33
34 type EventType string
35
36 const (
37 EventTypeWelcome = "welcome"
38 EventTypeHelp = "help"
39 EventTypePing = "ping"
40 EventTypeNotice = "notice"
41 EventTypeSay = "say"
42 EventTypeList = "list"
43 EventTypeJoined = "joined"
44 EventTypeFailedJoin = "failedjoin"
45 EventTypeLeft = "left"
46 EventTypeFailedLeave = "failedleave"
47 EventTypeBoard = "board"
48 EventTypeRolled = "rolled"
49 EventTypeFailedRoll = "failedroll"
50 EventTypeMoved = "moved"
51 EventTypeFailedMove = "failedmove"
52 EventTypeFailedOk = "failedok"
53 EventTypeWin = "win"
54 EventTypeSettings = "settings"
55 EventTypeReplay = "replay"
56 EventTypeHistory = "history"
57 )
58
View as plain text