This repository has been archived by the owner on Apr 24, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 69
/
Copy pathutils.cpp
458 lines (453 loc) · 13.4 KB
/
utils.cpp
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
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
#include"utils.hpp"
#include "Struct/UserSettings.hpp"
extern UserSettings userSettings;
Utils::Utils() {
this->b_useChineseLanguage = this->isChineseLanguageOS();
}
void Utils::changeLanguage() {
this->b_useChineseLanguage = !this->b_useChineseLanguage;
//userSettings.setInt(UserSettingsNames::b_use_chinese_language, this->b_useChineseLanguage);
}
const char8_t* Utils::getRoleName(int id) {
//返回中文角色名
if (this->b_useChineseLanguage) {
switch (id)
{
case gameRoleId::None:
return(u8"无");
break;
case gameRoleId::Goose:
return(u8"鹅");
break;
case gameRoleId::Duck:
return(u8"鸭子");
break;
case gameRoleId::Dodo:
return(u8"呆呆鸟");
break;
case gameRoleId::Bounty:
return(u8"赏金");
break;
case gameRoleId::Mechanic:
//可以使用管道(该角色已被开发者移除)
return(u8"Mechanic");
break;
case gameRoleId::Technician:
//可以在迷你地图上看到破坏的大约位置(该角色已被开发者移除)
return(u8"Technician");
break;
case gameRoleId::Medium:
return(u8"通灵");
break;
case gameRoleId::Vigilante:
return(u8"正义使者");
break;
case gameRoleId::Cannibal:
return(u8"食鸟鸭");
break;
case gameRoleId::Morphling:
return(u8"变形者(鸭子)");
break;
case gameRoleId::Sheriff:
return(u8"警长");
break;
case gameRoleId::Silencer:
return(u8"静语者(鸭子)");
break;
case gameRoleId::Canadian:
return(u8"加拿大鹅");
break;
case gameRoleId::LoverDuck:
return(u8"恋人(鸭子)");
break;
case gameRoleId::LoverGoose:
return(u8"恋人(鹅)");
break;
case gameRoleId::Vulture:
return(u8"秃鹫");
break;
case gameRoleId::Professional:
return(u8"专业杀手(鸭子)");
break;
case gameRoleId::Spy:
return(u8"间谍(鸭子)");
break;
case gameRoleId::Mimic:
return(u8"模仿者");
break;
case gameRoleId::Detective:
return(u8"侦探");
break;
case gameRoleId::Pigeon:
return(u8"鸽子");
break;
case gameRoleId::Birdwatcher:
return(u8"观鸟者");
break;
case gameRoleId::Assassin:
return(u8"刺客(鸭子)");
break;
case gameRoleId::Falcon:
return(u8"猎鹰");
break;
case gameRoleId::Hitman:
return(u8"雇佣杀手(鸭子)");
break;
case gameRoleId::Bodyguard:
return(u8"保镖鹅");
break;
case gameRoleId::Snitch:
return(u8"告密者(鸭子)");
break;
case gameRoleId::Politician:
return(u8"政治家");
break;
case gameRoleId::Locksmith:
return(u8"锁匠");
break;
case gameRoleId::Mortician:
return(u8"殡仪员");
break;
case gameRoleId::Celebrity:
return(u8"网红");
break;
case gameRoleId::Party:
return(u8"派对狂(鸭子)");
break;
case gameRoleId::Demolitionist:
return(u8"爆炸王(鸭子)");
break;
case gameRoleId::DuelingDodo:
return(u8"决斗呆呆鸟");
break;
case gameRoleId::GHGoose:
return(u8"【猎鹅】鹅");
break;
case gameRoleId::GHDuck:
return(u8"【猎鹅】鸭子");
break;
case gameRoleId::GHBounty:
//你的任务是被第一个消灭,如果任务完成则可以获得奖励(该角色已被开发者移除)
return(u8"【猎鹅】赏金鹅");
break;
case gameRoleId::HNSGoose:
return(u8"【HNS】鹅");
break;
case gameRoleId::HNSDuck:
return(u8"【HNS】鸭子");
break;
case gameRoleId::HNSBounty:
return(u8"【HNS】赏金鹅");
break;
case gameRoleId::DNDDuck:
return(u8"【霸王餐】鸭子");
break;
case gameRoleId::DNDFalcon:
return(u8"【霸王餐】猎鹰");
break;
case gameRoleId::DNDVulture:
return(u8"【霸王餐】秃鹫");
break;
case gameRoleId::DNDMorphling:
return(u8"【霸王餐】变形鸭");
break;
case gameRoleId::FPGoose:
return(u8"FPGoose");
break;
case gameRoleId::ExploreGoose:
return(u8"ExploreGoose");
break;
case gameRoleId::TTVampire:
return(u8"【TT】吸血鬼");
break;
case gameRoleId::TTPeasant:
return(u8"【TT】村民");
break;
case gameRoleId::TTThrall:
return(u8"【TT】鬼奴");
break;
case gameRoleId::Spectator:
return(u8"旁观");
break;
case gameRoleId::IdentityThief:
return(u8"身份窃贼");
break;
case gameRoleId::Adventurer:
return(u8"冒险家");
break;
case gameRoleId::Avenger:
return(u8"复仇者");
break;
case gameRoleId::Ninja:
return(u8"忍者(鸭子)");
break;
case gameRoleId::Undertaker:
return(u8"丧葬者");
break;
case gameRoleId::Snoop:
//可以隐藏在地图的一些地方(该角色已被开发者移除)
return(u8"Snoop");
break;
case gameRoleId::Esper:
return(u8"超能力者");
break;
case gameRoleId::Invisibility:
return(u8"隐身者");
break;
case gameRoleId::Astral:
return(u8"星界行者");
break;
case gameRoleId::Pelican:
return(u8"鹈鹕");
break;
case gameRoleId::TTEThrall:
return(u8"【TTE】鬼奴");
break;
case gameRoleId::TTMummy:
return(u8"【TT】木乃伊");
break;
case gameRoleId::SerialKiller:
return(u8"连环杀手(鸭子)");
break;
case gameRoleId::Engineer:
return(u8"工程师");
break;
case gameRoleId::Warlock:
return(u8"术士(鸭子)");
break;
case gameRoleId::StreetUrchin:
return(u8"流浪儿童");
break;
case gameRoleId::Tracker:
return(u8"追踪者");
break;
case gameRoleId::EsperDuck:
return(u8"超能力者(鸭子)");
break;
case gameRoleId::Stalker:
return(u8"追踪者");
break;
default:
return(u8"无");
break;
}
}
else {
switch (id)
{
case gameRoleId::None:
return(u8"None");
break;
case gameRoleId::Goose:
return(u8"Goose");
break;
case gameRoleId::Duck:
return(u8"Duck");
break;
case gameRoleId::Dodo:
return(u8"Dodo");
break;
case gameRoleId::Bounty:
return(u8"Bounty");
break;
case gameRoleId::Mechanic:
return(u8"Mechanic");
break;
case gameRoleId::Technician:
return(u8"Technician");
break;
case gameRoleId::Medium:
return(u8"Medium");
break;
case gameRoleId::Vigilante:
return(u8"Vigilante");
break;
case gameRoleId::Cannibal:
return(u8"Cannibal");
break;
case gameRoleId::Morphling:
return(u8"Morphling");
break;
case gameRoleId::Sheriff:
return(u8"Sheriff");
break;
case gameRoleId::Silencer:
return(u8"Silencer");
break;
case gameRoleId::Canadian:
return(u8"Canadian");
break;
case gameRoleId::LoverDuck:
return(u8"LoverDuck");
break;
case gameRoleId::LoverGoose:
return(u8"LoverGoose");
break;
case gameRoleId::Vulture:
return(u8"Vulture");
break;
case gameRoleId::Professional:
return(u8"Professional");
break;
case gameRoleId::Spy:
return(u8"Spy");
break;
case gameRoleId::Mimic:
return(u8"Mimic");
break;
case gameRoleId::Detective:
return(u8"Detective");
break;
case gameRoleId::Pigeon:
return(u8"Pigeon");
break;
case gameRoleId::Birdwatcher:
return(u8"Birdwatcher");
break;
case gameRoleId::Assassin:
return(u8"Assassin");
break;
case gameRoleId::Falcon:
return(u8"Falcon");
break;
case gameRoleId::Hitman:
return(u8"Hitman");
break;
case gameRoleId::Bodyguard:
return(u8"Bodyguard");
break;
case gameRoleId::Snitch:
return(u8"Snitch");
break;
case gameRoleId::Politician:
return(u8"Politician");
break;
case gameRoleId::Locksmith:
return(u8"Locksmith");
break;
case gameRoleId::Mortician:
return(u8"Mortician");
break;
case gameRoleId::Celebrity:
return(u8"Celebrity");
break;
case gameRoleId::Party:
return(u8"Party");
break;
case gameRoleId::Demolitionist:
return(u8"Demolitionist");
break;
case gameRoleId::DuelingDodo:
return(u8"DuelingDodo");
break;
case gameRoleId::GHGoose:
return(u8"GHGoose");
break;
case gameRoleId::GHDuck:
return(u8"GHDuck");
break;
case gameRoleId::GHBounty:
return(u8"GHBounty");
break;
case gameRoleId::HNSGoose:
return(u8"HNSGoose");
break;
case gameRoleId::HNSDuck:
return(u8"HNSDuck");
break;
case gameRoleId::HNSBounty:
return(u8"HNSBounty");
break;
case gameRoleId::DNDDuck:
return(u8"DNDDuck");
break;
case gameRoleId::DNDFalcon:
return(u8"DNDFalcon");
break;
case gameRoleId::DNDVulture:
return(u8"DNDVulture");
break;
case gameRoleId::DNDMorphling:
return(u8"DNDMorphling");
break;
case gameRoleId::FPGoose:
return(u8"FPGoose");
break;
case gameRoleId::ExploreGoose:
return(u8"ExploreGoose");
break;
case gameRoleId::TTVampire:
return(u8"TTVampire");
break;
case gameRoleId::TTPeasant:
return(u8"TTPeasant");
break;
case gameRoleId::TTThrall:
return(u8"TTThrall");
break;
case gameRoleId::Spectator:
return(u8"Spectator");
break;
case gameRoleId::IdentityThief:
return(u8"IdentityThief");
break;
case gameRoleId::Adventurer:
return(u8"Adventurer");
break;
case gameRoleId::Avenger:
return(u8"Avenger");
break;
case gameRoleId::Ninja:
return(u8"Ninja");
break;
case gameRoleId::Undertaker:
return(u8"Undertaker");
break;
case gameRoleId::Snoop:
return(u8"Snoop");
break;
case gameRoleId::Esper:
return(u8"Esper");
break;
case gameRoleId::Invisibility:
return(u8"Invisibility");
break;
case gameRoleId::Astral:
return(u8"Astral");
break;
case gameRoleId::Pelican:
return(u8"Pelican");
break;
case gameRoleId::TTEThrall:
return(u8"TTEThrall");
break;
case gameRoleId::TTMummy:
return(u8"TTMummy");
break;
case gameRoleId::SerialKiller:
return(u8"SerialKiller");
break;
case gameRoleId::Engineer:
return(u8"Engineer");
break;
case gameRoleId::Warlock:
return(u8"Warlock");
break;
case gameRoleId::StreetUrchin:
return(u8"StreetUrchin");
break;
case gameRoleId::Tracker:
return(u8"Tracker");
break;
case gameRoleId::EsperDuck:
return(u8"EsperDuck");
break;
case gameRoleId::Stalker:
return(u8"Stalker");
break;
default:
return(u8"None");
break;
}
}
}