@battle-racing/br-common-lib 3.4.0 → 3.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/constants/hardware/damage.d.ts +1 -0
- package/dist/constants/hardware/damage.js +1 -0
- package/dist/data/all-damages.d.ts +2 -0
- package/dist/data/all-damages.js +54 -0
- package/dist/data/all-power-ups.d.ts +3 -0
- package/dist/data/all-power-ups.js +521 -0
- package/dist/data/index.d.ts +3 -1
- package/dist/data/index.js +3 -1
- package/dist/data/role-definitions.d.ts +2 -0
- package/dist/data/role-definitions.js +27 -0
- package/dist/types/damage/Damage.d.ts +1 -3
- package/dist/types/powerUp/PowerUp.d.ts +1 -1
- package/dist/types/powerUp/PowerUpName.d.ts +1 -1
- package/package.json +1 -1
- package/src/constants/hardware/damage.ts +1 -0
- package/src/data/all-damages.ts +53 -0
- package/src/data/all-power-ups.ts +526 -0
- package/src/data/index.ts +4 -1
- package/src/types/damage/Damage.ts +2 -4
- package/src/types/powerUp/PowerUp.ts +1 -1
- package/src/types/powerUp/PowerUpName.ts +2 -1
- /package/src/data/{RoleDefinitions.ts → role-definitions.ts} +0 -0
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.allDamages = void 0;
|
|
4
|
+
const constants_1 = require("../constants");
|
|
5
|
+
exports.allDamages = [
|
|
6
|
+
{
|
|
7
|
+
name: 'Pulse Hit',
|
|
8
|
+
target: 'All',
|
|
9
|
+
sound: 'battle_pulse_damage.mp3',
|
|
10
|
+
rgbEffect: 'Ray Hit Effect',
|
|
11
|
+
amount: 1,
|
|
12
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.ELECTROCUTED,
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
name: 'Trap Hit',
|
|
16
|
+
target: 'Any',
|
|
17
|
+
sound: 'battle_trap_damage.mp3',
|
|
18
|
+
rgbEffect: 'Ray Hit Effect',
|
|
19
|
+
amount: 1,
|
|
20
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.OIL_DROP_COLORS,
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: 'Star Hit Left',
|
|
24
|
+
target: 'Any',
|
|
25
|
+
sound: 'battle_star_damage.mp3',
|
|
26
|
+
rgbEffect: 'Ray Hit Effect',
|
|
27
|
+
amount: 1,
|
|
28
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
name: 'Star Hit Right',
|
|
32
|
+
target: 'Any',
|
|
33
|
+
sound: 'battle_star_damage.mp3',
|
|
34
|
+
rgbEffect: 'Ray Hit Effect',
|
|
35
|
+
amount: 1,
|
|
36
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: 'Shot Hit',
|
|
40
|
+
target: 'Any',
|
|
41
|
+
sound: 'battle_shot_damage.mp3',
|
|
42
|
+
rgbEffect: 'Ray Hit Effect',
|
|
43
|
+
amount: 1,
|
|
44
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
name: 'Blue Shot Hit',
|
|
48
|
+
target: 'First',
|
|
49
|
+
sound: 'battle_shot_damage.mp3',
|
|
50
|
+
rgbEffect: 'Ray Hit Effect',
|
|
51
|
+
amount: 1,
|
|
52
|
+
flagMediaName: constants_1.FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
53
|
+
},
|
|
54
|
+
];
|
|
@@ -0,0 +1,521 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.defaultPowerUps = exports.allPowerUps = void 0;
|
|
4
|
+
const constants_1 = require("../constants");
|
|
5
|
+
exports.allPowerUps = [
|
|
6
|
+
{
|
|
7
|
+
id: 'battle-god',
|
|
8
|
+
name: 'Battle God',
|
|
9
|
+
imageName: 'power-up-battle-god.png',
|
|
10
|
+
description: 'Increase speed, slow down enemies near, enable shortcuts',
|
|
11
|
+
level: 5,
|
|
12
|
+
shield: {
|
|
13
|
+
duration: 5,
|
|
14
|
+
},
|
|
15
|
+
assignationCommands: [
|
|
16
|
+
{
|
|
17
|
+
module: 'flag',
|
|
18
|
+
action: 'showMediaTemporarily',
|
|
19
|
+
params: {
|
|
20
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_HELMET,
|
|
21
|
+
screens: {
|
|
22
|
+
left: true,
|
|
23
|
+
right: true,
|
|
24
|
+
back: true,
|
|
25
|
+
front: true,
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
module: 'sound',
|
|
31
|
+
action: 'play',
|
|
32
|
+
params: {
|
|
33
|
+
soundName: 'power_up_selection.mp3',
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
module: 'rgb',
|
|
38
|
+
action: 'showEffect',
|
|
39
|
+
params: {
|
|
40
|
+
effect: 'Roulette Effect',
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
],
|
|
44
|
+
activationCommands: [
|
|
45
|
+
{
|
|
46
|
+
module: 'speed',
|
|
47
|
+
action: 'change',
|
|
48
|
+
params: {
|
|
49
|
+
speed: '$kart.configuredSpeed * 2',
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
module: 'rgb',
|
|
54
|
+
action: 'showEffect',
|
|
55
|
+
params: {
|
|
56
|
+
effect: 'Star Effect',
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
module: 'sound',
|
|
61
|
+
action: 'play',
|
|
62
|
+
params: {
|
|
63
|
+
soundName: 'battle_god_activation.mp3',
|
|
64
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
module: 'leftStarBackLaser',
|
|
69
|
+
action: 'action',
|
|
70
|
+
params: {
|
|
71
|
+
laserAction: 'Init Attack',
|
|
72
|
+
starAction: 'Init Attack',
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
module: 'rightStarFrontLaser',
|
|
77
|
+
action: 'action',
|
|
78
|
+
params: {
|
|
79
|
+
laserAction: 'Init Attack',
|
|
80
|
+
starAction: 'Init Attack',
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
module: 'flag',
|
|
85
|
+
action: 'showMediaTemporarily',
|
|
86
|
+
params: {
|
|
87
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.BR_CHANGE_COLOR,
|
|
88
|
+
screens: {
|
|
89
|
+
left: true,
|
|
90
|
+
right: true,
|
|
91
|
+
front: true,
|
|
92
|
+
back: true,
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
},
|
|
96
|
+
],
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
id: 'battle-nitro',
|
|
100
|
+
name: 'Battle Nitro',
|
|
101
|
+
imageName: 'power-up-battle-nitro.png',
|
|
102
|
+
description: 'Double the speed of the user for 2 seconds.',
|
|
103
|
+
level: 1,
|
|
104
|
+
assignationCommands: [
|
|
105
|
+
{
|
|
106
|
+
module: 'flag',
|
|
107
|
+
action: 'showMediaTemporarily',
|
|
108
|
+
params: {
|
|
109
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_EXHAUST,
|
|
110
|
+
screens: {
|
|
111
|
+
left: true,
|
|
112
|
+
right: true,
|
|
113
|
+
back: true,
|
|
114
|
+
front: true,
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
module: 'sound',
|
|
120
|
+
action: 'play',
|
|
121
|
+
params: {
|
|
122
|
+
soundName: 'power_up_selection.mp3',
|
|
123
|
+
},
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
module: 'rgb',
|
|
127
|
+
action: 'showEffect',
|
|
128
|
+
params: {
|
|
129
|
+
effect: 'Roulette Effect',
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
],
|
|
133
|
+
activationCommands: [
|
|
134
|
+
{
|
|
135
|
+
module: 'speed',
|
|
136
|
+
action: 'change',
|
|
137
|
+
params: {
|
|
138
|
+
speed: '$kart.configuredSpeed * 2',
|
|
139
|
+
},
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
module: 'rgb',
|
|
143
|
+
action: 'showEffect',
|
|
144
|
+
params: {
|
|
145
|
+
effect: 'Speed Boost Effect',
|
|
146
|
+
},
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
module: 'sound',
|
|
150
|
+
action: 'play',
|
|
151
|
+
params: {
|
|
152
|
+
soundName: 'battle_turbo_activation.mp3',
|
|
153
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
module: 'flag',
|
|
158
|
+
action: 'showMediaTemporarily',
|
|
159
|
+
params: {
|
|
160
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.NITRO_BOTTLE,
|
|
161
|
+
screens: {
|
|
162
|
+
left: true,
|
|
163
|
+
right: true,
|
|
164
|
+
front: true,
|
|
165
|
+
back: true,
|
|
166
|
+
},
|
|
167
|
+
},
|
|
168
|
+
},
|
|
169
|
+
],
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
id: 'battle-pulse',
|
|
173
|
+
name: 'Battle Pulse',
|
|
174
|
+
imageName: 'power-up-battle-pulse.png',
|
|
175
|
+
description: 'Slow down all the enemies for 2 seconds.',
|
|
176
|
+
level: 5,
|
|
177
|
+
networkDamage: {
|
|
178
|
+
name: 'Pulse Hit',
|
|
179
|
+
target: 'All',
|
|
180
|
+
},
|
|
181
|
+
assignationCommands: [
|
|
182
|
+
{
|
|
183
|
+
module: 'flag',
|
|
184
|
+
action: 'showMediaTemporarily',
|
|
185
|
+
params: {
|
|
186
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_LIGHTNING,
|
|
187
|
+
screens: {
|
|
188
|
+
left: true,
|
|
189
|
+
right: true,
|
|
190
|
+
back: true,
|
|
191
|
+
front: true,
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
module: 'sound',
|
|
197
|
+
action: 'play',
|
|
198
|
+
params: {
|
|
199
|
+
soundName: 'power_up_selection.mp3',
|
|
200
|
+
},
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
module: 'rgb',
|
|
204
|
+
action: 'showEffect',
|
|
205
|
+
params: {
|
|
206
|
+
effect: 'Roulette Effect',
|
|
207
|
+
},
|
|
208
|
+
},
|
|
209
|
+
],
|
|
210
|
+
activationCommands: [
|
|
211
|
+
{
|
|
212
|
+
module: 'rgb',
|
|
213
|
+
action: 'showEffect',
|
|
214
|
+
params: {
|
|
215
|
+
effect: 'Ray Effect',
|
|
216
|
+
},
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
module: 'sound',
|
|
220
|
+
action: 'play',
|
|
221
|
+
params: {
|
|
222
|
+
soundName: 'battle_pulse_activation.mp3',
|
|
223
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
224
|
+
},
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
module: 'flag',
|
|
228
|
+
action: 'showMediaTemporarily',
|
|
229
|
+
params: {
|
|
230
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.THUNDER_EXPLOSION,
|
|
231
|
+
screens: {
|
|
232
|
+
left: true,
|
|
233
|
+
right: true,
|
|
234
|
+
front: true,
|
|
235
|
+
back: true,
|
|
236
|
+
},
|
|
237
|
+
},
|
|
238
|
+
},
|
|
239
|
+
],
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
id: 'battle-shield',
|
|
243
|
+
name: 'Battle Shield',
|
|
244
|
+
imageName: 'power-up-battle-shield.png',
|
|
245
|
+
description: 'A shield that blocks all the damage.',
|
|
246
|
+
level: 4,
|
|
247
|
+
shield: {
|
|
248
|
+
duration: 5,
|
|
249
|
+
},
|
|
250
|
+
assignationCommands: [
|
|
251
|
+
{
|
|
252
|
+
module: 'flag',
|
|
253
|
+
action: 'showMediaTemporarily',
|
|
254
|
+
params: {
|
|
255
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_SHIELD,
|
|
256
|
+
screens: {
|
|
257
|
+
left: true,
|
|
258
|
+
right: true,
|
|
259
|
+
back: true,
|
|
260
|
+
front: true,
|
|
261
|
+
},
|
|
262
|
+
},
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
module: 'sound',
|
|
266
|
+
action: 'play',
|
|
267
|
+
params: {
|
|
268
|
+
soundName: 'power_up_selection.mp3',
|
|
269
|
+
},
|
|
270
|
+
},
|
|
271
|
+
{
|
|
272
|
+
module: 'rgb',
|
|
273
|
+
action: 'showEffect',
|
|
274
|
+
params: {
|
|
275
|
+
effect: 'Roulette Effect',
|
|
276
|
+
},
|
|
277
|
+
},
|
|
278
|
+
],
|
|
279
|
+
activationCommands: [
|
|
280
|
+
{
|
|
281
|
+
module: 'rgb',
|
|
282
|
+
action: 'showEffect',
|
|
283
|
+
params: {
|
|
284
|
+
effect: 'Shield Effect',
|
|
285
|
+
},
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
module: 'sound',
|
|
289
|
+
action: 'play',
|
|
290
|
+
params: {
|
|
291
|
+
soundName: 'battle_shield_activation.mp3',
|
|
292
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
293
|
+
},
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
module: 'flag',
|
|
297
|
+
action: 'showMediaTemporarily',
|
|
298
|
+
params: {
|
|
299
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.SHIELD_BLUE_TO_PINK,
|
|
300
|
+
screens: {
|
|
301
|
+
left: true,
|
|
302
|
+
right: true,
|
|
303
|
+
front: true,
|
|
304
|
+
back: true,
|
|
305
|
+
},
|
|
306
|
+
},
|
|
307
|
+
},
|
|
308
|
+
],
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
id: 'battle-shot',
|
|
312
|
+
name: 'Battle Shot',
|
|
313
|
+
imageName: 'power-up-battle-shot.png',
|
|
314
|
+
description: 'Slow Down Specifc Enemy for 2 seconds.',
|
|
315
|
+
level: 3,
|
|
316
|
+
assignationCommands: [
|
|
317
|
+
{
|
|
318
|
+
module: 'flag',
|
|
319
|
+
action: 'showMediaTemporarily',
|
|
320
|
+
params: {
|
|
321
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
322
|
+
screens: {
|
|
323
|
+
left: true,
|
|
324
|
+
right: true,
|
|
325
|
+
back: true,
|
|
326
|
+
front: true,
|
|
327
|
+
},
|
|
328
|
+
},
|
|
329
|
+
},
|
|
330
|
+
{
|
|
331
|
+
module: 'sound',
|
|
332
|
+
action: 'play',
|
|
333
|
+
params: {
|
|
334
|
+
soundName: 'power_up_selection.mp3',
|
|
335
|
+
},
|
|
336
|
+
},
|
|
337
|
+
{
|
|
338
|
+
module: 'rgb',
|
|
339
|
+
action: 'showEffect',
|
|
340
|
+
params: {
|
|
341
|
+
effect: 'Roulette Effect',
|
|
342
|
+
},
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
module: 'diskSensorBallShooter',
|
|
346
|
+
action: 'prepareShooter',
|
|
347
|
+
},
|
|
348
|
+
],
|
|
349
|
+
activationCommands: [
|
|
350
|
+
{
|
|
351
|
+
module: 'rgb',
|
|
352
|
+
action: 'showEffect',
|
|
353
|
+
params: {
|
|
354
|
+
effect: 'Ball Shot Effect',
|
|
355
|
+
},
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
module: 'diskSensorBallShooter',
|
|
359
|
+
action: 'shootBall',
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
module: 'sound',
|
|
363
|
+
action: 'play',
|
|
364
|
+
params: {
|
|
365
|
+
soundName: 'battle_shot_activation.mp3',
|
|
366
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
367
|
+
},
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
module: 'flag',
|
|
371
|
+
action: 'showMediaTemporarily',
|
|
372
|
+
params: {
|
|
373
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.FIREBALL,
|
|
374
|
+
screens: {
|
|
375
|
+
left: true,
|
|
376
|
+
right: true,
|
|
377
|
+
front: true,
|
|
378
|
+
back: true,
|
|
379
|
+
},
|
|
380
|
+
},
|
|
381
|
+
},
|
|
382
|
+
],
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
id: 'battle-trap',
|
|
386
|
+
name: 'Battle Trap',
|
|
387
|
+
imageName: 'power-up-battle-trap.png',
|
|
388
|
+
description: 'Slow Down Specifc Enemy for 3 seconds.',
|
|
389
|
+
level: 2,
|
|
390
|
+
assignationCommands: [
|
|
391
|
+
{
|
|
392
|
+
module: 'flag',
|
|
393
|
+
action: 'showMediaTemporarily',
|
|
394
|
+
params: {
|
|
395
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_OIL_DROP,
|
|
396
|
+
screens: {
|
|
397
|
+
left: true,
|
|
398
|
+
right: true,
|
|
399
|
+
back: true,
|
|
400
|
+
front: true,
|
|
401
|
+
},
|
|
402
|
+
},
|
|
403
|
+
},
|
|
404
|
+
{
|
|
405
|
+
module: 'sound',
|
|
406
|
+
action: 'play',
|
|
407
|
+
params: {
|
|
408
|
+
soundName: 'power_up_selection.mp3',
|
|
409
|
+
},
|
|
410
|
+
},
|
|
411
|
+
{
|
|
412
|
+
module: 'rgb',
|
|
413
|
+
action: 'showEffect',
|
|
414
|
+
params: {
|
|
415
|
+
effect: 'Roulette Effect',
|
|
416
|
+
},
|
|
417
|
+
},
|
|
418
|
+
],
|
|
419
|
+
activationCommands: [
|
|
420
|
+
{
|
|
421
|
+
module: 'ballSensorDiskThrower',
|
|
422
|
+
action: 'throwDisk',
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
module: 'sound',
|
|
426
|
+
action: 'play',
|
|
427
|
+
params: {
|
|
428
|
+
soundName: 'battle_trap_activation.mp3',
|
|
429
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
430
|
+
},
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
module: 'flag',
|
|
434
|
+
action: 'showMediaTemporarily',
|
|
435
|
+
params: {
|
|
436
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.OIL_DROP_COLORS,
|
|
437
|
+
screens: {
|
|
438
|
+
left: true,
|
|
439
|
+
right: true,
|
|
440
|
+
front: true,
|
|
441
|
+
back: true,
|
|
442
|
+
},
|
|
443
|
+
},
|
|
444
|
+
},
|
|
445
|
+
],
|
|
446
|
+
},
|
|
447
|
+
// TODO: Change The media names
|
|
448
|
+
{
|
|
449
|
+
id: 'battle-blue-shot',
|
|
450
|
+
name: 'Battle Blue Shot',
|
|
451
|
+
imageName: 'power-up-battle-blue-shot.png',
|
|
452
|
+
description: 'Deal shot hit damage to the first player in the race.',
|
|
453
|
+
level: 4,
|
|
454
|
+
networkDamage: {
|
|
455
|
+
name: 'Blue Shot Hit',
|
|
456
|
+
target: 'First',
|
|
457
|
+
},
|
|
458
|
+
assignationCommands: [
|
|
459
|
+
{
|
|
460
|
+
module: 'flag',
|
|
461
|
+
action: 'showMediaTemporarily',
|
|
462
|
+
params: {
|
|
463
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
464
|
+
screens: {
|
|
465
|
+
left: true,
|
|
466
|
+
right: true,
|
|
467
|
+
back: true,
|
|
468
|
+
front: true,
|
|
469
|
+
},
|
|
470
|
+
},
|
|
471
|
+
},
|
|
472
|
+
{
|
|
473
|
+
module: 'sound',
|
|
474
|
+
action: 'play',
|
|
475
|
+
params: {
|
|
476
|
+
soundName: 'power_up_selection.mp3',
|
|
477
|
+
},
|
|
478
|
+
},
|
|
479
|
+
{
|
|
480
|
+
module: 'rgb',
|
|
481
|
+
action: 'showEffect',
|
|
482
|
+
params: {
|
|
483
|
+
effect: 'Roulette Effect',
|
|
484
|
+
},
|
|
485
|
+
},
|
|
486
|
+
],
|
|
487
|
+
activationCommands: [
|
|
488
|
+
{
|
|
489
|
+
module: 'rgb',
|
|
490
|
+
action: 'showEffect',
|
|
491
|
+
params: {
|
|
492
|
+
effect: 'Ray Effect',
|
|
493
|
+
},
|
|
494
|
+
},
|
|
495
|
+
{
|
|
496
|
+
module: 'sound',
|
|
497
|
+
action: 'play',
|
|
498
|
+
params: {
|
|
499
|
+
// TODO: Change to blue shot activation
|
|
500
|
+
soundName: 'battle_shot_activation.mp3',
|
|
501
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
502
|
+
},
|
|
503
|
+
},
|
|
504
|
+
{
|
|
505
|
+
module: 'flag',
|
|
506
|
+
action: 'showMediaTemporarily',
|
|
507
|
+
params: {
|
|
508
|
+
// TODO: Change to blue shot
|
|
509
|
+
mediaSourceName: constants_1.FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
510
|
+
screens: {
|
|
511
|
+
left: true,
|
|
512
|
+
right: true,
|
|
513
|
+
front: true,
|
|
514
|
+
back: true,
|
|
515
|
+
},
|
|
516
|
+
},
|
|
517
|
+
},
|
|
518
|
+
],
|
|
519
|
+
},
|
|
520
|
+
];
|
|
521
|
+
exports.defaultPowerUps = exports.allPowerUps.filter((powerUp) => ['battle-god', 'battle-pulse', 'battle-shield', 'battle-nitro', 'battle-blue-shot'].includes(powerUp.id));
|
package/dist/data/index.d.ts
CHANGED
package/dist/data/index.js
CHANGED
|
@@ -14,4 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./all-damages"), exports);
|
|
18
|
+
__exportStar(require("./all-power-ups"), exports);
|
|
19
|
+
__exportStar(require("./role-definitions"), exports);
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ROLE_DEFINITIONS = void 0;
|
|
4
|
+
const constants_1 = require("../constants");
|
|
5
|
+
exports.ROLE_DEFINITIONS = [
|
|
6
|
+
{
|
|
7
|
+
role: constants_1.USER_ROLE.SUPER_ADMIN,
|
|
8
|
+
description: 'Complete access to all features and settings',
|
|
9
|
+
permissions: [
|
|
10
|
+
constants_1.PERMISSION.FULL_ACCESS,
|
|
11
|
+
constants_1.PERMISSION.KARTS_MANAGE_HARDWARE,
|
|
12
|
+
constants_1.PERMISSION.KARTS_MANAGE_POWER_UPS,
|
|
13
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_GAMES,
|
|
14
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_BASIC_INFO,
|
|
15
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_HARDWARE,
|
|
16
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_KARTS_CONFIG,
|
|
17
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_CHECKPOINTS,
|
|
18
|
+
constants_1.PERMISSION.GAME_TRACK_MANAGE_KARTS,
|
|
19
|
+
constants_1.PERMISSION.KARTS_TRACKING,
|
|
20
|
+
],
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
role: constants_1.USER_ROLE.OPERATOR,
|
|
24
|
+
description: 'Game Track Operator',
|
|
25
|
+
permissions: [constants_1.PERMISSION.GAME_TRACK_MANAGE_GAMES],
|
|
26
|
+
},
|
|
27
|
+
];
|
|
@@ -5,11 +5,9 @@ import type { DamageTarget } from './DamageTarget';
|
|
|
5
5
|
export interface Damage {
|
|
6
6
|
name: DamageEffectName;
|
|
7
7
|
target: DamageTarget;
|
|
8
|
-
/** Time in seconds */
|
|
9
|
-
duration: number;
|
|
10
8
|
sound: SoundName;
|
|
11
9
|
rgbEffect: KartEffect;
|
|
12
|
-
/**
|
|
10
|
+
/** Mainly used for coins reduction */
|
|
13
11
|
amount: number;
|
|
14
12
|
flagMediaName: FlagMediaName;
|
|
15
13
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type PowerUpName = 'Battle God' | 'Battle Star' | 'Battle Shot' | 'Battle Nitro' | 'Battle Pulse' | 'Battle Trap' | 'Battle Shield' | 'Battle Turbo';
|
|
1
|
+
export type PowerUpName = 'Battle God' | 'Battle Star' | 'Battle Shot' | 'Battle Nitro' | 'Battle Pulse' | 'Battle Trap' | 'Battle Shield' | 'Battle Turbo' | 'Battle Blue Shot';
|
package/package.json
CHANGED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { FLAG_MEDIA_NAME } from '../constants';
|
|
2
|
+
import type { Damage } from '../types';
|
|
3
|
+
|
|
4
|
+
export const allDamages: Damage[] = [
|
|
5
|
+
{
|
|
6
|
+
name: 'Pulse Hit',
|
|
7
|
+
target: 'All',
|
|
8
|
+
sound: 'battle_pulse_damage.mp3',
|
|
9
|
+
rgbEffect: 'Ray Hit Effect',
|
|
10
|
+
amount: 1,
|
|
11
|
+
flagMediaName: FLAG_MEDIA_NAME.ELECTROCUTED,
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
name: 'Trap Hit',
|
|
15
|
+
target: 'Any',
|
|
16
|
+
sound: 'battle_trap_damage.mp3',
|
|
17
|
+
rgbEffect: 'Ray Hit Effect',
|
|
18
|
+
amount: 1,
|
|
19
|
+
flagMediaName: FLAG_MEDIA_NAME.OIL_DROP_COLORS,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
name: 'Star Hit Left',
|
|
23
|
+
target: 'Any',
|
|
24
|
+
sound: 'battle_star_damage.mp3',
|
|
25
|
+
rgbEffect: 'Ray Hit Effect',
|
|
26
|
+
amount: 1,
|
|
27
|
+
flagMediaName: FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
name: 'Star Hit Right',
|
|
31
|
+
target: 'Any',
|
|
32
|
+
sound: 'battle_star_damage.mp3',
|
|
33
|
+
rgbEffect: 'Ray Hit Effect',
|
|
34
|
+
amount: 1,
|
|
35
|
+
flagMediaName: FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
name: 'Shot Hit',
|
|
39
|
+
target: 'Any',
|
|
40
|
+
sound: 'battle_shot_damage.mp3',
|
|
41
|
+
rgbEffect: 'Ray Hit Effect',
|
|
42
|
+
amount: 1,
|
|
43
|
+
flagMediaName: FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
name: 'Blue Shot Hit',
|
|
47
|
+
target: 'First',
|
|
48
|
+
sound: 'battle_shot_damage.mp3',
|
|
49
|
+
rgbEffect: 'Ray Hit Effect',
|
|
50
|
+
amount: 1,
|
|
51
|
+
flagMediaName: FLAG_MEDIA_NAME.HIT_EFFECT,
|
|
52
|
+
},
|
|
53
|
+
];
|
|
@@ -0,0 +1,526 @@
|
|
|
1
|
+
import { FLAG_MEDIA_NAME } from '../constants';
|
|
2
|
+
import type { PowerUp } from '../types';
|
|
3
|
+
|
|
4
|
+
export const allPowerUps: PowerUp[] = [
|
|
5
|
+
{
|
|
6
|
+
id: 'battle-god',
|
|
7
|
+
name: 'Battle God',
|
|
8
|
+
imageName: 'power-up-battle-god.png',
|
|
9
|
+
description: 'Increase speed, slow down enemies near, enable shortcuts',
|
|
10
|
+
level: 5,
|
|
11
|
+
shield: {
|
|
12
|
+
duration: 5,
|
|
13
|
+
},
|
|
14
|
+
assignationCommands: [
|
|
15
|
+
{
|
|
16
|
+
module: 'flag',
|
|
17
|
+
action: 'showMediaTemporarily',
|
|
18
|
+
params: {
|
|
19
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_HELMET,
|
|
20
|
+
screens: {
|
|
21
|
+
left: true,
|
|
22
|
+
right: true,
|
|
23
|
+
back: true,
|
|
24
|
+
front: true,
|
|
25
|
+
},
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
module: 'sound',
|
|
30
|
+
action: 'play',
|
|
31
|
+
params: {
|
|
32
|
+
soundName: 'power_up_selection.mp3',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
module: 'rgb',
|
|
37
|
+
action: 'showEffect',
|
|
38
|
+
params: {
|
|
39
|
+
effect: 'Roulette Effect',
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
],
|
|
43
|
+
activationCommands: [
|
|
44
|
+
{
|
|
45
|
+
module: 'speed',
|
|
46
|
+
action: 'change',
|
|
47
|
+
params: {
|
|
48
|
+
speed: '$kart.configuredSpeed * 2',
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
module: 'rgb',
|
|
53
|
+
action: 'showEffect',
|
|
54
|
+
params: {
|
|
55
|
+
effect: 'Star Effect',
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
module: 'sound',
|
|
60
|
+
action: 'play',
|
|
61
|
+
params: {
|
|
62
|
+
soundName: 'battle_god_activation.mp3',
|
|
63
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
64
|
+
},
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
module: 'leftStarBackLaser',
|
|
68
|
+
action: 'action',
|
|
69
|
+
params: {
|
|
70
|
+
laserAction: 'Init Attack',
|
|
71
|
+
starAction: 'Init Attack',
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
module: 'rightStarFrontLaser',
|
|
76
|
+
action: 'action',
|
|
77
|
+
params: {
|
|
78
|
+
laserAction: 'Init Attack',
|
|
79
|
+
starAction: 'Init Attack',
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
module: 'flag',
|
|
84
|
+
action: 'showMediaTemporarily',
|
|
85
|
+
params: {
|
|
86
|
+
mediaSourceName: FLAG_MEDIA_NAME.BR_CHANGE_COLOR,
|
|
87
|
+
screens: {
|
|
88
|
+
left: true,
|
|
89
|
+
right: true,
|
|
90
|
+
front: true,
|
|
91
|
+
back: true,
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
],
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
id: 'battle-nitro',
|
|
99
|
+
name: 'Battle Nitro',
|
|
100
|
+
imageName: 'power-up-battle-nitro.png',
|
|
101
|
+
description: 'Double the speed of the user for 2 seconds.',
|
|
102
|
+
level: 1,
|
|
103
|
+
assignationCommands: [
|
|
104
|
+
{
|
|
105
|
+
module: 'flag',
|
|
106
|
+
action: 'showMediaTemporarily',
|
|
107
|
+
params: {
|
|
108
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_EXHAUST,
|
|
109
|
+
screens: {
|
|
110
|
+
left: true,
|
|
111
|
+
right: true,
|
|
112
|
+
back: true,
|
|
113
|
+
front: true,
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
module: 'sound',
|
|
119
|
+
action: 'play',
|
|
120
|
+
params: {
|
|
121
|
+
soundName: 'power_up_selection.mp3',
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
module: 'rgb',
|
|
126
|
+
action: 'showEffect',
|
|
127
|
+
params: {
|
|
128
|
+
effect: 'Roulette Effect',
|
|
129
|
+
},
|
|
130
|
+
},
|
|
131
|
+
],
|
|
132
|
+
activationCommands: [
|
|
133
|
+
{
|
|
134
|
+
module: 'speed',
|
|
135
|
+
action: 'change',
|
|
136
|
+
params: {
|
|
137
|
+
speed: '$kart.configuredSpeed * 2',
|
|
138
|
+
},
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
module: 'rgb',
|
|
142
|
+
action: 'showEffect',
|
|
143
|
+
params: {
|
|
144
|
+
effect: 'Speed Boost Effect',
|
|
145
|
+
},
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
module: 'sound',
|
|
149
|
+
action: 'play',
|
|
150
|
+
params: {
|
|
151
|
+
soundName: 'battle_turbo_activation.mp3',
|
|
152
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
153
|
+
},
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
module: 'flag',
|
|
157
|
+
action: 'showMediaTemporarily',
|
|
158
|
+
params: {
|
|
159
|
+
mediaSourceName: FLAG_MEDIA_NAME.NITRO_BOTTLE,
|
|
160
|
+
screens: {
|
|
161
|
+
left: true,
|
|
162
|
+
right: true,
|
|
163
|
+
front: true,
|
|
164
|
+
back: true,
|
|
165
|
+
},
|
|
166
|
+
},
|
|
167
|
+
},
|
|
168
|
+
],
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
id: 'battle-pulse',
|
|
172
|
+
name: 'Battle Pulse',
|
|
173
|
+
imageName: 'power-up-battle-pulse.png',
|
|
174
|
+
description: 'Slow down all the enemies for 2 seconds.',
|
|
175
|
+
level: 5,
|
|
176
|
+
networkDamage: {
|
|
177
|
+
name: 'Pulse Hit',
|
|
178
|
+
target: 'All',
|
|
179
|
+
},
|
|
180
|
+
assignationCommands: [
|
|
181
|
+
{
|
|
182
|
+
module: 'flag',
|
|
183
|
+
action: 'showMediaTemporarily',
|
|
184
|
+
params: {
|
|
185
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_LIGHTNING,
|
|
186
|
+
screens: {
|
|
187
|
+
left: true,
|
|
188
|
+
right: true,
|
|
189
|
+
back: true,
|
|
190
|
+
front: true,
|
|
191
|
+
},
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
module: 'sound',
|
|
196
|
+
action: 'play',
|
|
197
|
+
params: {
|
|
198
|
+
soundName: 'power_up_selection.mp3',
|
|
199
|
+
},
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
module: 'rgb',
|
|
203
|
+
action: 'showEffect',
|
|
204
|
+
params: {
|
|
205
|
+
effect: 'Roulette Effect',
|
|
206
|
+
},
|
|
207
|
+
},
|
|
208
|
+
],
|
|
209
|
+
activationCommands: [
|
|
210
|
+
{
|
|
211
|
+
module: 'rgb',
|
|
212
|
+
action: 'showEffect',
|
|
213
|
+
params: {
|
|
214
|
+
effect: 'Ray Effect',
|
|
215
|
+
},
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
module: 'sound',
|
|
219
|
+
action: 'play',
|
|
220
|
+
params: {
|
|
221
|
+
soundName: 'battle_pulse_activation.mp3',
|
|
222
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
223
|
+
},
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
module: 'flag',
|
|
227
|
+
action: 'showMediaTemporarily',
|
|
228
|
+
params: {
|
|
229
|
+
mediaSourceName: FLAG_MEDIA_NAME.THUNDER_EXPLOSION,
|
|
230
|
+
screens: {
|
|
231
|
+
left: true,
|
|
232
|
+
right: true,
|
|
233
|
+
front: true,
|
|
234
|
+
back: true,
|
|
235
|
+
},
|
|
236
|
+
},
|
|
237
|
+
},
|
|
238
|
+
],
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
id: 'battle-shield',
|
|
242
|
+
name: 'Battle Shield',
|
|
243
|
+
imageName: 'power-up-battle-shield.png',
|
|
244
|
+
description: 'A shield that blocks all the damage.',
|
|
245
|
+
level: 4,
|
|
246
|
+
shield: {
|
|
247
|
+
duration: 5,
|
|
248
|
+
},
|
|
249
|
+
assignationCommands: [
|
|
250
|
+
{
|
|
251
|
+
module: 'flag',
|
|
252
|
+
action: 'showMediaTemporarily',
|
|
253
|
+
params: {
|
|
254
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_SHIELD,
|
|
255
|
+
screens: {
|
|
256
|
+
left: true,
|
|
257
|
+
right: true,
|
|
258
|
+
back: true,
|
|
259
|
+
front: true,
|
|
260
|
+
},
|
|
261
|
+
},
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
module: 'sound',
|
|
265
|
+
action: 'play',
|
|
266
|
+
params: {
|
|
267
|
+
soundName: 'power_up_selection.mp3',
|
|
268
|
+
},
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
module: 'rgb',
|
|
272
|
+
action: 'showEffect',
|
|
273
|
+
params: {
|
|
274
|
+
effect: 'Roulette Effect',
|
|
275
|
+
},
|
|
276
|
+
},
|
|
277
|
+
],
|
|
278
|
+
activationCommands: [
|
|
279
|
+
{
|
|
280
|
+
module: 'rgb',
|
|
281
|
+
action: 'showEffect',
|
|
282
|
+
params: {
|
|
283
|
+
effect: 'Shield Effect',
|
|
284
|
+
},
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
module: 'sound',
|
|
288
|
+
action: 'play',
|
|
289
|
+
params: {
|
|
290
|
+
soundName: 'battle_shield_activation.mp3',
|
|
291
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
292
|
+
},
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
module: 'flag',
|
|
296
|
+
action: 'showMediaTemporarily',
|
|
297
|
+
params: {
|
|
298
|
+
mediaSourceName: FLAG_MEDIA_NAME.SHIELD_BLUE_TO_PINK,
|
|
299
|
+
screens: {
|
|
300
|
+
left: true,
|
|
301
|
+
right: true,
|
|
302
|
+
front: true,
|
|
303
|
+
back: true,
|
|
304
|
+
},
|
|
305
|
+
},
|
|
306
|
+
},
|
|
307
|
+
],
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
id: 'battle-shot',
|
|
311
|
+
name: 'Battle Shot',
|
|
312
|
+
imageName: 'power-up-battle-shot.png',
|
|
313
|
+
description: 'Slow Down Specifc Enemy for 2 seconds.',
|
|
314
|
+
level: 3,
|
|
315
|
+
assignationCommands: [
|
|
316
|
+
{
|
|
317
|
+
module: 'flag',
|
|
318
|
+
action: 'showMediaTemporarily',
|
|
319
|
+
params: {
|
|
320
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
321
|
+
screens: {
|
|
322
|
+
left: true,
|
|
323
|
+
right: true,
|
|
324
|
+
back: true,
|
|
325
|
+
front: true,
|
|
326
|
+
},
|
|
327
|
+
},
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
module: 'sound',
|
|
331
|
+
action: 'play',
|
|
332
|
+
params: {
|
|
333
|
+
soundName: 'power_up_selection.mp3',
|
|
334
|
+
},
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
module: 'rgb',
|
|
338
|
+
action: 'showEffect',
|
|
339
|
+
params: {
|
|
340
|
+
effect: 'Roulette Effect',
|
|
341
|
+
},
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
module: 'diskSensorBallShooter',
|
|
345
|
+
action: 'prepareShooter',
|
|
346
|
+
},
|
|
347
|
+
],
|
|
348
|
+
activationCommands: [
|
|
349
|
+
{
|
|
350
|
+
module: 'rgb',
|
|
351
|
+
action: 'showEffect',
|
|
352
|
+
params: {
|
|
353
|
+
effect: 'Ball Shot Effect',
|
|
354
|
+
},
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
module: 'diskSensorBallShooter',
|
|
358
|
+
action: 'shootBall',
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
module: 'sound',
|
|
362
|
+
action: 'play',
|
|
363
|
+
params: {
|
|
364
|
+
soundName: 'battle_shot_activation.mp3',
|
|
365
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
366
|
+
},
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
module: 'flag',
|
|
370
|
+
action: 'showMediaTemporarily',
|
|
371
|
+
params: {
|
|
372
|
+
mediaSourceName: FLAG_MEDIA_NAME.FIREBALL,
|
|
373
|
+
|
|
374
|
+
screens: {
|
|
375
|
+
left: true,
|
|
376
|
+
right: true,
|
|
377
|
+
front: true,
|
|
378
|
+
back: true,
|
|
379
|
+
},
|
|
380
|
+
},
|
|
381
|
+
},
|
|
382
|
+
],
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
id: 'battle-trap',
|
|
386
|
+
name: 'Battle Trap',
|
|
387
|
+
imageName: 'power-up-battle-trap.png',
|
|
388
|
+
description: 'Slow Down Specifc Enemy for 3 seconds.',
|
|
389
|
+
level: 2,
|
|
390
|
+
assignationCommands: [
|
|
391
|
+
{
|
|
392
|
+
module: 'flag',
|
|
393
|
+
action: 'showMediaTemporarily',
|
|
394
|
+
params: {
|
|
395
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_OIL_DROP,
|
|
396
|
+
screens: {
|
|
397
|
+
left: true,
|
|
398
|
+
right: true,
|
|
399
|
+
back: true,
|
|
400
|
+
front: true,
|
|
401
|
+
},
|
|
402
|
+
},
|
|
403
|
+
},
|
|
404
|
+
|
|
405
|
+
{
|
|
406
|
+
module: 'sound',
|
|
407
|
+
action: 'play',
|
|
408
|
+
params: {
|
|
409
|
+
soundName: 'power_up_selection.mp3',
|
|
410
|
+
},
|
|
411
|
+
},
|
|
412
|
+
{
|
|
413
|
+
module: 'rgb',
|
|
414
|
+
action: 'showEffect',
|
|
415
|
+
params: {
|
|
416
|
+
effect: 'Roulette Effect',
|
|
417
|
+
},
|
|
418
|
+
},
|
|
419
|
+
],
|
|
420
|
+
activationCommands: [
|
|
421
|
+
{
|
|
422
|
+
module: 'ballSensorDiskThrower',
|
|
423
|
+
action: 'throwDisk',
|
|
424
|
+
},
|
|
425
|
+
{
|
|
426
|
+
module: 'sound',
|
|
427
|
+
action: 'play',
|
|
428
|
+
params: {
|
|
429
|
+
soundName: 'battle_trap_activation.mp3',
|
|
430
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
431
|
+
},
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
module: 'flag',
|
|
435
|
+
action: 'showMediaTemporarily',
|
|
436
|
+
params: {
|
|
437
|
+
mediaSourceName: FLAG_MEDIA_NAME.OIL_DROP_COLORS,
|
|
438
|
+
|
|
439
|
+
screens: {
|
|
440
|
+
left: true,
|
|
441
|
+
right: true,
|
|
442
|
+
front: true,
|
|
443
|
+
back: true,
|
|
444
|
+
},
|
|
445
|
+
},
|
|
446
|
+
},
|
|
447
|
+
],
|
|
448
|
+
},
|
|
449
|
+
// TODO: Change The media names
|
|
450
|
+
{
|
|
451
|
+
id: 'battle-blue-shot',
|
|
452
|
+
name: 'Battle Blue Shot',
|
|
453
|
+
imageName: 'power-up-battle-blue-shot.png',
|
|
454
|
+
description: 'Deal shot hit damage to the first player in the race.',
|
|
455
|
+
level: 4,
|
|
456
|
+
networkDamage: {
|
|
457
|
+
name: 'Blue Shot Hit',
|
|
458
|
+
target: 'First',
|
|
459
|
+
},
|
|
460
|
+
assignationCommands: [
|
|
461
|
+
{
|
|
462
|
+
module: 'flag',
|
|
463
|
+
action: 'showMediaTemporarily',
|
|
464
|
+
params: {
|
|
465
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
466
|
+
screens: {
|
|
467
|
+
left: true,
|
|
468
|
+
right: true,
|
|
469
|
+
back: true,
|
|
470
|
+
front: true,
|
|
471
|
+
},
|
|
472
|
+
},
|
|
473
|
+
},
|
|
474
|
+
{
|
|
475
|
+
module: 'sound',
|
|
476
|
+
action: 'play',
|
|
477
|
+
params: {
|
|
478
|
+
soundName: 'power_up_selection.mp3',
|
|
479
|
+
},
|
|
480
|
+
},
|
|
481
|
+
{
|
|
482
|
+
module: 'rgb',
|
|
483
|
+
action: 'showEffect',
|
|
484
|
+
params: {
|
|
485
|
+
effect: 'Roulette Effect',
|
|
486
|
+
},
|
|
487
|
+
},
|
|
488
|
+
],
|
|
489
|
+
activationCommands: [
|
|
490
|
+
{
|
|
491
|
+
module: 'rgb',
|
|
492
|
+
action: 'showEffect',
|
|
493
|
+
params: {
|
|
494
|
+
effect: 'Ray Effect',
|
|
495
|
+
},
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
module: 'sound',
|
|
499
|
+
action: 'play',
|
|
500
|
+
params: {
|
|
501
|
+
// TODO: Change to blue shot activation
|
|
502
|
+
soundName: 'battle_shot_activation.mp3',
|
|
503
|
+
durationMs: '$kart.powerUpTime * 1000',
|
|
504
|
+
},
|
|
505
|
+
},
|
|
506
|
+
{
|
|
507
|
+
module: 'flag',
|
|
508
|
+
action: 'showMediaTemporarily',
|
|
509
|
+
params: {
|
|
510
|
+
// TODO: Change to blue shot
|
|
511
|
+
mediaSourceName: FLAG_MEDIA_NAME.STATIC_FIREBALL,
|
|
512
|
+
screens: {
|
|
513
|
+
left: true,
|
|
514
|
+
right: true,
|
|
515
|
+
front: true,
|
|
516
|
+
back: true,
|
|
517
|
+
},
|
|
518
|
+
},
|
|
519
|
+
},
|
|
520
|
+
],
|
|
521
|
+
},
|
|
522
|
+
];
|
|
523
|
+
|
|
524
|
+
export const defaultPowerUps: PowerUp[] = allPowerUps.filter((powerUp) =>
|
|
525
|
+
['battle-god', 'battle-pulse', 'battle-shield', 'battle-nitro', 'battle-blue-shot'].includes(powerUp.id),
|
|
526
|
+
);
|
package/src/data/index.ts
CHANGED
|
@@ -6,11 +6,9 @@ import type { DamageTarget } from './DamageTarget';
|
|
|
6
6
|
export interface Damage {
|
|
7
7
|
name: DamageEffectName;
|
|
8
8
|
target: DamageTarget;
|
|
9
|
-
/** Time in seconds */
|
|
10
|
-
duration: number;
|
|
11
9
|
sound: SoundName;
|
|
12
10
|
rgbEffect: KartEffect;
|
|
13
|
-
/**
|
|
14
|
-
amount: number
|
|
11
|
+
/** Mainly used for coins reduction */
|
|
12
|
+
amount: number
|
|
15
13
|
flagMediaName: FlagMediaName;
|
|
16
14
|
}
|
|
File without changes
|