Paper Mario DX
Paper Mario (N64) modding
 
Loading...
Searching...
No Matches
gray_magikoopa.inc.c
Go to the documentation of this file.
1#include "battle/battle.h"
2#include "script_api/battle.h"
3#include "effects.h"
4#include "sprite/npc/Magikoopa.h"
5#include "sprite/npc/FlyingMagikoopa.h"
6
7#define NAMESPACE A(gray_magikoopa)
8
9extern EvtScript N(EVS_Init);
10extern EvtScript N(EVS_Init_Flying);
11extern EvtScript N(EVS_TakeTurn);
12
13extern EvtScript N(EVS_Flee);
14
15extern s32 N(GroundAnims)[];
16extern s32 N(FlyingAnims)[];
17extern s32 N(BroomAnims)[];
18
19enum N(ActorPartIDs) {
20 PRT_GROUND = 1,
21 PRT_FLYING = 2,
22 PRT_BROOM = 3,
23};
24
25enum N(ActorVars) {
26 AVAR_ShouldKnockDown = 0,
27};
28
29enum N(ActorParams) {
30 DMG_MAGIC_BLAST = 3,
31 DMG_WAND_STRIKE = 3,
32};
33
34s32 N(DefenseTable)[] = {
37};
38
39s32 N(FlyingDefense)[] = {
42};
43
44s32 N(StatusTable)[] = {
67};
68
69s32 N(FlyingStatusTable)[] = {
92};
93
94ActorPartBlueprint N(GroundParts)[] = {
95 {
97 .index = PRT_GROUND,
98 .posOffset = { 0, 0, 0 },
99 .targetOffset = { 2, 35 },
100 .opacity = 255,
101 .idleAnimations = N(GroundAnims),
102 .defenseTable = N(DefenseTable),
103 .eventFlags = 0,
104 .elementImmunityFlags = 0,
105 .projectileTargetOffset = { -5, -12 },
106 },
107};
108
109ActorPartBlueprint N(FlyingParts)[] = {
110 {
112 .index = PRT_GROUND,
113 .posOffset = { 0, 0, 0 },
114 .targetOffset = { 2, 35 },
115 .opacity = 255,
116 .idleAnimations = N(GroundAnims),
117 .defenseTable = N(FlyingDefense),
118 .eventFlags = 0,
119 .elementImmunityFlags = 0,
120 .projectileTargetOffset = { -5, -12 },
121 },
122 {
124 .index = PRT_FLYING,
125 .posOffset = { 0, 0, 0 },
126 .targetOffset = { -10, 35 },
127 .opacity = 255,
128 .idleAnimations = N(FlyingAnims),
129 .defenseTable = N(FlyingDefense),
131 .elementImmunityFlags = 0,
132 .projectileTargetOffset = { 0, -8 },
133 },
134 {
136 .index = PRT_BROOM,
137 .posOffset = { 0, 0, 0 },
138 .targetOffset = { 0, 0 },
139 .opacity = 255,
140 .idleAnimations = N(BroomAnims),
141 .defenseTable = N(FlyingDefense),
142 .eventFlags = 0,
143 .elementImmunityFlags = 0,
144 .projectileTargetOffset = { 0, 0 },
145 },
146};
147
148ActorBlueprint NAMESPACE = {
149 .flags = 0,
150 .type = ACTOR_TYPE_GRAY_MAGIKOOPA,
151 .level = ACTOR_LEVEL_GRAY_MAGIKOOPA,
152 .maxHP = 11,
153 .partCount = ARRAY_COUNT(N(GroundParts)),
154 .partsData = N(GroundParts),
155 .initScript = &N(EVS_Init),
156 .statusTable = N(StatusTable),
157 .escapeChance = 40,
158 .airLiftChance = 80,
159 .hurricaneChance = 70,
160 .spookChance = 40,
161 .upAndAwayChance = 95,
162 .spinSmashReq = 0,
163 .powerBounceChance = 75,
164 .coinReward = 2,
165 .size = { 36, 40 },
166 .healthBarOffset = { 0, 0 },
167 .statusIconOffset = { -10, 20 },
168 .statusTextOffset = { 10, 32 },
169};
170
171ActorBlueprint N(flying) = {
172 .flags = ACTOR_FLAG_FLYING,
173 .type = ACTOR_TYPE_FLYING_GRAY_MAGIKOOPA,
174 .level = ACTOR_LEVEL_FLYING_GRAY_MAGIKOOPA,
175 .maxHP = 11,
176 .partCount = ARRAY_COUNT(N(FlyingParts)),
177 .partsData = N(FlyingParts),
178 .initScript = &N(EVS_Init_Flying),
179 .statusTable = N(FlyingStatusTable),
180 .escapeChance = 40,
181 .airLiftChance = 95,
182 .hurricaneChance = 75,
183 .spookChance = 40,
184 .upAndAwayChance = 95,
185 .spinSmashReq = 0,
186 .powerBounceChance = 75,
187 .coinReward = 2,
188 .size = { 48, 40 },
189 .healthBarOffset = { 0, 0 },
190 .statusIconOffset = { -25, 20 },
191 .statusTextOffset = { 1, 34 },
192};
193
194s32 N(GroundAnims)[] = {
195 STATUS_KEY_NORMAL, ANIM_Magikoopa_Gray_Anim01,
196 STATUS_KEY_STONE, ANIM_Magikoopa_Gray_Anim00,
197 STATUS_KEY_SLEEP, ANIM_Magikoopa_Gray_Anim08,
198 STATUS_KEY_POISON, ANIM_Magikoopa_Gray_Anim01,
199 STATUS_KEY_STOP, ANIM_Magikoopa_Gray_Anim00,
200 STATUS_KEY_STATIC, ANIM_Magikoopa_Gray_Anim01,
201 STATUS_KEY_PARALYZE, ANIM_Magikoopa_Gray_Anim00,
202 STATUS_KEY_DIZZY, ANIM_Magikoopa_Gray_Anim07,
203 STATUS_KEY_FEAR, ANIM_Magikoopa_Gray_Anim07,
205};
206
207s32 N(FlyingAnims)[] = {
208 STATUS_KEY_NORMAL, ANIM_FlyingMagikoopa_Gray_Anim01,
209 STATUS_KEY_STONE, ANIM_FlyingMagikoopa_Gray_Anim00,
210 STATUS_KEY_SLEEP, ANIM_FlyingMagikoopa_Gray_Anim08,
211 STATUS_KEY_POISON, ANIM_FlyingMagikoopa_Gray_Anim01,
212 STATUS_KEY_STOP, ANIM_FlyingMagikoopa_Gray_Anim00,
213 STATUS_KEY_STATIC, ANIM_FlyingMagikoopa_Gray_Anim01,
214 STATUS_KEY_PARALYZE, ANIM_FlyingMagikoopa_Gray_Anim00,
215 STATUS_KEY_DIZZY, ANIM_FlyingMagikoopa_Gray_Anim07,
216 STATUS_KEY_FEAR, ANIM_FlyingMagikoopa_Gray_Anim07,
218};
219
220s32 N(BroomAnims)[] = {
221 STATUS_KEY_NORMAL, ANIM_FlyingMagikoopa_Gray_Anim0A,
223};
224
225EvtScript N(EVS_Idle) = {
226 Return
227 End
228};
229
235
236EvtScript N(EVS_HandleEvent) = {
237 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
238 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
239 Call(GetLastEvent, ACTOR_SELF, LVar0)
243 SetConst(LVar0, PRT_GROUND)
244 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
248 SetConst(LVar0, PRT_GROUND)
249 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim05)
250 SetConst(LVar2, ANIM_Magikoopa_Gray_Anim06)
253 SetConst(LVar0, PRT_GROUND)
254 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim05)
255 SetConst(LVar2, ANIM_Magikoopa_Gray_Anim06)
257 SetConst(LVar0, PRT_GROUND)
258 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim06)
260 Return
262 SetConst(LVar0, PRT_GROUND)
263 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
266 SetConst(LVar0, PRT_GROUND)
267 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
269 SetConst(LVar0, PRT_GROUND)
270 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
272 Return
276 SetConst(LVar0, PRT_GROUND)
277 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim01)
281 SetConst(LVar0, PRT_GROUND)
282 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
284 Wait(10)
285 SetConst(LVar0, PRT_GROUND)
286 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
288 Return
290 SetConst(LVar0, PRT_GROUND)
291 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim01)
294 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim04)
295 Call(SetActorJumpGravity, ACTOR_SELF, Float(1.5))
296 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
297 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
298 Call(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
299 Wait(15)
300 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim02)
301 ExecWait(N(EVS_Flee))
302 Return
304 SetConst(LVar0, PRT_GROUND)
305 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim02)
308 Call(GetStatusFlags, ACTOR_SELF, LVar0)
311 Call(SetPartDispOffset, ACTOR_SELF, PRT_GROUND, 0, 2, 0)
312 Else
313 Call(SetPartDispOffset, ACTOR_SELF, PRT_GROUND, -4, 5, 0)
314 EndIf
315 EndIf
316 SetConst(LVar0, PRT_GROUND)
317 SetConst(LVar1, ANIM_Magikoopa_Gray_Anim04)
319 Return
322 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
323 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
324 Return
325 End
326};
327
328EvtScript N(EVS_KnockDownCheck) = {
329 Call(GetBattleFlags, LVar0)
332 Call(SetActorVar, ACTOR_SELF, AVAR_ShouldKnockDown, TRUE)
333 EndIf
334 Else
335 Call(N(GetSelectedMoveID), LVar0)
337 CaseOrEq(MOVE_HEADBONK1)
338 CaseOrEq(MOVE_HEADBONK2)
339 CaseOrEq(MOVE_HEADBONK3)
340 CaseOrEq(MOVE_MULTIBONK)
341 Call(GetBattleFlags, LVar0)
343 Call(SetActorVar, ACTOR_SELF, AVAR_ShouldKnockDown, TRUE)
344 EndIf
347 EndIf
348 Return
349 End
350};
351
352EvtScript N(EVS_KnockDown) = {
353 Call(GetActorVar, ACTOR_SELF, AVAR_ShouldKnockDown, LVar0)
354 IfEq(LVar0, 1)
355 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim04)
356 Goto(0)
357 EndIf
358 Call(GetLastElement, LVar0)
360 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim04)
361 Goto(0)
362 EndIf
363 Return
364 Label(0)
365 Call(HideHealthBar, ACTOR_SELF)
366 Call(GetStatusFlags, ACTOR_SELF, LVar0)
368 Call(SetPartScale, ACTOR_SELF, PRT_BROOM, Float(0.4), Float(0.4), Float(0.4))
369 EndIf
370 Call(SetPartFlagBits, ACTOR_SELF, PRT_GROUND, ACTOR_PART_FLAG_PRIMARY_TARGET, TRUE)
371 Call(SetPartFlagBits, ACTOR_SELF, PRT_GROUND, ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_NO_TARGET, FALSE)
372 Call(SetPartFlagBits, ACTOR_SELF, PRT_FLYING, ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_NO_TARGET, TRUE)
373 Call(SetPartFlagBits, ACTOR_SELF, PRT_FLYING, ACTOR_PART_FLAG_PRIMARY_TARGET, FALSE)
374 Call(SetPartFlagBits, ACTOR_SELF, PRT_BROOM, ACTOR_PART_FLAG_USE_ABSOLUTE_POSITION, TRUE)
375 Call(SetPartFlagBits, ACTOR_SELF, PRT_BROOM, ACTOR_PART_FLAG_INVISIBLE, FALSE)
376 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
377 Sub(LVar2, 1)
378 Call(SetPartPos, ACTOR_SELF, PRT_BROOM, LVar0, LVar1, LVar2)
379 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_FALL_QUICK)
380 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
381 Set(LVar1, 0)
382 Call(SetActorJumpGravity, ACTOR_SELF, Float(0.8))
383 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
384 Call(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
385 Call(N(StartRumbleWithParams), 150, 10)
386 Thread
387 Call(ShakeCam, CAM_BATTLE, 0, 5, Float(0.7))
389 Call(GetLastEvent, ACTOR_SELF, LVar3)
391 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim04)
392 Call(GetActorPos, ACTOR_SELF, LVar3, LVar4, LVar5)
393 Add(LVar4, 10)
394 Add(LVar5, 5)
395 PlayEffect(EFFECT_SMOKE_BURST, 0, LVar3, LVar4, LVar5, Float(1.0), 10, 0)
396 EndIf
397 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
398 Call(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
399 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
400 Call(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
401 Loop(20)
402 Call(SetPartFlagBits, ACTOR_SELF, PRT_BROOM, ACTOR_PART_FLAG_INVISIBLE, TRUE)
403 Wait(1)
404 Call(SetPartFlagBits, ACTOR_SELF, PRT_BROOM, ACTOR_PART_FLAG_INVISIBLE, FALSE)
405 Wait(1)
406 EndLoop
407 Call(SetPartFlagBits, ACTOR_SELF, PRT_BROOM, ACTOR_PART_FLAG_INVISIBLE, TRUE)
408 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim01)
409 Call(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_FLYING, FALSE)
410 Call(BindHandleEvent, ACTOR_SELF, Ref(N(EVS_HandleEvent)))
411 Call(SetActorType, ACTOR_SELF, ACTOR_TYPE_GRAY_MAGIKOOPA)
412 Call(SetStatusTable, ACTOR_SELF, Ref(N(StatusTable)))
413 Call(N(SetAbsoluteStatusOffsets), -10, 20, 10, 32)
414 Call(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_TYPE_CHANGED, TRUE)
415 Call(ResetAllActorSounds, ACTOR_SELF)
416 Call(GetIndexFromPos, ACTOR_SELF, LVar0)
417 Mod(LVar0, 4)
418 Call(SetGoalToIndex, ACTOR_SELF, LVar0)
419 Call(SetActorSpeed, ACTOR_SELF, Float(4.0))
420 Call(RunToGoal, ACTOR_SELF, 0, FALSE)
421 Call(GetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
422 Call(ForceHomePos, ACTOR_SELF, LVar0, LVar1, LVar2)
423 Call(HPBarToHome, ACTOR_SELF)
424 Return
425 End
426};
427
428EvtScript N(EVS_HandleEvent_Flying) = {
429 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
430 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
431 Call(GetLastEvent, ACTOR_SELF, LVar0)
434 ExecWait(N(EVS_KnockDownCheck))
435 SetConst(LVar0, PRT_FLYING)
436 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
440 ExecWait(N(EVS_KnockDownCheck))
441 SetConst(LVar0, PRT_FLYING)
442 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
444 ExecWait(N(EVS_KnockDown))
448 ExecWait(N(EVS_KnockDownCheck))
449 SetConst(LVar0, PRT_FLYING)
450 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim05)
451 SetConst(LVar2, ANIM_FlyingMagikoopa_Gray_Anim06)
453 ExecWait(N(EVS_KnockDown))
456 SetConst(LVar0, PRT_FLYING)
457 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim05)
458 SetConst(LVar2, ANIM_FlyingMagikoopa_Gray_Anim06)
460 SetConst(LVar0, PRT_FLYING)
461 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim06)
463 Return
465 SetConst(LVar0, PRT_FLYING)
466 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
469 SetConst(LVar0, PRT_FLYING)
470 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
472 SetConst(LVar0, PRT_FLYING)
473 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
475 Return
479 SetConst(LVar0, PRT_FLYING)
480 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim01)
484 SetConst(LVar0, PRT_FLYING)
485 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
487 Wait(10)
488 SetConst(LVar0, PRT_FLYING)
489 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
491 Return
493 Call(SetActorPos, ACTOR_SELF, 20, 0, 0)
494 Call(HPBarToCurrent, ACTOR_SELF)
496 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim01)
497 Call(SetGoalToHome, ACTOR_SELF)
498 Call(SetActorSpeed, ACTOR_SELF, Float(4.0))
499 Call(FlyToGoal, ACTOR_SELF, 0, 1, EASING_LINEAR)
500 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim01)
501 Call(HPBarToHome, ACTOR_SELF)
503 SetConst(LVar0, PRT_FLYING)
504 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim01)
507 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim04)
508 Call(SetActorJumpGravity, ACTOR_SELF, Float(1.5))
509 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
510 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
511 Call(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
512 Wait(15)
513 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim02)
514 ExecWait(N(EVS_Flee))
515 Return
517 SetConst(LVar0, PRT_FLYING)
518 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim02)
521 Call(GetStatusFlags, ACTOR_SELF, LVar0)
524 Call(SetPartDispOffset, ACTOR_SELF, PRT_FLYING, -3, 0, 0)
525 Else
526 Call(SetPartDispOffset, ACTOR_SELF, PRT_FLYING, -15, 0, 0)
527 EndIf
528 EndIf
529 SetConst(LVar0, PRT_FLYING)
530 SetConst(LVar1, ANIM_FlyingMagikoopa_Gray_Anim04)
532 Return
535 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
536 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
537 Return
538 End
539};
540
541EvtScript N(EVS_Attack_MagicBlast) = {
542 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
543 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
544 Call(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
545 Call(GetBattlePhase, LVar0)
547 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
548 Call(MoveBattleCamOver, 1)
549 Else
550 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
551 Call(MoveBattleCamOver, 10)
552 EndIf
553 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_SPELL_CAST1)
554 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
555 Call(GetStatusFlags, ACTOR_SELF, LVarA)
557 Sub(LVar0, 12)
558 Add(LVar1, 14)
559 Else
560 Sub(LVar0, 30)
561 Add(LVar1, 36)
562 EndIf
563 PlayEffect(EFFECT_GATHER_MAGIC, 0, LVar0, LVar1, LVar2, Float(0.5), 30, 0)
564 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim02)
565 Wait(30)
566 Call(EnemyTestTarget, ACTOR_SELF, LVar0, 0, 0, 1, BS_FLAGS1_INCLUDE_POWER_UPS)
570 Set(LVarA, LVar0)
571 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_SPELL_CAST2)
572 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim03)
573 Wait(5)
574 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
575 Call(GetStatusFlags, ACTOR_SELF, LVar9)
577 Sub(LVar0, 8)
578 Add(LVar1, 8)
579 Else
580 Sub(LVar0, 20)
581 Add(LVar1, 20)
582 EndIf
583 Call(SetGoalToTarget, ACTOR_SELF)
584 Call(GetGoalPos, ACTOR_SELF, LVar3, LVar4, LVar5)
585 Sub(LVar3, 50)
586 Set(LVar4, 0)
587 Call(N(ShrinkActor), LVar0, LVar1, LVar5, LVar3, LVar4, LVar5, 25)
588 Wait(50)
590 Call(EnemyTestTarget, ACTOR_SELF, LVar0, DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
591 EndIf
592 Wait(14)
593 Call(YieldTurn)
594 Call(AddActorDecoration, ACTOR_SELF, PRT_FLYING, 0, ACTOR_DECORATION_SWEAT)
595 Wait(30)
596 Call(RemoveActorDecoration, ACTOR_SELF, PRT_FLYING, 0)
597 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
598 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
599 Return
602 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_SPELL_CAST2)
603 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim03)
604 Wait(5)
605 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
606 Call(GetStatusFlags, ACTOR_SELF, LVarA)
608 Sub(LVar0, 8)
609 Add(LVar1, 8)
610 Else
611 Sub(LVar0, 20)
612 Add(LVar1, 20)
613 EndIf
614 Call(SetGoalToTarget, ACTOR_SELF)
615 Call(GetGoalPos, ACTOR_SELF, LVar3, LVar4, LVar5)
616 Sub(LVar3, 10)
617 Call(N(ShrinkActor), LVar0, LVar1, LVar5, LVar3, LVar4, LVar5, 20)
618 Wait(18)
619 Wait(2)
620 Call(EnemyDamageTarget, ACTOR_SELF, LVar0, DAMAGE_TYPE_MAGIC | DAMAGE_TYPE_NO_CONTACT, 0, 0, DMG_MAGIC_BLAST, BS_FLAGS1_TRIGGER_EVENTS)
624 Wait(19)
625 Call(YieldTurn)
628 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
629 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
630 Return
631 End
632};
633
634EvtScript N(EVS_Attack_WandStrike) = {
635 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
636 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
637 Call(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
638 Call(UseBattleCamPreset, BTL_CAM_ENEMY_APPROACH)
639 Call(BattleCamTargetActor, ACTOR_SELF)
640 Call(SetBattleCamTargetingModes, BTL_CAM_YADJ_TARGET, BTL_CAM_XADJ_AVG, FALSE)
641 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_MAGIKOOPA_VANISH)
642 Thread
643 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim02)
644 Set(LVar0, 200)
645 Loop(20)
646 Sub(LVar0, 10)
647 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
648 Wait(1)
649 EndLoop
651 Wait(10)
652 Call(SetGoalToTarget, ACTOR_SELF)
653 Call(GetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
654 Call(GetStatusFlags, ACTOR_SELF, LVarA)
656 Add(LVar0, 5)
657 Else
658 Add(LVar0, 25)
659 EndIf
660 Set(LVar1, 0)
661 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
662 Call(FlyToGoal, ACTOR_SELF, 30, 0, EASING_COS_IN_OUT)
663 Set(LVar0, 55)
664 Loop(20)
665 Add(LVar0, 10)
666 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
667 Wait(1)
668 EndLoop
669 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, 255)
670 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim03)
671 Wait(11)
673 Call(EnemyTestTarget, ACTOR_SELF, LVar0, 0, 0, 1, BS_FLAGS1_INCLUDE_POWER_UPS)
677 Set(LVarA, LVar0)
678 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
680 Call(EnemyTestTarget, ACTOR_SELF, LVar0, DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
681 EndIf
682 Wait(15)
683 Set(LVar0, 200)
684 Loop(20)
685 Sub(LVar0, 10)
686 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
687 Wait(1)
688 EndLoop
689 Call(YieldTurn)
690 Call(SetGoalToHome, ACTOR_SELF)
691 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim01)
692 Call(FlyToGoal, ACTOR_SELF, 30, 0, EASING_COS_IN_OUT)
693 Set(LVar0, 55)
694 Loop(20)
695 Add(LVar0, 10)
696 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
697 Wait(1)
698 EndLoop
699 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, 255)
700 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
701 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
702 Return
705 Call(SetGoalToTarget, ACTOR_SELF)
706 Wait(2)
707 Call(EnemyDamageTarget, ACTOR_SELF, LVar0, DAMAGE_TYPE_NO_CONTACT, 0, 0, DMG_WAND_STRIKE, BS_FLAGS1_TRIGGER_EVENTS)
711 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
712 Wait(10)
713 Set(LVar0, 200)
714 Loop(20)
715 Sub(LVar0, 10)
716 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
717 Wait(1)
718 EndLoop
719 Call(YieldTurn)
720 Call(SetGoalToHome, ACTOR_SELF)
721 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim01)
722 Call(FlyToGoal, ACTOR_SELF, 20, 0, EASING_COS_IN_OUT)
723 Set(LVar0, 55)
724 Loop(20)
725 Add(LVar0, 10)
726 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, LVar0)
727 Wait(1)
728 EndLoop
729 Call(SetPartAlpha, ACTOR_SELF, PRT_GROUND, 255)
732 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
733 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
734 Return
735 End
736};
737
738EvtScript N(EVS_Flee) = {
739 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
740 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
741 Call(HideHealthBar, ACTOR_SELF)
742 Call(GetLastEvent, ACTOR_SELF, LVar0)
744 Call(UseBattleCamPreset, BTL_CAM_ACTOR)
745 Call(BattleCamTargetActor, ACTOR_SELF)
746 Call(MoveBattleCamOver, 15)
747 Wait(15)
748 Call(UseBattleCamPreset, BTL_CAM_INTERRUPT)
749 EndIf
750 Call(SetActorSpeed, ACTOR_SELF, Float(1.0))
751 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
752 Add(LVar0, 20)
753 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
754 Call(RunToGoal, ACTOR_SELF, 0, FALSE)
755 Wait(10)
756 Call(SetActorYaw, ACTOR_SELF, 180)
757 Call(EnableActorBlur, ACTOR_SELF, ACTOR_BLUR_ENABLE)
758 Call(SetActorSpeed, ACTOR_SELF, Float(10.0))
759 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
760 Add(LVar0, 200)
761 Call(SetGoalPos, ACTOR_SELF, LVar0, LVar1, LVar2)
762 Call(RunToGoal, ACTOR_SELF, 0, FALSE)
763 Call(YieldTurn)
764 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
766 Call(HideHealthBar, ACTOR_SELF)
767 Call(RemoveActor, ACTOR_SELF)
768 Return
769 End
770};
771
772EvtScript N(EVS_Init) = {
773 Call(BindIdle, ACTOR_SELF, Ref(N(EVS_Idle)))
774 Call(BindTakeTurn, ACTOR_SELF, Ref(N(EVS_TakeTurn)))
775 Call(BindHandleEvent, ACTOR_SELF, Ref(N(EVS_HandleEvent)))
777 IfEq(LVar0, 0)
779 EndIf
780 Call(SetActorVar, ACTOR_SELF, AVAR_ShouldKnockDown, FALSE)
781 Return
782 End
783};
784
785EvtScript N(EVS_Init_Flying) = {
786 Call(BindIdle, ACTOR_SELF, Ref(N(EVS_Idle)))
787 Call(BindTakeTurn, ACTOR_SELF, Ref(N(EVS_TakeTurn)))
788 Call(BindHandleEvent, ACTOR_SELF, Ref(N(EVS_HandleEvent_Flying)))
790 IfEq(LVar0, 0)
792 EndIf
793 Call(SetActorVar, ACTOR_SELF, AVAR_ShouldKnockDown, FALSE)
794 Return
795 End
796};
797
798EvtScript N(EVS_TakeTurn) = {
799 Set(LFlag0, FALSE)
800 Label(10)
801 Call(CreateHomeTargetList, TARGET_FLAG_2 | TARGET_FLAG_PRIMARY_ONLY)
802 Call(InitTargetIterator)
803 Label(0)
804 Call(GetOwnerTarget, LVar0, LVar1)
805 Call(GetIndexFromHome, LVar0, LVar1)
808 Call(N(CheckMagikoopaCastTarget), LVar0, LVar3)
809 IfEq(LVar3, 0)
810 Call(GetStatusFlags, LVar0, LVar4)
812 Set(LVar8, LVar0)
814 Goto(100)
815 EndIf
816 EndIf
817 EndIf
818 Call(ChooseNextTarget, ITER_NEXT, LVar0)
820 Goto(0)
821 EndIf
822 IfEq(LFlag0, FALSE)
823 Set(LFlag0, TRUE)
825 Goto(10)
826 EndIf
828 IfEq(LVar0, 1)
829 ExecWait(N(EVS_Flee))
830 Return
831 EndIf
832 Call(GetActorFlags, ACTOR_SELF, LVar0)
834 ExecWait(N(EVS_Attack_MagicBlast))
835 Else
836 ExecWait(N(EVS_Attack_WandStrike))
837 EndIf
838 Return
839 Label(100) // make ally invisible
840 Call(UseIdleAnimation, ACTOR_SELF, FALSE)
841 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_DISABLE)
842 Call(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
843 Call(UseBattleCamPreset, BTL_CAM_ACTOR)
844 Call(BattleCamTargetActor, ACTOR_SELF)
845 Call(MoveBattleCamOver, 15)
846 Wait(15)
847 Call(GetActorFlags, ACTOR_SELF, LVar0)
849 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim02)
850 Else
851 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim02)
852 EndIf
853 Wait(5)
854 Call(PlaySoundAtActor, ACTOR_SELF, SOUND_SPELL_CAST1)
855 Call(GetActorFlags, ACTOR_SELF, LVar0)
857 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
858 Call(GetStatusFlags, ACTOR_SELF, LVarA)
860 Sub(LVar0, 6)
861 Add(LVar1, 12)
862 Sub(LVar2, 2)
863 PlayEffect(EFFECT_RADIAL_SHIMMER, 6, LVar0, LVar1, LVar2, Float(0.12), 30, 0)
864 Else
865 Sub(LVar0, 16)
866 Add(LVar1, 31)
867 Sub(LVar2, 2)
868 PlayEffect(EFFECT_RADIAL_SHIMMER, 6, LVar0, LVar1, LVar2, Float(0.3), 30, 0)
869 EndIf
870 Else
871 Call(GetActorPos, ACTOR_SELF, LVar0, LVar1, LVar2)
872 Call(GetStatusFlags, ACTOR_SELF, LVarA)
874 Sub(LVar0, 12)
875 Add(LVar1, 14)
876 Sub(LVar2, 2)
877 PlayEffect(EFFECT_RADIAL_SHIMMER, 6, LVar0, LVar1, LVar2, Float(0.12), 30, 0)
878 Else
879 Sub(LVar0, 30)
880 Add(LVar1, 36)
881 Sub(LVar2, 2)
882 PlayEffect(EFFECT_RADIAL_SHIMMER, 6, LVar0, LVar1, LVar2, Float(0.3), 30, 0)
883 EndIf
884 EndIf
885 Wait(30)
886 Call(GetActorFlags, ACTOR_SELF, LVar0)
888 Call(SetAnimation, ACTOR_SELF, PRT_GROUND, ANIM_Magikoopa_Gray_Anim01)
889 Else
890 Call(SetAnimation, ACTOR_SELF, PRT_FLYING, ANIM_FlyingMagikoopa_Gray_Anim01)
891 EndIf
892 Wait(5)
893 Thread
894 Wait(10)
895 Call(PlaySoundAtActor, LVar8, SOUND_MAGIKOOPA_VANISH)
897 Thread
898 Call(FreezeBattleState, TRUE)
899 Call(VanishActor, LVar8, 2)
900 Call(FreezeBattleState, FALSE)
902 Call(WaitForBuffDone)
903 Call(UseBattleCamPreset, BTL_CAM_DEFAULT)
904 Wait(10)
905 Call(YieldTurn)
906 Call(EnableIdleScript, ACTOR_SELF, IDLE_SCRIPT_ENABLE)
907 Call(UseIdleAnimation, ACTOR_SELF, TRUE)
908 Return
909 End
910};
Bytecode EvtScript[]
#define STATUS_FLAGS_IMMOBILIZED
Definition enums.h:2834
@ BTL_CAM_XADJ_AVG
Definition enums.h:4900
@ BS_FLAGS1_PARTNER_ACTING
Definition enums.h:3588
@ BS_FLAGS1_SUPER_HIT
Definition enums.h:3579
@ BS_FLAGS1_NICE_HIT
Definition enums.h:3576
@ BS_FLAGS1_TRIGGER_EVENTS
Definition enums.h:3575
@ BS_FLAGS1_INCLUDE_POWER_UPS
Definition enums.h:3571
@ ELEMENT_END
Definition enums.h:2114
@ ELEMENT_NORMAL
Definition enums.h:2115
@ ITER_NO_MORE
Definition enums.h:2030
@ ITER_NEXT
Definition enums.h:2025
@ ACTOR_EVENT_FLAG_RIDING_BROOMSTICK
Actor is on Magikoopa Broomstick, effect seems to be redundant.
Definition enums.h:3390
@ ACTOR_DECORATION_SWEAT
Definition enums.h:2045
@ PHASE_FIRST_STRIKE
Definition enums.h:2059
@ STATUS_KEY_PARALYZE
Definition enums.h:2201
@ STATUS_TURN_MOD_DEFAULT
Definition enums.h:2227
@ STATUS_TURN_MOD_PARALYZE
Definition enums.h:2234
@ STATUS_KEY_FROZEN
Definition enums.h:2203
@ STATUS_TURN_MOD_SLEEP
Definition enums.h:2228
@ STATUS_TURN_MOD_DIZZY
Definition enums.h:2232
@ STATUS_KEY_STATIC
Definition enums.h:2207
@ STATUS_END
Definition enums.h:2196
@ STATUS_TURN_MOD_POISON
Definition enums.h:2233
@ STATUS_KEY_FEAR
Definition enums.h:2199
@ STATUS_TURN_MOD_STOP
Definition enums.h:2237
@ STATUS_KEY_SLEEP
Definition enums.h:2202
@ STATUS_KEY_STONE
Definition enums.h:2208
@ STATUS_KEY_STOP
Definition enums.h:2204
@ STATUS_TURN_MOD_FROZEN
Definition enums.h:2230
@ STATUS_KEY_SHRINK
Definition enums.h:2206
@ STATUS_KEY_DIZZY
Definition enums.h:2200
@ STATUS_KEY_POISON
Definition enums.h:2205
@ STATUS_TURN_MOD_STATIC
Definition enums.h:2229
@ STATUS_TURN_MOD_FEAR
Definition enums.h:2231
@ STATUS_KEY_NORMAL
Definition enums.h:2197
@ STATUS_TURN_MOD_SHRINK
Definition enums.h:2235
@ STATUS_KEY_DEFAULT
Definition enums.h:2198
@ HIT_RESULT_NO_DAMAGE
Definition enums.h:1952
@ HIT_RESULT_HIT
Definition enums.h:1950
@ HIT_RESULT_LUCKY
Definition enums.h:1955
@ HIT_RESULT_MISS
Definition enums.h:1956
@ BTL_CAM_DEFAULT
Definition enums.h:4824
@ BTL_CAM_INTERRUPT
Definition enums.h:4823
@ BTL_CAM_ACTOR
Definition enums.h:4836
@ BTL_CAM_ENEMY_APPROACH
Definition enums.h:4885
@ TARGET_FLAG_PRIMARY_ONLY
Definition enums.h:1863
@ TARGET_FLAG_2
Definition enums.h:1850
@ EASING_COS_IN_OUT
Definition enums.h:520
@ EASING_LINEAR
Definition enums.h:510
@ IDLE_SCRIPT_ENABLE
Definition enums.h:6408
@ IDLE_SCRIPT_DISABLE
Definition enums.h:6407
@ STATUS_FLAG_STATIC
Definition enums.h:2813
@ STATUS_FLAG_SHRINK
Definition enums.h:2819
@ STATUS_FLAG_TRANSPARENT
Definition enums.h:2825
@ SOUND_MAGIKOOPA_WAND_STRIKE
Definition enums.h:1054
@ SOUND_SPELL_CAST1
Definition enums.h:1498
@ SOUND_SPELL_CAST2
Definition enums.h:1499
@ SOUND_MAGIKOOPA_VANISH
Definition enums.h:1053
@ SOUND_FALL_QUICK
Definition enums.h:1090
@ ACTOR_PLAYER
Definition enums.h:2085
@ ACTOR_SELF
Definition enums.h:2084
@ ACTOR_FLAG_FLYING
Quake Hammer can't hit.
Definition enums.h:3329
@ ACTOR_FLAG_TYPE_CHANGED
Indicates actors type has changed, triggers recheck for if HP bar should be shown based on tattle sta...
Definition enums.h:3332
@ BTL_CAM_YADJ_TARGET
Definition enums.h:4905
@ ACTOR_BLUR_ENABLE
Definition enums.h:6414
@ EVENT_HIT
Definition enums.h:2132
@ EVENT_SCARE_AWAY
Definition enums.h:2174
@ EVENT_BURN_HIT
Definition enums.h:2136
@ EVENT_BEGIN_FIRST_STRIKE
Definition enums.h:2173
@ EVENT_END_FIRST_STRIKE
Definition enums.h:2171
@ EVENT_IMMUNE
Definition enums.h:2146
@ EVENT_FALL_TRIGGER
Definition enums.h:2134
@ EVENT_BURN_DEATH
Definition enums.h:2157
@ EVENT_ZERO_DAMAGE
Definition enums.h:2144
@ EVENT_SPIN_SMASH_HIT
Definition enums.h:2133
@ EVENT_SPIN_SMASH_DEATH
Definition enums.h:2154
@ EVENT_HIT_COMBO
Definition enums.h:2131
@ EVENT_15
Definition enums.h:2137
@ EVENT_AIR_LIFT_FAILED
Definition enums.h:2152
@ EVENT_BEGIN_AIR_LIFT
Definition enums.h:2175
@ EVENT_DEATH
Definition enums.h:2153
@ EVENT_RECOVER_STATUS
Definition enums.h:2167
@ EVENT_BLOW_AWAY
Definition enums.h:2143
@ ACTOR_PART_FLAG_PRIMARY_TARGET
Definition enums.h:3362
@ ACTOR_PART_FLAG_USE_ABSOLUTE_POSITION
Definition enums.h:3361
@ ACTOR_PART_FLAG_NO_TARGET
Cannot be targeted.
Definition enums.h:3360
@ ACTOR_PART_FLAG_INVISIBLE
Definition enums.h:3350
@ CAM_BATTLE
Definition enums.h:1801
@ DAMAGE_TYPE_POW
Definition enums.h:2861
@ DAMAGE_TYPE_MAGIC
Definition enums.h:2855
@ DAMAGE_TYPE_TRIGGER_LUCKY
Definition enums.h:2881
@ DAMAGE_TYPE_NO_CONTACT
Definition enums.h:2878
EvtScript EVS_Enemy_Hit
EvtScript EVS_Enemy_Death
EvtScript EVS_Enemy_SpinSmashHit
EvtScript EVS_Enemy_AirLift
EvtScript EVS_ForceNextTarget
EvtScript EVS_Enemy_BlowAway
EvtScript EVS_Enemy_Recover
EvtScript EVS_Enemy_BurnHit
EvtScript EVS_Enemy_NoDamageHit
ApiStatus ShakeCam(Evt *script, b32 isInitialCall)
#define Else
Marks the end of an if statement and the start of the else block.
Definition macros.h:295
#define Switch(LVAR)
Marks the start of a switch statement.
Definition macros.h:311
#define Ref(sym)
Address/pointer constant.
Definition macros.h:60
#define Set(VAR, INT_VALUE)
Sets the given variable to a given value casted to an integer.
Definition macros.h:365
#define CaseEq(RVAR)
Marks the start of a switch case that executes only if LVAR == RVAR. It also marks the end of any pre...
Definition macros.h:319
#define Sub(VAR, INT_VALUE)
Definition macros.h:377
#define IfNe(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR != RVAR.
Definition macros.h:272
#define End
Signals the end of EVT script data. A script missing this will likely crash on load.
Definition macros.h:213
#define Mod(VAR, INT_VALUE)
Definition macros.h:380
#define Add(VAR, INT_VALUE)
Definition macros.h:376
#define EndLoop
Marks the end of a loop.
Definition macros.h:248
#define EndCaseGroup
Marks the end of a switch case group (CaseOrEq and/or CaseAndEq), stopping fallthrough.
Definition macros.h:352
#define Goto(LABEL_ID)
Moves execution to the given label.
Definition macros.h:232
#define ARRAY_COUNT(arr)
Definition macros.h:40
#define IfGt(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR <= RVAR.
Definition macros.h:278
#define Float(DOUBLE)
Definition macros.h:51
#define Label(LABEL_ID)
Marks this point in the script as a Goto target.
Definition macros.h:227
#define CaseOrEq(RVAR)
Marks the start of a switch case that executes only if LVAR == RVAR.
Definition macros.h:341
#define EndIf
Marks the end of an if statement or an else block.
Definition macros.h:298
#define LVar5
Definition macros.h:153
#define CaseDefault
Marks the start of a switch case that executes unconditionally. It also marks the end of any previous...
Definition macros.h:337
#define ExecWait(EVT_SOURCE)
Launches a new child thread.
Definition macros.h:475
#define Thread
Marks the start of a thread block.
Definition macros.h:544
#define EndThread
Marks the end of a thread block.
Definition macros.h:547
#define IfFlag(LVAR, RVAR)
Marks the beginning of an if statement that only executes if the RVAR flag is set on LVAR,...
Definition macros.h:288
#define LVar8
Definition macros.h:156
#define LVar2
Definition macros.h:150
#define LVar1
Definition macros.h:149
#define LFlag0
Definition macros.h:167
#define LVarA
Definition macros.h:158
#define IfNotFlag(LVAR, RVAR)
Marks the beginning of an if statement that only executes if the RVAR flag is unset on LVAR,...
Definition macros.h:292
#define Wait(NUM_FRAMES)
Blocks for the given number of frames.
Definition macros.h:254
#define LVar9
Definition macros.h:157
#define PlayEffect(args...)
Definition macros.h:807
#define EndSwitch
Marks the end of a switch statement and any case.
Definition macros.h:362
#define IfEq(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR == RVAR.
Definition macros.h:269
#define Call(FUNC, ARGS...)
Calls a given C EVT API function with any number of arguments.
Definition macros.h:576
#define Loop(TIMES)
Marks the beginning of a loop.
Definition macros.h:245
#define LVar4
Definition macros.h:152
#define LVar3
Definition macros.h:151
#define LVar0
Definition macros.h:148
#define SetConst(VAR, CONST)
Sets the given variable to a given value, skipping the evt_get_variable call.
Definition macros.h:370
#define Return
Kills the current EVT thread.
Definition macros.h:217
@ BTL_VAR_Magikoopa_LastIndexBoosted
Definition battle.h:90