行会红包 » 历史记录 » 版本 27
chenjun, 2022-06-04 18:32
1 | 1 | chenjun | h4. %{color:green}行会红包% |
---|---|---|---|
2 | |||
3 | 27 | chenjun | |
4 | 标签:模块示例|行会红包 |
||
5 | |||
6 | |||
7 | *模块说明* |
||
8 | 1 | chenjun | 玩家可以在行会中发红包给行会成员,也可以收取其他成员发放的红包 |
9 | 27 | chenjun | |
10 | 行会红包的发放和领取与微信红包的规则类似,主要有以下几点: |
||
11 | * 发出的红包有总金额和领取个数,单个领取金额随机,个数领完该红包消失,无法继续领取 |
||
12 | * 每个行会红包每人只能领取一次 |
||
13 | * 红包发出超过24小时,未被领取的金额将退还给发红包的人 |
||
14 | 1 | chenjun | |
15 | - |
||
16 | - |
||
17 | |||
18 | h4. *%{color:deepskyblue}特戒引擎脚本示例:%* |
||
19 | |||
20 | - |
||
21 | - |
||
22 | |||
23 | 26 | chenjun | bq. %{color:lightGrey};..\Mir200\Envir\QuestDiary\行会红包\行会红包.txt% |
24 | [<notextile>@</notextile>main] |
||
25 | 2 | chenjun | %{color:lightGrey};行会红包UI显示处理% |
26 | 15 | chenjun | #if |
27 | 2 | chenjun | #act |
28 | openMerchantBigDlg lc_chuangti 4 0 0 1 0 0 |
||
29 | 3 | chenjun | goto <notextile>@</notextile>生成红包列表 |
30 | goto <notextile>@</notextile>红包数据 |
||
31 | 2 | chenjun | #say |
32 | <panelsize:1440:900>\ |
||
33 | <Img:lc_quyufenge_01:255:95:1>\ |
||
34 | <Img:lc_quyufenge_02:270:760:1>\ |
||
35 | <text:灵符:<$gameGird>{scolor=250}:1100:840> \ |
||
36 | 3 | chenjun | <ImgButton:lc_anniuhui_4zi_da:1300:820:去发红包/<notextile>@</notextile>去发红包>\ |
37 | 2 | chenjun | %{color:lightGrey};创建领取红包列表界面% |
38 | 15 | chenjun | <notextile><</notextile>*{color:green}[[dlg_itemGrid_|itemGrid]]*:GridName,0,0,1:260:80:310,410:1,4,652,1:0>\ |
39 | 1 | chenjun | |
40 | |
||
41 | 15 | chenjun | [<notextile>@</notextile>去发红包] |
42 | #if |
||
43 | #act |
||
44 | mov n$发红包金额显示值 1000 |
||
45 | mov n$发红包数量显示值 10 |
||
46 | goto <notextile>@</notextile>设置红包 |
||
47 | |
||
48 | |
||
49 | [<notextile>@</notextile>设置红包] |
||
50 | #if |
||
51 | #act |
||
52 | openMerchantBigDlg lc_chuangti 4 0 0 1 0 0 |
||
53 | #say |
||
54 | %{color:lightGrey};红包展示% |
||
55 | <Img:lc_hongbao_03:123:225:1:1.5> |
||
56 | <text:<$userName>的红包{scolor=151}:200:240> \ |
||
57 | <text:恭喜发财,大吉大利{scolor=151}:128:374> \ |
||
58 | <text:发放金额:{scolor=161}:500:230> \ |
||
59 | <img:huatiao01:832:222:1:1> |
||
60 | %{color:lightGrey};红包金额输入框% |
||
61 | 22 | chenjun | <notextile><</notextile>*{color:green}[[dlg_Input_|Input]]*:1:1:<$str(n$发红包金额显示值)>:161:400:40:161:30:6:921:237/<notextile>@</notextile>endInput1> \ |
62 | 16 | chenjun | |
63 | 15 | chenjun | <text:今日可发<$str(u$今日剩余可发灵符)>灵符{scolor=160}:803:317> \ |
64 | <ImgButton:lc_shangcheng_jh_anniu:772:224:/<notextile>@</notextile>发放金额减>\ |
||
65 | <ImgButton:lc_shangcheng_jiahao_anniu:1074:224:/<notextile>@</notextile>发放金额加>\ |
||
66 | <text:红包数量:{scolor=161}:500:480> \ |
||
67 | <img:huatiao01:832:474:1:1> |
||
68 | %{color:lightGrey};红包数量输入框% |
||
69 | 22 | chenjun | <notextile><</notextile>*{color:green}[[dlg_Input_|Input]]*:2:1:<$str(n$发红包数量显示值)>:161:400:40:161:30:4:931:487/<notextile>@</notextile>endInput2> \ |
70 | 15 | chenjun | <ImgButton:lc_shangcheng_jh_anniu:772:476:/<notextile>@</notextile>红包数量减>\ |
71 | <ImgButton:lc_shangcheng_jiahao_anniu:1074:476:/<notextile>@</notextile>红包数量加>\ |
||
72 | <text:祝福语:{scolor=161}:500:700> \ |
||
73 | <text:恭喜发财,大吉大利{scolor=161}:692:700> \ |
||
74 | <text:注:未领取的红包将于24小时后退还{scolor=250}:100:850> \ |
||
75 | <ImgButton:lc_anniuhui_4zi_da:1200:820:发送/<notextile>@</notextile>submitinput>\ |
||
76 | |
||
77 | |
||
78 | [<notextile>@</notextile>endInput1] |
||
79 | %{color:lightGrey};触发编辑结束,如未输入红包金额,会返回一个空字符% |
||
80 | #act |
||
81 | mov n$新红包金额 <$str(s1)> |
||
82 | |
||
83 | #if |
||
84 | not equal s1 |
||
85 | small n$新红包金额 n$发红包金额显示值 |
||
86 | #act |
||
87 | sendtipsmsg 红包金额最少需要1000灵符 |
||
88 | mov s1 1000 |
||
89 | mov n$发红包金额显示值 <$str(s1)> |
||
90 | goto <notextile>@</notextile>设置红包 |
||
91 | #elseact |
||
92 | mov n$发红包金额显示值 <$str(s1)> |
||
93 | |
||
94 | |
||
95 | [<notextile>@</notextile>endInput2] |
||
96 | %{color:lightGrey};触发编辑结束,如未输入红包数量,会返回一个空字符% |
||
97 | #act |
||
98 | mov n$新红包数量 <$str(s2)> |
||
99 | |
||
100 | #if |
||
101 | not equal s2 |
||
102 | small n$新红包数量 n$发红包数量显示值 |
||
103 | #act |
||
104 | sendtipsmsg 红包数量最少10个 |
||
105 | mov s2 10 |
||
106 | mov n$发红包数量显示值 <$str(s2)> |
||
107 | goto <notextile>@</notextile>设置红包 |
||
108 | #elseact |
||
109 | mov n$发红包数量显示值 <$str(s2)> |
||
110 | |
||
111 | |
||
112 | %{color:lightGrey};点击调整红包金额的减号按钮触发% |
||
113 | [<notextile>@</notextile>发放金额减] |
||
114 | #if |
||
115 | small n$发红包金额显示值 1001 |
||
116 | #act |
||
117 | mov n$发红包金额显示值 1000 |
||
118 | sendtipsmsg 红包金额最少需要1000灵符 |
||
119 | #elseact |
||
120 | mov n$显示值数字化金额 <$str(n$发红包金额显示值)> |
||
121 | dec n$显示值数字化金额 100 |
||
122 | mov n$发红包金额显示值 <$str(n$显示值数字化金额)> |
||
123 | goto <notextile>@</notextile>设置红包 |
||
124 | |
||
125 | |
||
126 | %{color:lightGrey};点击调整红包金额的加号按钮触发% |
||
127 | [<notextile>@</notextile>发放金额加] |
||
128 | #if |
||
129 | equal s1 |
||
130 | #act |
||
131 | mov s1 10 |
||
132 | mov n$显示值数字化金额 1000 |
||
133 | inc n$显示值数字化金额 100 |
||
134 | mov n$发红包金额显示值 <$str(n$显示值数字化金额)> |
||
135 | goto <notextile>@</notextile>设置红包 |
||
136 | break |
||
137 | |
||
138 | #if |
||
139 | #act |
||
140 | mov n$显示值数字化金额 <$str(n$发红包金额显示值)> |
||
141 | inc n$显示值数字化金额 100 |
||
142 | mov n$发红包金额显示值 <$str(n$显示值数字化金额)> |
||
143 | goto <notextile>@</notextile>设置红包 |
||
144 | |
||
145 | |
||
146 | %{color:lightGrey};点击调整红包数量的减号按钮触发% |
||
147 | [<notextile>@</notextile>红包数量减] |
||
148 | #if |
||
149 | small n$发红包数量显示值 11 |
||
150 | #act |
||
151 | mov n$发红包数量显示值 10 |
||
152 | sendtipsmsg 红包数量最少10个 |
||
153 | #elseact |
||
154 | mov n$显示值数字化数量 <$str(n$发红包数量显示值)> |
||
155 | dec n$显示值数字化数量 1 |
||
156 | mov n$发红包数量显示值 <$str(n$显示值数字化数量)> |
||
157 | goto <notextile>@</notextile>设置红包 |
||
158 | |
||
159 | |
||
160 | %{color:lightGrey};点击调整红包数量的加号按钮触发% |
||
161 | [<notextile>@</notextile>红包数量加] |
||
162 | #if |
||
163 | equal s2 |
||
164 | #act |
||
165 | mov s2 10 |
||
166 | mov n$显示值数字化数量 10 |
||
167 | inc n$显示值数字化数量 1 |
||
168 | mov n$发红包数量显示值 <$str(n$显示值数字化数量)> |
||
169 | goto <notextile>@</notextile>设置红包 |
||
170 | break |
||
171 | |
||
172 | #if |
||
173 | #act |
||
174 | mov n$显示值数字化数量 <$str(n$发红包数量显示值)> |
||
175 | inc n$显示值数字化数量 1 |
||
176 | mov n$发红包数量显示值 <$str(n$显示值数字化数量)> |
||
177 | goto <notextile>@</notextile>设置红包 |
||
178 | |
||
179 | |
||
180 | [<notextile>@</notextile>submitinput] |
||
181 | %{color:lightGrey};触发提交时,如果未输入过任何内容,则返回值为空格% |
||
182 | #if |
||
183 | equal " " <$str(s1)> |
||
184 | #act |
||
185 | mov s1 <$str(n$发红包金额显示值)> |
||
186 | |
||
187 | #if |
||
188 | equal " " <$str(s2)> |
||
189 | #act |
||
190 | mov s2 <$str(n$发红包数量显示值)> |
||
191 | |
||
192 | %{color:lightGrey};今日剩余可发灵符不足时,弹出提示% |
||
193 | #act |
||
194 | mov n$新红包金额 <$str(s1)> |
||
195 | |
||
196 | #if |
||
197 | large n$新红包金额 u$今日剩余可发灵符 |
||
198 | #act |
||
199 | messageBox 今日剩余可发灵符不足 |
||
200 | break |
||
201 | |
||
202 | #if |
||
203 | small n$新红包金额 1000 |
||
204 | #act |
||
205 | messageBox 红包金额最少需要1000灵符 |
||
206 | break |
||
207 | |
||
208 | #if |
||
209 | small n$新红包数量 10 |
||
210 | #act |
||
211 | messageBox 红包数量最少10个 |
||
212 | break |
||
213 | |
||
214 | #if |
||
215 | #act |
||
216 | mov n$新红包金额 <$str(s1)> |
||
217 | %{color:lightGrey};更新今日剩余可发灵符% |
||
218 | dec u$今日剩余可发灵符 n$新红包金额 |
||
219 | %{color:lightGrey};扣除灵符% |
||
220 | gameGird - <$str(s1)> |
||
221 | %{color:lightGrey};添加新红包数据,时间戳,发放者角色名,红包总金额,红包数量% |
||
222 | mov s$新红包数据 <$timeStamp>|<$userName>|<$str(s1)>|<$str(s2)>|: |
||
223 | inc s$新红包数据 <$guild2(行会红包)> |
||
224 | *{color:green}[[calcVar]]* guild2 行会红包 = <$str(s$新红包数据)> |
||
225 | %{color:lightGrey};更新自己发出的红包列表,过期退还红包余额时用% |
||
226 | mov s1 <$str(t$自己发出的红包列表)> |
||
227 | inc s1 <$timeStamp>| |
||
228 | mov t$自己发出的红包列表 <$str(s1)> |
||
229 | sendMsg 6 发送红包成功 |
||
230 | %{color:lightGrey};重新加载红包列表界面% |
||
231 | goto <notextile>@</notextile>main |
||
232 | |
||
233 | |
||
234 | [<notextile>@</notextile>生成红包列表] |
||
235 | %{color:lightGrey};获取全部的行会红包,包括不能领取的% |
||
236 | #act |
||
237 | mov s$红包列表含已领取 <$guild2(行会红包)> |
||
238 | *{color:green}[[pgExtractString]]* : s$红包列表含已领取 s$红包列表含已领取分割后 n$行会红包总数 |
||
239 | mov n$红包计数器 1 |
||
240 | |
||
241 | %{color:lightGrey};循环取出列表中各红包的时间戳% |
||
242 | #if loop n$行会红包总数 |
||
243 | #act |
||
244 | %{color:lightGrey};取出单个红包数据% |
||
245 | mov n$var <$str(n$红包计数器)> |
||
246 | *{color:green}[[getListValue]]* s$红包列表含已领取分割后 <$str(n$var)> s$红包 |
||
247 | %{color:lightGrey};取出红包的时间戳% |
||
248 | *{color:green}[[pgExtractString]]* | <$str(s$红包)> s$红包分割后 n$红包分割后 |
||
249 | mov n$var 1 |
||
250 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包的时间戳 |
||
251 | goto <notextile>@</notextile>过滤红包 |
||
252 | inc n$红包计数器 1 |
||
253 | |
||
254 | |
||
255 | [<notextile>@</notextile>过滤红包] |
||
256 | %{color:lightGrey};列表不展示自己已经领取过的行会红包,列表不展示发出超过24小时的行会红包% |
||
257 | %{color:lightGrey};检测时间戳是否在自己领过的红包列表中,检测时间戳与当前时间的差值是否大于24小时% |
||
258 | #act |
||
259 | mov n$var1 <$timeStamp> |
||
260 | mov n$var2 <$str(s$红包的时间戳)> |
||
261 | dec n$var1 n$var2 |
||
262 | div n$发出多少小时 n$var1 3600 |
||
263 | |
||
264 | #or |
||
265 | *{color:green}[[checkContainsText]]* t$自己领过的红包列表 s$红包的时间戳 |
||
266 | not small n$发出多少小时 24 |
||
267 | #act |
||
268 | mov s$tmp |
||
269 | *{color:green}[[ansiReplaceText]]* s$红包列表含已领取 <$str(s$红包)>: s$tmp |
||
270 | mov s$红包列表 <$str(s$红包列表含已领取)> |
||
271 | #elseact |
||
272 | mov s$红包列表 <$str(s$红包列表含已领取)> |
||
273 | |
||
274 | |
||
275 | [<notextile>@</notextile>红包数据] |
||
276 | #act |
||
277 | *{color:green}[[pgExtractString]]* : s$红包列表 s$红包列表分割后 n$行会红包总数 |
||
278 | |
||
279 | %{color:lightGrey};没有可领取的红包% |
||
280 | #if |
||
281 | equal n$行会红包总数 0 |
||
282 | #act |
||
283 | mov s$itemList |
||
284 | |
||
285 | %{color:lightGrey};红包界面第1个红包% |
||
286 | #if |
||
287 | large n$行会红包总数 0 |
||
288 | #act |
||
289 | mov n$var 1 |
||
290 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包1 |
||
291 | *{color:green}[[pgExtractString]]* | <$str(s$红包1)> s$红包分割后 n$红包分割数 |
||
292 | mov n$var 2 |
||
293 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
294 | mov s$item1 (<itemindex:1> |
||
295 | inc s$item1 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(1)> |
||
296 | inc s$item1 <Img:lc_qiang:100:250:1> |
||
297 | inc s$item1 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
298 | inc s$item1 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
299 | mov s$itemList <$str(s$item1)> |
||
300 | |
||
301 | %{color:lightGrey};红包界面第2个红包% |
||
302 | #if |
||
303 | large n$行会红包总数 1 |
||
304 | #act |
||
305 | mov n$var 2 |
||
306 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包2 |
||
307 | *{color:green}[[pgExtractString]]* | <$str(s$红包2)> s$红包分割后 n$红包分割数 |
||
308 | mov n$var 2 |
||
309 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
310 | mov s$item2 (<itemindex:2> |
||
311 | inc s$item2 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(2)> |
||
312 | inc s$item2 <Img:lc_qiang:100:250:1> |
||
313 | inc s$item2 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
314 | inc s$item2 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
315 | inc s$itemList <$str(s$item2)> |
||
316 | |
||
317 | %{color:lightGrey};红包界面第3个红包% |
||
318 | #if |
||
319 | large n$行会红包总数 2 |
||
320 | #act |
||
321 | mov n$var 3 |
||
322 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包3 |
||
323 | *{color:green}[[pgExtractString]]* | <$str(s$红包3)> s$红包分割后 n$红包分割数 |
||
324 | mov n$var 2 |
||
325 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
326 | mov s$item3 (<itemindex:3> |
||
327 | inc s$item3 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(3)> |
||
328 | inc s$item3 <Img:lc_qiang:100:250:1> |
||
329 | inc s$item3 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
330 | inc s$item3 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
331 | inc s$itemList <$str(s$item3)> |
||
332 | |
||
333 | %{color:lightGrey};红包界面第4个红包% |
||
334 | #if |
||
335 | large n$行会红包总数 3 |
||
336 | #act |
||
337 | mov n$var 4 |
||
338 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包4 |
||
339 | *{color:green}[[pgExtractString]]* | <$str(s$红包4)> s$红包分割后 n$红包分割数 |
||
340 | mov n$var 2 |
||
341 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
342 | mov s$item4 (<itemindex:4> |
||
343 | inc s$item4 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(4)> |
||
344 | inc s$item4 <Img:lc_qiang:100:250:1> |
||
345 | inc s$item4 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
346 | inc s$item4 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
347 | inc s$itemList <$str(s$item4)> |
||
348 | |
||
349 | %{color:lightGrey};红包界面第5个红包% |
||
350 | #if |
||
351 | large n$行会红包总数 4 |
||
352 | #act |
||
353 | mov n$var 5 |
||
354 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包5 |
||
355 | *{color:green}[[pgExtractString]]* | <$str(s$红包5)> s$红包分割后 n$红包分割数 |
||
356 | mov n$var 2 |
||
357 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
358 | mov s$item5 (<itemindex:5> |
||
359 | inc s$item5 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(5)> |
||
360 | inc s$item5 <Img:lc_qiang:100:250:1> |
||
361 | inc s$item5 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
362 | inc s$item5 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
363 | inc s$itemList <$str(s$item5)> |
||
364 | |
||
365 | %{color:lightGrey};红包界面第6个红包% |
||
366 | #if |
||
367 | large n$行会红包总数 5 |
||
368 | #act |
||
369 | mov n$var 6 |
||
370 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包6 |
||
371 | *{color:green}[[pgExtractString]]* | <$str(s$红包6)> s$红包分割后 n$红包分割数 |
||
372 | mov n$var 2 |
||
373 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
374 | mov s$item6 (<itemindex:6> |
||
375 | inc s$item6 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(6)> |
||
376 | inc s$item6 <Img:lc_qiang:100:250:1> |
||
377 | inc s$item6 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
378 | inc s$item6 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
379 | inc s$itemList <$str(s$item6)> |
||
380 | |
||
381 | %{color:lightGrey};红包界面第7个红包% |
||
382 | #if |
||
383 | large n$行会红包总数 6 |
||
384 | #act |
||
385 | mov n$var 7 |
||
386 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包7 |
||
387 | *{color:green}[[pgExtractString]]* | <$str(s$红包7)> s$红包分割后 n$红包分割数 |
||
388 | mov n$var 2 |
||
389 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
390 | mov s$item7 (<itemindex:7> |
||
391 | inc s$item7 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(7)> |
||
392 | inc s$item7 <Img:lc_qiang:100:250:1> |
||
393 | inc s$item7 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
394 | inc s$item7 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
395 | inc s$itemList <$str(s$item7)> |
||
396 | |
||
397 | %{color:lightGrey};红包界面第8个红包% |
||
398 | #if |
||
399 | large n$行会红包总数 7 |
||
400 | #act |
||
401 | mov n$var 8 |
||
402 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$红包8 |
||
403 | *{color:green}[[pgExtractString]]* | <$str(s$红包8)> s$红包分割后 n$红包分割数 |
||
404 | mov n$var 2 |
||
405 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$红包角色名 |
||
406 | mov s$item8 (<itemindex:8> |
||
407 | inc s$item8 <Img:lc_hongbao_01:25:10:1/<notextile>@</notextile>领取红包(8)> |
||
408 | inc s$item8 <Img:lc_qiang:100:250:1> |
||
409 | inc s$item8 <text:<$str(s$红包角色名)>的红包{scolor=151}:60:55> |
||
410 | inc s$item8 <text:恭喜发财,大吉大利{scolor=151}:35:175>) |
||
411 | inc s$itemList <$str(s$item8)> |
||
412 | |
||
413 | |
||
414 | [<notextile>@</notextile>领取红包] |
||
415 | #if |
||
416 | #act |
||
417 | %{color:lightGrey};取出单个红包的数据% |
||
418 | mov n$var <$scriptParam1> |
||
419 | *{color:green}[[getListValue]]* s$红包列表分割后 <$str(n$var)> s$点的红包 |
||
420 | *{color:green}[[pgExtractString]]* | <$str(s$点的红包)> s$红包分割后 n$红包分割数 |
||
421 | %{color:lightGrey};取出红包的金额和数量% |
||
422 | mov n$var 1 |
||
423 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$点的红包时间戳 |
||
424 | mov n$var 3 |
||
425 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$点的红包金额 |
||
426 | mov n$var 4 |
||
427 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$点的红包数量 |
||
428 | mov n1 <$str(s$点的红包金额)> |
||
429 | mov n2 <$str(s$点的红包数量)> |
||
430 | |
||
431 | %{color:lightGrey};随机获得红包奖励% |
||
432 | %{color:lightGrey};如果红包数量大于1,领取后更新该红包% |
||
433 | #if |
||
434 | large n2 1 |
||
435 | %{color:lightGrey};领过的红包不能再领% |
||
436 | not *{color:green}[[checkContainsText]]* t$自己领过的红包列表 s$点的红包时间戳 |
||
437 | #act |
||
438 | div n$当前平均值 n1 n2 |
||
439 | mul n$当前平均值的2倍 n$当前平均值 2 |
||
440 | %{color:lightGrey};一个行会红包只能再领2次时,最后1个玩家至少可以领取1个货币% |
||
441 | dec n$当前平均值的2倍 1 |
||
442 | movr n$随机红包领取值 1 n$当前平均值的2倍 |
||
443 | dec n1 n$随机红包领取值 |
||
444 | dec n2 1 |
||
445 | mov s1 <$str(s$红包分割后_1)>|<$str(s$红包分割后_2)>|<$str(n1)>|<$str(n2)>| |
||
446 | mov s$红包列表 <$guild2(行会红包)> |
||
447 | *{color:green}[[ansiReplaceText]]* s$红包列表 <$str(s$点的红包)> <$str(s1)> |
||
448 | *{color:green}[[calcVar]]* guild2 行会红包 = <$str(s$红包列表)> |
||
449 | gameGird + n$随机红包领取值 |
||
450 | sendtipsmsg 恭喜你抢到了<$str(n$随机红包领取值)>灵符的红包 |
||
451 | mov s1 <$str(t$自己领过的红包列表)> |
||
452 | inc s1 <$str(s$点的红包时间戳)>| |
||
453 | mov t$自己领过的红包列表 <$str(s1)> |
||
454 | goto <notextile>@</notextile>main |
||
455 | |
||
456 | %{color:lightGrey};一个行会红包只能再领1次时,领取后删除该红包% |
||
457 | #if |
||
458 | equal n2 1 |
||
459 | %{color:lightGrey};自己领过的红包不能再领% |
||
460 | not *{color:green}[[checkContainsText]]* t$自己领过的红包列表 s$点的红包时间戳 |
||
461 | #act |
||
462 | mov s$tmp |
||
463 | mov s$红包列表 <$guild2(行会红包)> |
||
464 | *{color:green}[[ansiReplaceText]]* s$红包列表 <$str(s$点的红包)>: s$tmp |
||
465 | *{color:green}[[calcVar]]* guild2 行会红包 = <$str(s$红包列表)> |
||
466 | gameGird + n1 |
||
467 | sendtipsmsg 恭喜你抢到了<$str(n1)>灵符的红包 |
||
468 | goto <notextile>@</notextile>main |
||
469 | |
||
470 | |
||
471 | [<notextile>@</notextile>返还过期红包] |
||
472 | %{color:lightGrey};循环取出自己发出的红包% |
||
473 | #act |
||
474 | *{color:green}[[pgExtractString]]* | <$str(t$自己发出的红包列表)> s1 n1 |
||
475 | mov n$红包计数器 1 |
||
476 | |
||
477 | %{color:lightGrey};循环取出自己发红包列表中红包的时间戳% |
||
478 | #if loop n1 |
||
479 | #act |
||
480 | %{color:lightGrey};取出时间戳% |
||
481 | mov n$var <$str(n$红包计数器)> |
||
482 | *{color:green}[[getListValue]]* s1 <$str(n$var)> s$红包的时间戳 |
||
483 | goto <notextile>@</notextile>过期处理 |
||
484 | inc n$红包计数器 1 |
||
485 | |
||
486 | %{color:lightGrey};返还过期的红包% |
||
487 | #if |
||
488 | large u$过期返还的红包金额 0 |
||
489 | #act |
||
490 | messageBox 您发出的行会红包超过24小时仍未领完\现将未领取的红包退还\共退还<$str(u$过期返还的红包金额)>灵符 |
||
491 | gameGird + u$过期返还的红包金额 |
||
492 | sendMsg 6 你获得了退还的<$str(u$过期返还的红包金额)>灵符 |
||
493 | mov u$过期返还的红包金额 0 |
||
494 | |
||
495 | |
||
496 | [<notextile>@</notextile>过期处理] |
||
497 | %{color:lightGrey};根据时间戳判断该红包是否过期% |
||
498 | #act |
||
499 | mov n$var1 <$timeStamp> |
||
500 | mov n$var2 <$str(s$红包的时间戳)> |
||
501 | dec n$var1 n$var2 |
||
502 | div n$发出多少小时 n$var1 3600 |
||
503 | |
||
504 | #if |
||
505 | not small n$发出多少小时 24 |
||
506 | #act |
||
507 | %{color:lightGrey};从发红包数据中删除该红包% |
||
508 | mov s$tmp |
||
509 | *{color:green}[[ansiReplaceText]]* t$自己发出的红包列表 <$str(s$红包的时间戳)>| s$tmp |
||
510 | goto <notextile>@</notextile>找出仍在行会红包中的 |
||
511 | |
||
512 | %{color:lightGrey};过期并且依然存在于行会红包中的,找出来% |
||
513 | [<notextile>@</notextile>找出仍在行会红包中的] |
||
514 | #act |
||
515 | %{color:lightGrey};获取全部的行会红包% |
||
516 | mov s$红包列表含已领取 <$guild2(行会红包)> |
||
517 | *{color:green}[[pgExtractString]]* : s$红包列表含已领取 s$红包列表含已领取分割后 n$行会红包总数 |
||
518 | |
||
519 | #if |
||
520 | *{color:green}[[checkContainsText]]* s$红包列表含已领取 s$红包的时间戳 |
||
521 | #act |
||
522 | mov n$红包计数器2号 1 |
||
523 | %{color:lightGrey};循环取出列表中红包们的时间戳% |
||
524 | #if loop n$行会红包总数 |
||
525 | #act |
||
526 | %{color:lightGrey};取出红包% |
||
527 | mov n$var <$str(n$红包计数器2号)> |
||
528 | *{color:green}[[getListValue]]* s$红包列表含已领取分割后 <$str(n$var)> s$红包 |
||
529 | *{color:green}[[pgExtractString]]* | <$str(s$红包)> s$红包分割后 n$红包分割后 |
||
530 | %{color:lightGrey};取出红包的时间戳% |
||
531 | mov n$var 1 |
||
532 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$行会红包的时间戳 |
||
533 | %{color:lightGrey};取出红包的红包金额% |
||
534 | mov n$var 3 |
||
535 | *{color:green}[[getListValue]]* s$红包分割后 <$str(n$var)> s$行会红包金额 |
||
536 | goto <notextile>@</notextile>处理仍在行会红包中的 |
||
537 | inc n$红包计数器2号 1 |
||
538 | |
||
539 | |
||
540 | %{color:lightGrey};将红包余额存个人变量,再从行会红包中删除% |
||
541 | [<notextile>@</notextile>处理仍在行会红包中的] |
||
542 | #if |
||
543 | *{color:green}[[CompareText]]* s$红包的时间戳 s$行会红包的时间戳 |
||
544 | #act |
||
545 | %{color:lightGrey};将红包余额存变量% |
||
546 | mov n$var <$str(s$行会红包金额)> |
||
547 | inc u$过期返还的红包金额 n$var |
||
548 | %{color:lightGrey};从行会红包中删除该红包% |
||
549 | mov s$tmp |
||
550 | mov s$红包列表 <$guild2(行会红包)> |
||
551 | *{color:green}[[ansiReplaceText]]* s$红包列表 <$str(s$红包)>: s$tmp |
||
552 | *{color:green}[[calcVar]]* guild2 行会红包 = <$str(s$红包列表)> |
||
553 | |
||
554 | |
||
555 | %{color:lightGrey};自己领红包数据中,删除时间超过24小时的红包% |
||
556 | [<notextile>@</notextile>更新领红包数据] |
||
557 | %{color:lightGrey};循环取出自己领取的红包% |
||
558 | #act |
||
559 | *{color:green}[[pgExtractString]]* | <$str(t$自己领过的红包列表)> s1 n1 |
||
560 | mov n$红包计数器 1 |
||
561 | |
||
562 | %{color:lightGrey};循环取出自己领取红包列表中红包的时间戳% |
||
563 | #if loop n1 |
||
564 | #act |
||
565 | %{color:lightGrey};取出时间戳% |
||
566 | mov n$var <$str(n$红包计数器)> |
||
567 | *{color:green}[[getListValue]]* s1 <$str(n$var)> s$红包的时间戳 |
||
568 | goto <notextile>@</notextile>领红包过期处理 |
||
569 | inc n$红包计数器 1 |
||
570 | |
||
571 | |
||
572 | [<notextile>@</notextile>领红包过期处理] |
||
573 | %{color:lightGrey};根据时间戳判断该红包是否过期% |
||
574 | #act |
||
575 | mov n$var1 <$timeStamp> |
||
576 | mov n$var2 <$str(s$红包的时间戳)> |
||
577 | dec n$var1 n$var2 |
||
578 | div n$发出多少小时 n$var1 3600 |
||
579 | |
||
580 | #if |
||
581 | not small n$发出多少小时 24 |
||
582 | #act |
||
583 | %{color:lightGrey};从领红包数据中删除该红包% |
||
584 | mov s$tmp |
||
585 | *{color:green}[[ansiReplaceText]]* t$自己领过的红包列表 <$str(s$红包的时间戳)>| s$tmp |
||
586 | 24 | chenjun | |
587 | 25 | chenjun | - |
588 | - |
||
589 | 24 | chenjun | |
590 | bq. %{color:lightGrey};..\Mir200\Envir\MapQuest_def\QManage.txt% |
||
591 | 15 | chenjun | [<notextile>@</notextile>Login] |
592 | #if |
||
593 | %{color:lightGrey};登陆时返还过期红包% |
||
594 | #call [\行会红包\行会红包.txt] <notextile>@</notextile>返还过期红包 |
||
595 | %{color:lightGrey};登陆时,自己领红包数据中,删除时间超过24小时的红包% |
||
596 | #call [\行会红包\行会红包.txt] <notextile>@</notextile>更新领红包数据 |
||
597 | |
||
598 | 1 | chenjun | %{color:lightGrey};每日首次登陆时重置每日数据% |
599 | #if |
||
600 | 20 | chenjun | checkLoginCount = 1 |
601 | #act |
||
602 | 15 | chenjun | mov u$今日剩余可发灵符 10000000 |