datadef.go
7.71 KB
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
package logic
type UserLoginReq struct {
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type UserLoginData struct {
Walletgold int `json:"walletgold"`
Curji int `json:"curji"`
Curlevel int `json:"curlevel"`
Guanrednum int `json:"guanrednum"`
Jirednum int `json:"jirednum"`
Randnum int `json:"randnum"`
Speciallevel int `json:"speciallevel"`
Specialguannum int `json:"specialguannum"`
Tili int `json:"tili"`
}
type UserLoginResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data UserLoginData `json:"data"`
}
type GetuserdataReq struct {
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type GetuserdataData struct {
Walletgold int `json:"walletgold"`
Nowtime int `json:"nowtime"`
Curji int `json:"curji"`
Curlevel int `json:"curlevel"`
Guanrednum int `json:"guanrednum"`
Jirednum int `json:"jirednum"`
Randnum int `json:"randnum"`
Speciallevel int `json:"speciallevel"`
Specialguannum int `json:"specialguannum"`
}
type GetuserdataResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data GetuserdataData `json:"data"`
}
type CommReq struct {
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type QuerdrawinfoResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data WithDrawInfo `json:"data"`
}
type GetcashReq struct {
Gameid string `json:"gameid"`
Channel string `json:"channel"`
Money float32 `json:"money"`
Openid string `json:"openid"`
Nickname string `json:"nickname"`
Headurl string `json:"headurl"`
Ver string `json:"ver"`
Ctype int `json:"ctype"`
}
type GetcashData struct {
Walletgold int `json:"walletgold"`
}
type GetcashResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data GetcashData `json:"data"`
}
type WithDrawList struct {
Withdata []WithDrawRecord `json:"withdata"`
}
type GetcashrecordReq struct {
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type GetcashrecordResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data WithDrawList `json:"data"`
}
type UploadlevelReq struct {
Level int `json:"level"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type UploadlevelResp struct {
Code int `json:"code"`
Message string `json:"message"`
}
type UploadtiliReq struct {
Tili int `json:"tili"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type UploadtiliResp struct {
Code int `json:"code"`
Message string `json:"message"`
}
type FetchredbagReq struct {
Rtype int `json:"rtype"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
}
type FetchredbagData struct {
Guanrednum int `json:"guanrednum"`
Jirednum int `json:"jirednum"`
Randnum int `json:"randnum"`
Specialguannum int `json:"specialguannum"`
Getgold int `json:"getgold"`
Walletgold int `json:"walletgold"`
}
type FetchredbagResp struct {
Code int `json:"code"`
Message string `json:"message"`
Data FetchredbagData `json:"data"`
}
////////////////////////////////////////////////////////////////////////////////////////
type GetCashListResp struct {
Code string `json:"code"`
Msg string `json:"msg"`
Data []WithDrawRecord `json:"data"`
}
//提现记录结构
type WithDrawRecord struct {
Coin int `json:"coin"`
Create_time int `json:"create_time"`
Money int `json:"money"`
No string `json:"no"`
Status int `json:"status"`
Statusmsg string `json:"statusmsg"`
Typ int `json:"typ"`
}
type WithDrawDesc struct {
Cid int `json:"cid"`
Cnum float32 `json:"cnum"`
Isnew int `json:"isnew"`
Limitlv int `json:"limitlv"`
Preisfind int `json:"preisfind"`
Logindaylimit int `json:"logindaylimit"`
}
type WithDrawDescs []WithDrawDesc
func (v WithDrawDescs) Len() int {
return len(v)
}
func (v WithDrawDescs) Swap(i, j int) {
v[i], v[j] = v[j], v[i]
}
func (v WithDrawDescs) Less(i, j int) bool {
return v[i].Cid < v[j].Cid
}
type WithDrawInfo struct {
Logindaysum int `json:"logindaysum"`
Logindaycontinue int `json:"logindaycontinue"`
Cashdata WithDrawDescs `json:"cashdata"`
SpecialCashdata WithDrawDescs `json:"specialcashdata"`
}
//玩家数据
type UserData struct {
Userid int //玩家id
Lv int //玩家当前等级
LvRewardGet int //当前等级奖励是否已经领取 1未领取 2普通领取 3双倍领取
Exp int //玩家当前经验值
GuanGold int //玩家存钱罐中金币数量
RealGold int //玩家实际金币数量(可用于提现的)
WatchAddsTime int //当天剩余红包次数 初始化50次
LastLoginTime int //上次登陆时间
ContinueLoginDay int //连续登录天数
SumLoginDay int //累计登陆天数
GetFromGuanCnt int //当天从存钱款提取金币次数
SignRound int //签到轮数
SignSum int //累计签到天数
IsSignToday int //今日是否已经签到 1是 0否
LeftFreeRB int //剩余免费红包次数
UpLvCostTime int //上一个等级升级时间
UpLvCostTimeSec int //上一个等级升级的时间点时刻
PassLevel int //当前关卡
BigLevel int //当前等级
SpecialLevel int //特殊关卡
GuanRedNum int //关卡红包领取进度
JiRedNum int //等级红包领取进度
RandNum int //随机红包剩余次数
SpecialNum int //特殊关卡红包领取进度
Tili int //体力
ReadNum int //玩家微转发阅读量
GetCashCnt int //当天提现次数
WithDraw WithDrawInfo //提现记录信息
}
//----------------------------------------------------------------------------------------------------------------------
type TixianDesc struct {
Sign string `json:"sign"`
Sign_type string `json:"sign_type"`
Time_stamp string `json:"time_stamp"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
Uid int `json:"uid"`
Typ int `json:"typ"`
Money int `json:"money"`
Openid string `json:"openid"`
Nickname string `json:"nickname"`
Headurl string `json:"headurl"`
Editcoin int `json:"editcoin"`
Ver string `json:"ver"`
Checkcoin int `json:"checkcoin"`
}
type AddCoinDesc struct {
Sign string `json:"sign"`
Sign_type string `json:"sign_type"`
Time_stamp string `json:"time_stamp"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
Uid int `json:"uid"`
Coin int `json:"coin"`
Typ int `json:"typ"`
}
type AddCoinResultData struct {
Mycoin int `json:"mycoin"`
}
type AddCoinResp struct {
Code string `json:"code"`
Msg string `json:"msg"`
Data AddCoinResultData `json:"data"`
}
type GetCoinDesc struct {
Sign string `json:"sign"`
Sign_type string `json:"sign_type"`
Time_stamp string `json:"time_stamp"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
Uid int `json:"uid"`
}
type GetCashResp struct {
Code string `json:"code"`
Msg string `json:"msg"`
}
type GetCashListDesc struct {
Sign string `json:"sign"`
Sign_type string `json:"sign_type"`
Time_stamp string `json:"time_stamp"`
Gameid string `json:"gameid"`
Channel string `json:"channel"`
Uid int `json:"uid"`
Start int `json:"start"`
Number int `json:"number"`
}