forked from hugolgst/rich-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
types.go
49 lines (41 loc) 路 1.18 KB
/
types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package client
type Handshake struct {
V string `json:"v"`
ClientId string `json:"client_id"`
}
type Frame struct {
Cmd string `json:"cmd"`
Args Args `json:"args"`
Nonce string `json:"nonce"`
}
type Args struct {
Pid int `json:"pid"`
Activity *PayloadActivity `json:"activity"`
}
type PayloadActivity struct {
Details string `json:"details"`
State string `json:"state"`
Assets PayloadAssets `json:"assets"`
Party *PayloadParty `json:"party,omitempty"`
Timestamps *PayloadTimestamps `json:"timestamps,omitempty"`
Secrets *PayloadSecrets `json:"secrets,omitempty"`
}
type PayloadAssets struct {
LargeImage string `json:"large_image"`
LargeText string `json:"large_text"`
SmallImage string `json:"small_image"`
SmallText string `json:"small_text"`
}
type PayloadParty struct {
ID string `json:"id"`
Size [2]int `json:"size"`
}
type PayloadTimestamps struct {
Start *uint64 `json:"start,omitempty"`
End *uint64 `json:"end,omitempty"`
}
type PayloadSecrets struct {
Match string `json:"match,omitempty"`
Join string `json:"join,omitempty"`
Spectate string `json:"spectate,omitempty"`
}