mirror of
https://github.com/pmret/papermario.git
synced 2024-11-08 12:02:30 +01:00
Disassemble Various Data Files (#616)
* Disassemble IWA Battle Map * Disassemble SBK Battle Map * Disassemble Quake Hammer * Disassemble jump.c * Disassemble Hammer Action Command * Some Labelling * Fix symbol_addrs * Disassemble ISK Part 1 Battle Map * Restore symbol_addrs
This commit is contained in:
parent
fdf0ed245b
commit
36e5315fdc
@ -601,7 +601,7 @@ EffectInstance* playFX_1C(s32, f32, f32, f32, s32);
|
||||
void playFX_1D(s32, f32, f32, f32, f32, s32, f32, s32);
|
||||
EffectInstance* playFX_1E(s32, f32, f32, f32, f32, f32, s32, s32*);
|
||||
EffectInstance* playFX_1F(s32, f32, f32, f32, f32, f32, f32, f32);
|
||||
EffectInstance* playFX_20(s32, f32, f32, f32, f32, EffectInstance*);
|
||||
EffectInstance* playFX_20(s32, f32, f32, f32, f32, EffectInstance**);
|
||||
EffectInstance* playFX_21(s32, f32, f32, f32, f32, f32, s32);
|
||||
void playFX_22(s32, f32, f32, f32, f32, f32, s32, s32);
|
||||
EffectInstance* playFX_23(u32, f32, f32, f32, f32);
|
||||
|
@ -1072,6 +1072,24 @@ enum PlayerAnims {
|
||||
ANIM_30004 = 0x00030004,
|
||||
ANIM_30008 = 0x00030008,
|
||||
ANIM_30009 = 0x00030009,
|
||||
ANIM_3000D = 0x0003000D,
|
||||
ANIM_3000E = 0x0003000E,
|
||||
ANIM_3000F = 0x0003000F,
|
||||
ANIM_30010 = 0x00030010,
|
||||
ANIM_30011 = 0x00030011,
|
||||
ANIM_30012 = 0x00030012,
|
||||
ANIM_30014 = 0x00030014,
|
||||
ANIM_30015 = 0x00030015,
|
||||
ANIM_30016 = 0x00030016,
|
||||
ANIM_30017 = 0x00030017,
|
||||
ANIM_30018 = 0x00030018,
|
||||
ANIM_30019 = 0x00030019,
|
||||
ANIM_3001B = 0x0003001B,
|
||||
ANIM_3001C = 0x0003001C,
|
||||
ANIM_3001D = 0x0003001D,
|
||||
ANIM_3001E = 0x0003001E,
|
||||
ANIM_3001F = 0x0003001F,
|
||||
ANIM_30020 = 0x00030020,
|
||||
ANIM_80003 = 0x00080003,
|
||||
ANIM_80007 = 0x00080007,
|
||||
ANIM_8000B = 0x0008000B,
|
||||
@ -1515,6 +1533,8 @@ enum PlayerBuffs {
|
||||
|
||||
enum StatusFlags {
|
||||
STATUS_FLAG_1 = 0x00000001,
|
||||
STATUS_FLAG_100 = 0x00000100,
|
||||
STATUS_FLAG_200 = 0x00000200,
|
||||
STATUS_FLAG_SLEEP = 0x00001000,
|
||||
STATUS_FLAG_STATIC = 0x00002000,
|
||||
STATUS_FLAG_FROZEN = 0x00004000,
|
||||
@ -1532,6 +1552,7 @@ enum StatusFlags {
|
||||
STATUS_FLAG_DEFENSE_BOOST = 0x10000000,
|
||||
STATUS_FLAG_CHILL_OUT = 0x20000000,
|
||||
STATUS_FLAG_RIGHT_ON = 0x40000000,
|
||||
STATUS_FLAG_80000000 = 0x80000000,
|
||||
};
|
||||
|
||||
enum DamageTypes {
|
||||
|
@ -59,6 +59,7 @@ ApiStatus SetActionSuccess(Evt* script, s32 isInitialCall);
|
||||
ApiStatus GetActionSuccessCopy(Evt* script, s32 isInitialCall);
|
||||
ApiStatus GetBlockResult(Evt* script, s32 isInitialCall);
|
||||
ApiStatus CloseActionCommandInfo(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_80269470(Evt* script, s32 isInitialCall);
|
||||
ApiStatus LoadBattleSection(Evt* script, s32 isInitialCall);
|
||||
ApiStatus GetBattlePhase(Evt* script, s32 isInitialCall);
|
||||
ApiStatus GetLastElement(Evt* script, s32 isInitialCall);
|
||||
@ -321,6 +322,8 @@ ApiStatus PlayLoopingSoundAtActor(Evt* script, s32 isInitialCall);
|
||||
ApiStatus StopLoopingSoundAtActor(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_8026ED20(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_8026EBF8(Evt* script, s32 isInitialCall);
|
||||
ApiStatus SetupMashMeter(Evt* script, s32 isInitialCall);
|
||||
ApiStatus SetActionResult(Evt* script, s32 isInitialCall);
|
||||
|
||||
extern EvtSource PlayerScriptDispatcher;
|
||||
extern EvtSource PeachScriptDispatcher;
|
||||
@ -369,6 +372,7 @@ extern EvtSource D_802976E8;
|
||||
extern EvtSource D_8029C12C;
|
||||
extern EvtSource DoBurnHit;
|
||||
extern EvtSource DoShockHit;
|
||||
extern EvtSource D_8029A76C;
|
||||
extern EvtSource D_80294720;
|
||||
extern EvtSource DoImmune;
|
||||
extern EvtSource DoDeath;
|
||||
|
@ -50,8 +50,7 @@ Gfx D_80074580[] = {
|
||||
gsSPEndDisplayList(),
|
||||
};
|
||||
|
||||
void sin_cos_rad(f32 rad, f32* outSinTheta, f32* outCosTheta);
|
||||
void dma_write_block(s32 romStart, s32 vramDest, s32 length);
|
||||
void dma_write_block(s32 dramAddr, s32 devAddr, s32 size);
|
||||
|
||||
#define ROM_CHUNK_SIZE 0x2000
|
||||
|
||||
|
8
src/battle/action_cmd/break_free.h
Normal file
8
src/battle/action_cmd/break_free.h
Normal file
@ -0,0 +1,8 @@
|
||||
#ifndef _BREAK_FREE_H_
|
||||
#define _BREAK_FREE_H_
|
||||
|
||||
#include "common_structs.h"
|
||||
|
||||
ApiStatus func_802A91B0_4235A0(Evt* script, s32 isInitialCall);
|
||||
|
||||
#endif
|
9
src/battle/action_cmd/hammer.h
Normal file
9
src/battle/action_cmd/hammer.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef _HAMMER_H_
|
||||
#define _HAMMER_H_
|
||||
|
||||
#include "common_structs.h"
|
||||
|
||||
ApiStatus action_command_hammer_CreateHudElements(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802A9258_422258(Evt* script, s32 isInitialCall);
|
||||
|
||||
#endif
|
9
src/battle/action_cmd/whirlwind.h
Normal file
9
src/battle/action_cmd/whirlwind.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef _WHIRLWIND_H_
|
||||
#define _WHIRLWIND_H_
|
||||
|
||||
#include "common_structs.h"
|
||||
|
||||
ApiStatus func_802A9000_423C70(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802A91E0_423E50(Evt* script, s32 isInitialCall);
|
||||
|
||||
#endif
|
@ -7,8 +7,8 @@
|
||||
|
||||
s32 N(defenseTable_8021ACB0)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_WATER, 4294967294,
|
||||
ELEMENT_ICE, 4294967294,
|
||||
ELEMENT_WATER, -2,
|
||||
ELEMENT_ICE, -2,
|
||||
ELEMENT_FIRE, 99,
|
||||
ELEMENT_END,
|
||||
};
|
||||
@ -278,7 +278,7 @@ EvtSource N(8021B398) = {
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_8021B594) = { 0, 0xFFFFFC18, 0, };
|
||||
Vec3i N(vector3D_8021B594) = { 0, -1000, 0, };
|
||||
|
||||
Formation N(specialFormation_8021B5A0) = {
|
||||
{ .actor = &NAMESPACE, .home = { .vec = &N(vector3D_8021B594) }},
|
||||
|
@ -1,5 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
#define NAMESPACE dup_b_area_isk_part_1
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
||||
#define NAMESPACE b_area_isk_part_1
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
#define NAMESPACE dup2_b_area_isk_part_1
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
||||
#define NAMESPACE b_area_isk_part_1
|
@ -1,34 +0,0 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
extern EffectInstance* D_80224D60;
|
||||
extern EffectInstance* D_80224D64;
|
||||
extern s32 D_80224920_4EF060;
|
||||
|
||||
#include "common/ChompChainInit.inc.c"
|
||||
|
||||
#include "common/ChompChainUpdateHelperFunc.inc.c"
|
||||
|
||||
#include "common/ChompChainUpdateHelperFunc2.inc.c"
|
||||
|
||||
INCLUDE_ASM(s32, "battle/area_isk_part_1/4E29B0", b_area_isk_part_1_ChompChainUpdate);
|
||||
|
||||
// Clover's suggestion: isk_bt04_CreateTorchFX
|
||||
// Reason: this sort of additional namespacing is required because the isk battle source includes the data for each of the stages
|
||||
// if these were regular maps, theyd have their own source files
|
||||
ApiStatus func_802188B0_4E2FF0(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -133.0f, 72.0f, -143.0f, 0.3f, &D_80224D60);
|
||||
playFX_20(1, 129.0f, 72.0f, -143.0f, 0.3f, &D_80224D64);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
// Clover's suggestion: isk_bt04_DeleteTorchFX
|
||||
// Reason: this sort of additional namespacing is required because the isk battle source includes the data for each of the stages
|
||||
// if these were regular maps, theyd have their own source files
|
||||
ApiStatus func_80218944_4E3084(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224D60);
|
||||
remove_effect(D_80224D64);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
@ -1,19 +0,0 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
extern EffectInstance* D_80224D70;
|
||||
extern EffectInstance* D_80224D74;
|
||||
|
||||
ApiStatus func_80218980_4E30C0(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -90.0f, 45.0f, -146.0f, 0.25f, &D_80224D70);
|
||||
playFX_20(1, 80.0f, 45.0f, -146.0f, 0.25f, &D_80224D74);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218A10_4E3150(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224D70);
|
||||
remove_effect(D_80224D74);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
@ -1,49 +0,0 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
extern EffectInstance* D_80224D80;
|
||||
extern EffectInstance* D_80224D90;
|
||||
extern EffectInstance* D_80224DA0;
|
||||
extern EffectInstance* D_80224DB0;
|
||||
|
||||
ApiStatus func_80218A50_4E3190(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -110.0f, 80.0f, -146.0f, 0.3f, &D_80224D80);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218A98_4E31D8(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224D80);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218AC0_4E3200(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, 110.0f, 80.0f, -146.0f, 0.3f, &D_80224D90);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218B08_4E3248(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224D90);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218B30_4E3270(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -110.0f, 80.0f, -146.0, 0.3f, &D_80224DA0);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218B78_4E32B8(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224DA0);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218BA0_4E32E0(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, 0, 72.0f, -146.0, 0.3f, &D_80224DB0);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218BE8_4E3328(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(D_80224DB0);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
822
src/battle/area_isk_part_1/actor/buzzy_beetle.c
Normal file
822
src/battle/area_isk_part_1/actor/buzzy_beetle.c
Normal file
@ -0,0 +1,822 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/buzzy_beetle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_buzzy_beetle
|
||||
|
||||
extern s32 N(idleAnimations_8021E62C)[];
|
||||
extern EvtSource N(init_8021E6BC);
|
||||
extern EvtSource N(idle_8021E88C);
|
||||
extern EvtSource N(takeTurn_8021FF8C);
|
||||
extern EvtSource N(handleEvent_8021ECD0);
|
||||
extern EvtSource N(takeTurn_80220A44);
|
||||
extern EvtSource N(handleEvent_8021F228);
|
||||
|
||||
s32 N(defenseTable_8021E4C0)[] = {
|
||||
ELEMENT_NORMAL, 2,
|
||||
ELEMENT_FIRE, 99,
|
||||
ELEMENT_BLAST, 99,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8021E4DC)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_8021E4E8)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 90,
|
||||
STATUS_POISON, 50,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 75,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 50,
|
||||
STATUS_PARALYZE, 75,
|
||||
STATUS_SHRINK, 90,
|
||||
STATUS_STOP, 90,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 0,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021E594)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 16 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021E62C),
|
||||
.defenseTable = N(defenseTable_8021E4C0),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_FLIPABLE,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 263,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = ACTOR_FLAG_HP_OFFSET_BELOW,
|
||||
.type = ACTOR_TYPE_BUZZY_BEETLE,
|
||||
.level = 10,
|
||||
.maxHP = 3,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021E594)),
|
||||
.partsData = N(partsTable_8021E594),
|
||||
.script = N(init_8021E6BC),
|
||||
.statusTable = N(statusTable_8021E4E8),
|
||||
.escapeChance = 60,
|
||||
.airLiftChance = 75,
|
||||
.spookChance = 75,
|
||||
.baseStatusChance = 75,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 90,
|
||||
.coinReward = 1,
|
||||
.size = { 22, 18 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -8, 16 },
|
||||
.statusMessageOffset = { 8, 13 },
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021E5E0)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_buzzy_beetle_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_9,
|
||||
STATUS_POISON, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_buzzy_beetle_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_buzzy_beetle_Palette_00_Anim_A,
|
||||
STATUS_FEAR, NPC_ANIM_buzzy_beetle_Palette_00_Anim_A,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021E62C)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_buzzy_beetle_Palette_00_Anim_F,
|
||||
STATUS_STONE, NPC_ANIM_buzzy_beetle_Palette_00_Anim_E,
|
||||
STATUS_SLEEP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_14,
|
||||
STATUS_POISON, NPC_ANIM_buzzy_beetle_Palette_00_Anim_F,
|
||||
STATUS_STOP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_E,
|
||||
STATUS_STATIC, NPC_ANIM_buzzy_beetle_Palette_00_Anim_F,
|
||||
STATUS_PARALYZE, NPC_ANIM_buzzy_beetle_Palette_00_Anim_E,
|
||||
STATUS_DIZZY, NPC_ANIM_buzzy_beetle_Palette_00_Anim_15,
|
||||
STATUS_FEAR, NPC_ANIM_buzzy_beetle_Palette_00_Anim_15,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021E678)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_buzzy_beetle_Palette_00_Anim_2,
|
||||
STATUS_STONE, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1A,
|
||||
STATUS_SLEEP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1B,
|
||||
STATUS_POISON, NPC_ANIM_buzzy_beetle_Palette_00_Anim_2,
|
||||
STATUS_STOP, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1A,
|
||||
STATUS_STATIC, NPC_ANIM_buzzy_beetle_Palette_00_Anim_2,
|
||||
STATUS_DIZZY, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1C,
|
||||
STATUS_FEAR, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1C,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
||||
|
||||
EvtSource N(init_8021E6BC) = {
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021E88C)))
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_CALL(N(UnkBattleFunc1), -10, 0, 10, 0)
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_8021FF8C)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021ECD0)))
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_FLIPABLE, 0)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 1)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 16)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, -1, -9)
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80220A44)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021F228)))
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021E5E0)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_FLIPABLE, 1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_8021E88C) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021E89C) = {
|
||||
EVT_CALL(func_8027D32C, ACTOR_SELF)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 2)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 16)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, -1, -9)
|
||||
EVT_CALL(N(UnkBattleFunc1), -10, 20, 10, 20)
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80220A44)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021F228)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 9, 1)
|
||||
EVT_CALL(SetDefenseTable, ACTOR_SELF, 1, EVT_ADDR(N(defenseTable_8021E4DC)))
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021E678)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_SPIKY_TOP, 0)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_FLIPABLE, 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_400, 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_8)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_SELF, 2, 769, 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(GetIndexFromPos, ACTOR_SELF, LW(10))
|
||||
EVT_MOD(LW(10), 4)
|
||||
EVT_CALL(SetGoalToIndex, ACTOR_SELF, LW(10))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_CALL(SetHomePos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_SET(LW(13), LW(10))
|
||||
EVT_SET(LW(14), LW(11))
|
||||
EVT_SET(LW(15), LW(12))
|
||||
EVT_SUB(LW(13), LW(0))
|
||||
EVT_SUB(LW(14), LW(1))
|
||||
EVT_SUB(LW(15), LW(2))
|
||||
EVT_DIV(LW(13), 2)
|
||||
EVT_DIV(LW(14), 2)
|
||||
EVT_DIV(LW(15), 2)
|
||||
EVT_ADD(LW(0), LW(13))
|
||||
EVT_ADD(LW(1), LW(14))
|
||||
EVT_ADD(LW(2), LW(15))
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021ECD0) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CASE_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_EXEC_WAIT(N(8021E89C))
|
||||
EVT_CASE_EQ(EVENT_FLIP_TRIGGER)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_EXEC_WAIT(N(8021E89C))
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_18)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_EXEC_WAIT(N(8021E89C))
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_18)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_16)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CASE_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_16)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_STOP)
|
||||
EVT_EXEC_WAIT(N(8021E89C))
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_FLYING, 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_11)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_13)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021F18C) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(3))
|
||||
EVT_IF_EQ(LW(3), 2)
|
||||
EVT_SET(LW(1), LW(2))
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(intTable_8021F1DC)[] = {
|
||||
7, 13, 17, 21, 23, 24, 23, 21, 17, 13,
|
||||
7, 0, 4, 7, 6, 4, 0, 2, 0,
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021F228) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_NE(LW(0), 2)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_B)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1D)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1D)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_NE(LW(0), 2)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_B)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1D)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1D)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1D)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CASE_EQ(EVENT_FLIP_TRIGGER)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 2)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 16)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, -1, -9)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 9, 1)
|
||||
EVT_CALL(SetDefenseTable, ACTOR_SELF, 1, EVT_ADDR(N(defenseTable_8021E4DC)))
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021E678)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_400, 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 12, 0)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, -45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, -90)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, -135)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, -180)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_THREAD
|
||||
EVT_USE_BUF(EVT_ADDR(N(intTable_8021F1DC)))
|
||||
EVT_LOOP(19)
|
||||
EVT_BUF_READ1(LW(0))
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, LW(0), 0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_C)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_17)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_IMMUNE)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_C)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_D)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIKE_TAUNT)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(3))
|
||||
EVT_IF_FLAG(LW(3), STATUS_FLAG_SHRINK)
|
||||
EVT_ADD(LW(1), 9)
|
||||
EVT_ELSE
|
||||
EVT_ADD(LW(1), 24)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1A, 0, LW(0), LW(1), LW(2), 20, 0, 0, 0, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_19)
|
||||
EVT_EXEC_WAIT(N(8021F18C))
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_END_IF
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_7)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_8)
|
||||
EVT_END_IF
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_C)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_D)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_IF
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_8021FF8C) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 1)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 16)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, -1, -9)
|
||||
EVT_CALL(N(UnkBattleFunc1), -10, 20, 10, 20)
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80220A44)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021F228)))
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021E5E0)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_FLIPABLE, 1)
|
||||
EVT_CALL(GetIndexFromPos, ACTOR_SELF, LW(0))
|
||||
EVT_MOD(LW(0), 4)
|
||||
EVT_CALL(SetGoalToIndex, ACTOR_SELF, LW(0))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetHomePos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(4), LW(2))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_E)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_11)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(4), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(6.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_E)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetActorSounds, ACTOR_SELF, 2, 769, 0)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_F)
|
||||
EVT_CALL(SetBattleCamZoom, 430)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 20)
|
||||
EVT_CALL(MoveBattleCamOver, 10)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 3, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(SetPartYaw, ACTOR_SELF, 1, 180)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_8)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_0)
|
||||
EVT_END_THREAD
|
||||
EVT_ADD(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(6.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_8)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(1), LW(4))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 65535, 0, 3, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_0)
|
||||
EVT_END_THREAD
|
||||
EVT_ADD(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_LABEL(10)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_80220A44) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 2)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 9, LW(0))
|
||||
EVT_SUB(LW(0), 1)
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 9, LW(0))
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_WAIT_FRAMES(30)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_ELSE
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_2)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(D_8029BBB4)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 1)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 16)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, -1, -9)
|
||||
EVT_CALL(SetDefenseTable, ACTOR_SELF, 1, EVT_ADDR(N(defenseTable_8021E4C0)))
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021E5E0)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021E88C)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_400, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_C)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_6)
|
||||
EVT_THREAD
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2021)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_5)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetActorSounds, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x20D3)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 2, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_THREAD
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_IF_GT(LW(0), LW(3))
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_B)
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, -150, 0, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(14.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 200)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(10.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_D)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(14.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 65535, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 40)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_ADD(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 6, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_buzzy_beetle_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_buzzy_beetle_Palette_00_Anim_1)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
1005
src/battle/area_isk_part_1/actor/pokey_mummy.c
Normal file
1005
src/battle/area_isk_part_1/actor/pokey_mummy.c
Normal file
File diff suppressed because it is too large
Load Diff
746
src/battle/area_isk_part_1/actor/stone_chomp.c
Normal file
746
src/battle/area_isk_part_1/actor/stone_chomp.c
Normal file
@ -0,0 +1,746 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/stone_chomp.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_stone_chomp
|
||||
|
||||
extern EvtSource N(init_80221ABC);
|
||||
extern EvtSource N(takeTurn_80222ED0);
|
||||
extern EvtSource N(idle_80221D00);
|
||||
extern EvtSource N(handleEvent_80222364);
|
||||
extern EvtSource N(8022181C);
|
||||
extern EvtSource N(80222324);
|
||||
|
||||
s32 N(idleAnimations_80221450)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_stone_chomp_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_stone_chomp_Palette_00_Anim_A,
|
||||
STATUS_POISON, NPC_ANIM_stone_chomp_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_stone_chomp_Palette_00_Anim_1,
|
||||
STATUS_DIZZY, NPC_ANIM_stone_chomp_Palette_00_Anim_B,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8022148C)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_stone_chomp_Palette_00_Anim_3,
|
||||
STATUS_POISON, NPC_ANIM_stone_chomp_Palette_00_Anim_3,
|
||||
STATUS_STOP, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_STONE, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_stone_chomp_Palette_00_Anim_A,
|
||||
STATUS_STATIC, NPC_ANIM_stone_chomp_Palette_00_Anim_3,
|
||||
STATUS_DIZZY, NPC_ANIM_stone_chomp_Palette_00_Anim_B,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_802214C8)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_stone_chomp_Palette_00_Anim_4,
|
||||
STATUS_POISON, NPC_ANIM_stone_chomp_Palette_00_Anim_4,
|
||||
STATUS_STOP, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_STONE, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_stone_chomp_Palette_00_Anim_A,
|
||||
STATUS_STATIC, NPC_ANIM_stone_chomp_Palette_00_Anim_4,
|
||||
STATUS_DIZZY, NPC_ANIM_stone_chomp_Palette_00_Anim_B,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_80221504)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_stone_chomp_Palette_00_Anim_5,
|
||||
STATUS_POISON, NPC_ANIM_stone_chomp_Palette_00_Anim_5,
|
||||
STATUS_STOP, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_STONE, NPC_ANIM_stone_chomp_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_stone_chomp_Palette_00_Anim_A,
|
||||
STATUS_STATIC, NPC_ANIM_stone_chomp_Palette_00_Anim_5,
|
||||
STATUS_DIZZY, NPC_ANIM_stone_chomp_Palette_00_Anim_B,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_80221540)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_stone_chomp_Palette_00_Anim_2,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8022154C)[] = {
|
||||
ELEMENT_NORMAL, 1,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_80221558)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 0,
|
||||
STATUS_POISON, 0,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 75,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 0,
|
||||
STATUS_PARALYZE, 50,
|
||||
STATUS_SHRINK, 75,
|
||||
STATUS_STOP, 75,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, -1,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, -1,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, -1,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_80221604)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_NO_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 24 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221450),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_100000 | ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 2,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { -13, 40 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221450),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 242,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 3,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 4,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 5,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 6,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 7,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 8,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 9,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2 | ACTOR_PART_FLAG_4000 | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 10,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80221540),
|
||||
.defenseTable = N(defenseTable_8022154C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = 0,
|
||||
.type = ACTOR_TYPE_STONE_CHOMP,
|
||||
.level = 14,
|
||||
.maxHP = 4,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_80221604)),
|
||||
.partsData = N(partsTable_80221604),
|
||||
.script = N(init_80221ABC),
|
||||
.statusTable = N(statusTable_80221558),
|
||||
.escapeChance = 0,
|
||||
.airLiftChance = 25,
|
||||
.spookChance = 25,
|
||||
.baseStatusChance = 0,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 85,
|
||||
.coinReward = 5,
|
||||
.size = { 56, 40 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 20 },
|
||||
.statusMessageOffset = { 10, 20 },
|
||||
};
|
||||
|
||||
#include "common/ChompChainInit.inc.c"
|
||||
|
||||
#include "common/ChompChainUpdateHelperFunc.inc.c"
|
||||
|
||||
#include "common/ChompChainUpdateHelperFunc2.inc.c"
|
||||
|
||||
ApiStatus b_area_isk_part_1_ChompChainUpdate(Evt* script, s32 isInitialCall);
|
||||
INCLUDE_ASM(s32, "battle/area_isk_part_1/4E29B0", b_area_isk_part_1_ChompChainUpdate);
|
||||
|
||||
EvtSource N(80221794) = {
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, LW(0), LW(1))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(2.0))
|
||||
EVT_EXEC_WAIT(N(8022181C))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8022181C) = {
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_LABEL(0)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(3), LW(4), LW(5))
|
||||
EVT_IF_EQ(LW(3), LW(0))
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_IF_LT(LW(3), LW(0))
|
||||
EVT_SET(LW(4), LW(0))
|
||||
EVT_SUB(LW(4), LW(3))
|
||||
EVT_IF_LT(LW(4), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_ELSE
|
||||
EVT_SET(LW(4), LW(3))
|
||||
EVT_ADD(LW(3), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(3), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 0, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_SET(LW(4), LW(3))
|
||||
EVT_SUB(LW(4), LW(0))
|
||||
EVT_IF_LT(LW(4), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(3), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(3), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 0, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_GOTO(0)
|
||||
EVT_LABEL(10)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(init_80221ABC) = {
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80222ED0)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_80221D00)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_80222364)))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(0), 3)
|
||||
EVT_LOOP(8)
|
||||
EVT_CALL(SetPartSize, ACTOR_SELF, LW(0), 16, 16)
|
||||
EVT_ADD(LW(0), 1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(N(ChompChainInit))
|
||||
EVT_EXEC(N(80222324))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80221BC4) = {
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 2, 0, 24)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 2, 0, 0)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 2, -13, 40)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 2, 0, -14)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_80221D00) = {
|
||||
EVT_LABEL(0)
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_80221504)))
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 10)
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 11, 1)
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 6, 1)
|
||||
EVT_CALL(RandInt, 10, LW(0))
|
||||
EVT_ADD(LW(0), 1)
|
||||
EVT_WAIT_FRAMES(LW(0))
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_802214C8)))
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 15, 1)
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_80221504)))
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 20)
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 12, 1)
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 10)
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 9, 1)
|
||||
EVT_LOOP(0)
|
||||
EVT_EXEC_WAIT(N(80221BC4))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8022148C)))
|
||||
EVT_CALL(SetActorIdleJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetIdleGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetIdleGoal, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(IdleJumpToGoal, ACTOR_SELF, 6, 1)
|
||||
EVT_CALL(RandInt, 10, LW(0))
|
||||
EVT_ADD(LW(0), 10)
|
||||
EVT_WAIT_FRAMES(LW(0))
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80222324) = {
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(b_area_isk_part_1_ChompChainUpdate)
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_80222364) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetActorScale, ACTOR_SELF, EVT_FLOAT(1.0), EVT_FLOAT(1.0), EVT_FLOAT(1.0))
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 3, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 4, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 5, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 6, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 7, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 8, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 9, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 10, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_stone_chomp_Palette_00_Anim_8)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 3, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 4, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 5, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 6, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 7, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 8, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 9, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 10, NPC_ANIM_stone_chomp_Palette_00_Anim_9)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_stone_chomp_Palette_00_Anim_8)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_8)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, -1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, LW(0), LW(1))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.400390625))
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 30, 0, 0)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 15, 0, 0)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 5, 0, 0)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_5)
|
||||
EVT_EXEC_WAIT(N(80221794))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.6005859375))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 1, EVT_FLOAT(0.5))
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(1), LW(2), LW(3))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SHRINK)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_ADD(LW(2), 4)
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(1), 5)
|
||||
EVT_ADD(LW(2), 11)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(1), LW(2), LW(3))
|
||||
EVT_END_IF
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, -1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_CASE_EQ(EVENT_UP_AND_AWAY)
|
||||
EVT_WAIT_FRAMES(1000)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_IF_NE(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), 0, LW(2))
|
||||
EVT_CALL(FallToGoal, ACTOR_SELF, 11)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_80222ED0) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 1)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.5))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_ADD(LW(0), 45)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_5)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x10F)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 1, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 20)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 25)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 6, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_SUB(LW(0), 15)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 4, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_4)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(4.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(8022181C))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, -1)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(10))
|
||||
EVT_IF_FLAG(LW(10), STATUS_FLAG_SHRINK)
|
||||
EVT_ADD(LW(0), 4)
|
||||
EVT_ELSE
|
||||
EVT_ADD(LW(0), 10)
|
||||
EVT_END_IF
|
||||
EVT_SET(LW(1), 27)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.2001953125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 0, 0, 3, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_4)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 40)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_ADD(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 6, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_SUB(LW(0), 10)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 4, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x3F9)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(4.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(8022181C))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_stone_chomp_Palette_00_Anim_1)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, -1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
598
src/battle/area_isk_part_1/actor/swooper.c
Normal file
598
src/battle/area_isk_part_1/actor/swooper.c
Normal file
@ -0,0 +1,598 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/swooper.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_swooper
|
||||
|
||||
extern s32 N(idleAnimations_8021C5B4)[];
|
||||
extern EvtSource N(init_8021C64C);
|
||||
extern EvtSource N(takeTurn_8021DED4);
|
||||
extern EvtSource N(idle_8021C6B0);
|
||||
extern EvtSource N(handleEvent_8021D064);
|
||||
|
||||
s32 N(defenseTable_8021C4B0)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_8021C4BC)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 80,
|
||||
STATUS_POISON, 60,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 100,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 80,
|
||||
STATUS_PARALYZE, 90,
|
||||
STATUS_SHRINK, 90,
|
||||
STATUS_STOP, 90,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 1,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 1,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021C568)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 29 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021C5B4),
|
||||
.defenseTable = N(defenseTable_8021C4B0),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 271,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = ACTOR_FLAG_HP_OFFSET_BELOW,
|
||||
.type = ACTOR_TYPE_SWOOPER,
|
||||
.level = 10,
|
||||
.maxHP = 4,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021C568)),
|
||||
.partsData = N(partsTable_8021C568),
|
||||
.script = N(init_8021C64C),
|
||||
.statusTable = N(statusTable_8021C4BC),
|
||||
.escapeChance = 50,
|
||||
.airLiftChance = 100,
|
||||
.spookChance = 95,
|
||||
.baseStatusChance = 90,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 80,
|
||||
.coinReward = 1,
|
||||
.size = { 31, 24 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, -20 },
|
||||
.statusMessageOffset = { 10, -20 },
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021C5B4)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_swooper_Palette_00_Anim_C,
|
||||
STATUS_STONE, NPC_ANIM_swooper_Palette_00_Anim_B,
|
||||
STATUS_SLEEP, NPC_ANIM_swooper_Palette_00_Anim_F,
|
||||
STATUS_POISON, NPC_ANIM_swooper_Palette_00_Anim_C,
|
||||
STATUS_STOP, NPC_ANIM_swooper_Palette_00_Anim_B,
|
||||
STATUS_STATIC, NPC_ANIM_swooper_Palette_00_Anim_C,
|
||||
STATUS_PARALYZE, NPC_ANIM_swooper_Palette_00_Anim_B,
|
||||
STATUS_DIZZY, NPC_ANIM_swooper_Palette_00_Anim_10,
|
||||
STATUS_FEAR, NPC_ANIM_swooper_Palette_00_Anim_10,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021C600)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_swooper_Palette_00_Anim_2,
|
||||
STATUS_STONE, NPC_ANIM_swooper_Palette_00_Anim_1,
|
||||
STATUS_SLEEP, NPC_ANIM_swooper_Palette_00_Anim_13,
|
||||
STATUS_POISON, NPC_ANIM_swooper_Palette_00_Anim_2,
|
||||
STATUS_STOP, NPC_ANIM_swooper_Palette_00_Anim_1,
|
||||
STATUS_STATIC, NPC_ANIM_swooper_Palette_00_Anim_2,
|
||||
STATUS_PARALYZE, NPC_ANIM_swooper_Palette_00_Anim_1,
|
||||
STATUS_DIZZY, NPC_ANIM_swooper_Palette_00_Anim_14,
|
||||
STATUS_FEAR, NPC_ANIM_swooper_Palette_00_Anim_14,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
||||
|
||||
EvtSource N(init_8021C64C) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_8021DED4)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021C6B0)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021D064)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_8021C6B0) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021C6C0) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 0, -24, 0)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, 1, 11)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 1)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021C5B4)))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_C)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, 1, 11)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021C880) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_17)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_17)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_CALL(func_80269470)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_CALL(func_80269470)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(30)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_END_THREAD
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_CASE_OR_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_FLYING, 0)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021CD04) = {
|
||||
EVT_CALL(func_8027D32C, ACTOR_SELF)
|
||||
EVT_CALL(GetLastDamage, ACTOR_SELF, LW(0))
|
||||
EVT_IF_LE(LW(0), 0)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(10))
|
||||
EVT_IF_EQ(LW(10), -1)
|
||||
EVT_CALL(SetHomePos, ACTOR_SELF, LW(0), 45, LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, FALSE, FALSE)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, FALSE, FALSE)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), 45, LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 15, FALSE, FALSE, FALSE)
|
||||
EVT_CALL(GetIndexFromPos, ACTOR_SELF, LW(10))
|
||||
EVT_MOD(LW(10), 4)
|
||||
EVT_ADD(LW(10), 4)
|
||||
EVT_CALL(SetGoalToIndex, ACTOR_SELF, LW(10))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_CALL(SetHomePos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, FALSE, FALSE)
|
||||
EVT_END_IF
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, 0, -10)
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 22)
|
||||
EVT_CALL(N(UnkBattleFunc1), -10, 20, 10, 20)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021C600)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_FLYING, 1)
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 8, 1)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021D064) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_EXEC_WAIT(N(8021C880))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_E)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_HIT)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_E)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_EXEC_WAIT(N(8021CD04))
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_17)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_11)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_12)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_EXEC_WAIT(N(8021CD04))
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_17)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_18)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_11)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_12)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_12)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_CALL(func_80269470)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(D_8029A76C)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_CALL(func_80269470)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(D_8029A76C)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(30)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_END_THREAD
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_C)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_E)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_E)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_FIRST_STRIKE)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021C600)))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, 20, 0, 0)
|
||||
EVT_CALL(HPBarToCurrent, ACTOR_SELF)
|
||||
EVT_CASE_EQ(EVENT_END_FIRST_STRIKE)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CALL(HPBarToHome, ACTOR_SELF)
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_FLYING, 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, -24, 0)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_swooper_Palette_00_Anim_15)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021D7E4) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 10, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ELSE
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 10, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -4, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 2, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, FALSE, FALSE)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 50)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -10, 0)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(10.0))
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(HIT_RESULT_HIT_STATIC)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_STATIC)
|
||||
EVT_SET(LF(0), 0)
|
||||
EVT_ELSE
|
||||
EVT_SET(LF(0), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_SWITCH
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, FALSE, FALSE)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -10, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 0, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 10, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -10, 0)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_8021DED4) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 8, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_EXEC_WAIT(N(8021D7E4))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_HP_OFFSET_BELOW, 0)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 24)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 2, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, -50, 0, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -40, 0)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(10.0))
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(HIT_RESULT_HIT_STATIC)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_STATIC)
|
||||
EVT_SET(LF(0), 0)
|
||||
EVT_ELSE
|
||||
EVT_SET(LF(0), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_SWITCH
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_6)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -40, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 0, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 10, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_swooper_Palette_00_Anim_2)
|
||||
EVT_CALL(FlyToGoal, ACTOR_SELF, 0, -10, 0)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_EXEC_WAIT(N(8021C6C0))
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
206
src/battle/area_isk_part_1/area.c
Normal file
206
src/battle/area_isk_part_1/area.c
Normal file
@ -0,0 +1,206 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1
|
||||
|
||||
extern ActorDesc N(pokey_mummy);
|
||||
extern ActorDesc N(swooper);
|
||||
extern ActorDesc N(stone_chomp);
|
||||
extern ActorDesc N(buzzy_beetle);
|
||||
|
||||
extern Stage N(isk_00);
|
||||
extern Stage N(isk_01);
|
||||
extern Stage N(isk_02);
|
||||
extern Stage N(isk_02b);
|
||||
extern Stage N(isk_02c);
|
||||
extern Stage N(isk_03);
|
||||
extern Stage N(isk_03b);
|
||||
extern Stage N(isk_04);
|
||||
extern Stage N(isk_05);
|
||||
extern Stage N(isk_06);
|
||||
extern Stage N(isk_06b);
|
||||
extern Stage N(isk_07);
|
||||
extern Stage N(isk_08);
|
||||
|
||||
Vec3i N(vector3D_80224070) = { 15, 133, -25 };
|
||||
|
||||
Vec3i N(vector3D_8022407C) = { 55, 133, -25 };
|
||||
|
||||
Vec3i N(vector3D_80224088) = { 95, 133, -25 };
|
||||
|
||||
Vec3i N(vector3D_80224094) = { 135, 133, -25 };
|
||||
|
||||
Vec3i N(vector3D_802240A0) = { 15, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_802240AC) = { 55, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_802240B8) = { 95, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_802240C4) = { 135, 112, -25 };
|
||||
|
||||
Formation N(formation_00) = {
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_01) = {
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_02) = {
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_80224088) }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_03) = {
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_80224088) }, .priority = 8 },
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_802241E8) = { 80, 133, -25 };
|
||||
|
||||
Vec3i N(vector3D_802241F4) = { 115, 133, -25 };
|
||||
|
||||
Formation N(formation_04) = {
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey_mummy), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_802241E8) }, .priority = 8 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_802241F4) }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_05) = {
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_8022407C) }, .priority = 10 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_80224088) }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_06) = {
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_80224070) }, .priority = 10 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_8022407C) }, .priority = 9 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_80224088) }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_07) = {
|
||||
{ .actor = &N(stone_chomp), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(stone_chomp), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_08) = {
|
||||
{ .actor = &N(stone_chomp), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(stone_chomp), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(stone_chomp), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_09) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0A) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_0B) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 9, .var0 = 1 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_802240B8) }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_0C) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_802240B8) }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0D) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 10, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0E) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240B8) }, .priority = 9, .var0 = 1 },
|
||||
};
|
||||
|
||||
Formation N(formation_0F) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 10, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240B8) }, .priority = 9, .var0 = 1 },
|
||||
};
|
||||
|
||||
Formation N(formation_10) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 9, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240B8) }, .priority = 8, .var0 = 1 },
|
||||
};
|
||||
|
||||
Formation N(formation_11) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240A0) }, .priority = 10, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 9, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240B8) }, .priority = 8, .var0 = 1 },
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_8022460C) = { 0, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_80224618) = { 40, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_80224624) = { 80, 112, -25 };
|
||||
|
||||
Vec3i N(vector3D_80224630) = { 120, 112, -25 };
|
||||
|
||||
Formation N(formation_12) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_8022460C) }, .priority = 10, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_80224618) }, .priority = 9, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_80224624) }, .priority = 8, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_80224630) }, .priority = 7, .var0 = 1 },
|
||||
};
|
||||
|
||||
Formation N(formation_13) = {
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240A0) }, .priority = 10, .var0 = 1 },
|
||||
{ .actor = &N(buzzy_beetle), .home = { .vec = &N(vector3D_802240AC) }, .priority = 9, .var0 = 1 },
|
||||
{ .actor = &N(swooper), .home = { .vec = &N(vector3D_802240B8) }, .priority = 8 },
|
||||
};
|
||||
|
||||
BattleList N(formationTable) = {
|
||||
BATTLE("サンボマミーx2", N(formation_00), &N(isk_02b)),
|
||||
BATTLE("サンボマミーx3", N(formation_01), &N(isk_02b)),
|
||||
BATTLE("サンボマミー,バサバサ", N(formation_02), &N(isk_04)),
|
||||
BATTLE("サンボマミーx2,バサバサ", N(formation_03), &N(isk_04)),
|
||||
BATTLE("サンボマミーx2,バサバサx2", N(formation_04), &N(isk_04)),
|
||||
BATTLE("バサバサx2", N(formation_05), &N(isk_04)),
|
||||
BATTLE("バサバサx3", N(formation_06), &N(isk_04)),
|
||||
BATTLE("ストーンワンワンx2", N(formation_07), &N(isk_02b)),
|
||||
BATTLE("ストーンワンワンx3", N(formation_08), &N(isk_02b)),
|
||||
BATTLE("メットx2", N(formation_09), &N(isk_02b)),
|
||||
BATTLE("メットx4", N(formation_0A), &N(isk_02b)),
|
||||
BATTLE("メット,メット(てんじょう),バサバサ", N(formation_0B), &N(isk_05)),
|
||||
BATTLE("メット,バサバサ", N(formation_0C), &N(isk_05)),
|
||||
BATTLE("メット(てんじょう),メット", N(formation_0D), &N(isk_05)),
|
||||
BATTLE("メット,メット(てんじょう)", N(formation_0E), &N(isk_05)),
|
||||
BATTLE("メット(てんじょう)x2", N(formation_0F), &N(isk_05)),
|
||||
BATTLE("メット,メット(てんじょう)x2", N(formation_10), &N(isk_05)),
|
||||
BATTLE("メット(てんじょう)x3", N(formation_11), &N(isk_05)),
|
||||
BATTLE("メット(てんじょう)x4", N(formation_12), &N(isk_05)),
|
||||
BATTLE("メット(てんじょう)x2,バサバサ", N(formation_13), &N(isk_05)),
|
||||
{},
|
||||
};
|
||||
|
||||
StageList N(stageTable) = {
|
||||
{ "isk_00", &N(isk_00) },
|
||||
{ "isk_01", &N(isk_01) },
|
||||
{ "isk_02", &N(isk_02) },
|
||||
{ "isk_02b", &N(isk_02b) },
|
||||
{ "isk_02c", &N(isk_02c) },
|
||||
{ "isk_03", &N(isk_03) },
|
||||
{ "isk_03b", &N(isk_03b) },
|
||||
{ "isk_04", &N(isk_04) },
|
||||
{ "isk_05", &N(isk_05) },
|
||||
{ "isk_06", &N(isk_06) },
|
||||
{ "isk_06b", &N(isk_06b) },
|
||||
{ "isk_07", &N(isk_07) },
|
||||
{ "isk_08", &N(isk_08) },
|
||||
{},
|
||||
};
|
23
src/battle/area_isk_part_1/stage/isk_00.c
Normal file
23
src/battle/area_isk_part_1/stage/isk_00.c
Normal file
@ -0,0 +1,23 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_00
|
||||
|
||||
EvtSource N(beforeBattle_802238B0) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_802238EC) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt00_shape",
|
||||
.preBattle = N(beforeBattle_802238B0),
|
||||
.postBattle = N(afterBattle_802238EC),
|
||||
};
|
24
src/battle/area_isk_part_1/stage/isk_01.c
Normal file
24
src/battle/area_isk_part_1/stage/isk_01.c
Normal file
@ -0,0 +1,24 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_01
|
||||
|
||||
EvtSource N(beforeBattle_80223930) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_8022396C) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt01_shape",
|
||||
.hit = "isk_bt01_hit",
|
||||
.preBattle = N(beforeBattle_80223930),
|
||||
.postBattle = N(afterBattle_8022396C),
|
||||
};
|
29
src/battle/area_isk_part_1/stage/isk_02.c
Normal file
29
src/battle/area_isk_part_1/stage/isk_02.c
Normal file
@ -0,0 +1,29 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_02
|
||||
|
||||
EvtSource N(beforeBattle_802239B0) = {
|
||||
EVT_CALL(SetSpriteShading, 786432)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_802239EC) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_802239FC)[] = {
|
||||
0x0000001F, 0x0000001E, 0x00000021, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt02_shape",
|
||||
.hit = "isk_bt02_hit",
|
||||
.preBattle = N(beforeBattle_802239B0),
|
||||
.postBattle = N(afterBattle_802239EC),
|
||||
.foregroundModelList = N(foregroundModelList_802239FC),
|
||||
};
|
35
src/battle/area_isk_part_1/stage/isk_02b.c
Normal file
35
src/battle/area_isk_part_1/stage/isk_02b.c
Normal file
@ -0,0 +1,35 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_02b
|
||||
|
||||
EvtSource N(beforeBattle_80223D90) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(EnableModel, 7, 0)
|
||||
EVT_CALL(EnableModel, 8, 0)
|
||||
EVT_CALL(EnableModel, 9, 0)
|
||||
EVT_CALL(EnableModel, 15, 0)
|
||||
EVT_CALL(EnableModel, 16, 0)
|
||||
EVT_CALL(EnableModel, 17, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223E44) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_80223E54)[] = {
|
||||
0x0000001F, 0x0000001E, 0x00000021, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt02_shape",
|
||||
.hit = "isk_bt02_hit",
|
||||
.preBattle = N(beforeBattle_80223D90),
|
||||
.postBattle = N(afterBattle_80223E44),
|
||||
.foregroundModelList = N(foregroundModelList_80223E54),
|
||||
};
|
31
src/battle/area_isk_part_1/stage/isk_02c.c
Normal file
31
src/battle/area_isk_part_1/stage/isk_02c.c
Normal file
@ -0,0 +1,31 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_02c
|
||||
|
||||
EvtSource N(beforeBattle_80223E90) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(EnableModel, 14, 0)
|
||||
EVT_CALL(EnableModel, 11, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223EF4) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_80223F04)[] = {
|
||||
0x0000001F, 0x0000001E, 0x00000021, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt02_shape",
|
||||
.hit = "isk_bt02_hit",
|
||||
.preBattle = N(beforeBattle_80223E90),
|
||||
.postBattle = N(afterBattle_80223EF4),
|
||||
.foregroundModelList = N(foregroundModelList_80223F04),
|
||||
};
|
25
src/battle/area_isk_part_1/stage/isk_03.c
Normal file
25
src/battle/area_isk_part_1/stage/isk_03.c
Normal file
@ -0,0 +1,25 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_03
|
||||
|
||||
EvtSource N(beforeBattle_80223A40) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223A7C) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt03_shape",
|
||||
.hit = "isk_bt03_hit",
|
||||
.bg = "sbk3_bg",
|
||||
.preBattle = N(beforeBattle_80223A40),
|
||||
.postBattle = N(afterBattle_80223A7C),
|
||||
};
|
24
src/battle/area_isk_part_1/stage/isk_03b.c
Normal file
24
src/battle/area_isk_part_1/stage/isk_03b.c
Normal file
@ -0,0 +1,24 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_03b
|
||||
|
||||
EvtSource N(beforeBattle_80223D10) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223D4C) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt03_shape",
|
||||
.hit = "isk_bt03_hit",
|
||||
.preBattle = N(beforeBattle_80223D10),
|
||||
.postBattle = N(afterBattle_80223D4C),
|
||||
};
|
48
src/battle/area_isk_part_1/stage/isk_04.c
Normal file
48
src/battle/area_isk_part_1/stage/isk_04.c
Normal file
@ -0,0 +1,48 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_04
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224D60);
|
||||
BSS EffectInstance* N(D_80224D64);
|
||||
|
||||
ApiStatus N(CreateTorchFX)(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -133.0f, 72.0f, -143.0f, 0.3f, &N(D_80224D60));
|
||||
playFX_20(1, 129.0f, 72.0f, -143.0f, 0.3f, &N(D_80224D64));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus N(DeleteTorchFX)(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224D60));
|
||||
remove_effect(N(D_80224D64));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223AC0) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(N(CreateTorchFX))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223B08) = {
|
||||
EVT_CALL(N(DeleteTorchFX))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_80223B24)[] = {
|
||||
0x00000033, 0x00000034, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt04_shape",
|
||||
.hit = "isk_bt04_hit",
|
||||
.preBattle = N(beforeBattle_80223AC0),
|
||||
.postBattle = N(afterBattle_80223B08),
|
||||
.foregroundModelList = N(foregroundModelList_80223B24),
|
||||
};
|
43
src/battle/area_isk_part_1/stage/isk_05.c
Normal file
43
src/battle/area_isk_part_1/stage/isk_05.c
Normal file
@ -0,0 +1,43 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_05
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224D70);
|
||||
BSS EffectInstance* N(D_80224D74);
|
||||
|
||||
ApiStatus N(CreateTorchFX)(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -90.0f, 45.0f, -146.0f, 0.25f, &N(D_80224D70));
|
||||
playFX_20(1, 80.0f, 45.0f, -146.0f, 0.25f, &N(D_80224D74));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus N(DeleteTorchFX)(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224D70));
|
||||
remove_effect(N(D_80224D74));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223B60) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(N(CreateTorchFX))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223BA8) = {
|
||||
EVT_CALL(N(DeleteTorchFX))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt05_shape",
|
||||
.hit = "isk_bt05_hit",
|
||||
.preBattle = N(beforeBattle_80223B60),
|
||||
.postBattle = N(afterBattle_80223BA8),
|
||||
};
|
40
src/battle/area_isk_part_1/stage/isk_06.c
Normal file
40
src/battle/area_isk_part_1/stage/isk_06.c
Normal file
@ -0,0 +1,40 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_06
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224D80);
|
||||
|
||||
ApiStatus func_80218A50_4E3190(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -110.0f, 80.0f, -146.0f, 0.3f, &N(D_80224D80));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218A98_4E31D8(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224D80));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223BF0) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(func_80218A50_4E3190)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223C38) = {
|
||||
EVT_CALL(func_80218A98_4E31D8)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt06_shape",
|
||||
.hit = "isk_bt06_hit",
|
||||
.preBattle = N(beforeBattle_80223BF0),
|
||||
.postBattle = N(afterBattle_80223C38),
|
||||
};
|
41
src/battle/area_isk_part_1/stage/isk_06b.c
Normal file
41
src/battle/area_isk_part_1/stage/isk_06b.c
Normal file
@ -0,0 +1,41 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_06b
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224DA0);
|
||||
|
||||
ApiStatus func_80218B30_4E3270(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, -110.0f, 80.0f, -146.0, 0.3f, &N(D_80224DA0));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218B78_4E32B8(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224DA0));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223F40) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(func_80218B30_4E3270)
|
||||
EVT_CALL(EnableModel, 23, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223F9C) = {
|
||||
EVT_CALL(func_80218B78_4E32B8)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt06_shape",
|
||||
.hit = "isk_bt06_hit",
|
||||
.preBattle = N(beforeBattle_80223F40),
|
||||
.postBattle = N(afterBattle_80223F9C),
|
||||
};
|
40
src/battle/area_isk_part_1/stage/isk_07.c
Normal file
40
src/battle/area_isk_part_1/stage/isk_07.c
Normal file
@ -0,0 +1,40 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_07
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224D90);
|
||||
|
||||
ApiStatus func_80218AC0_4E3200(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, 110.0f, 80.0f, -146.0f, 0.3f, &N(D_80224D90));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218B08_4E3248(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224D90));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223C80) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(func_80218AC0_4E3200)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80223CC8) = {
|
||||
EVT_CALL(func_80218B08_4E3248)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt07_shape",
|
||||
.hit = "isk_bt07_hit",
|
||||
.preBattle = N(beforeBattle_80223C80),
|
||||
.postBattle = N(afterBattle_80223CC8),
|
||||
};
|
40
src/battle/area_isk_part_1/stage/isk_08.c
Normal file
40
src/battle/area_isk_part_1/stage/isk_08.c
Normal file
@ -0,0 +1,40 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_isk_part_1_isk_08
|
||||
|
||||
BSS char N(pad)[8]; // BSS has bad alignment. Should be 0x10 aligned.
|
||||
BSS EffectInstance* N(D_80224DB0);
|
||||
|
||||
ApiStatus func_80218BA0_4E32E0(Evt* script, s32 isInitialCall) {
|
||||
playFX_20(1, 0, 72.0f, -146.0, 0.3f, &N(D_80224DB0));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus func_80218BE8_4E3328(Evt* script, s32 isInitialCall) {
|
||||
remove_effect(N(D_80224DB0));
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource N(beforeBattle_80223FE0) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetCamBGColor, 1, 0, 0, 0)
|
||||
EVT_CALL(func_80218BA0_4E32E0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80224028) = {
|
||||
EVT_CALL(func_80218BE8_4E3328)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "isk_tex",
|
||||
.shape = "isk_bt08_shape",
|
||||
.hit = "isk_bt08_hit",
|
||||
.preBattle = N(beforeBattle_80223FE0),
|
||||
.postBattle = N(afterBattle_80224028),
|
||||
};
|
@ -1,8 +0,0 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
#include "common/SetSpinSmashable.inc.c"
|
||||
|
||||
#include "common/StartRumbleWithParams.inc.c"
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
#define NAMESPACE dup_b_area_iwa
|
||||
#include "common/StartRumbleWithParams.inc.c"
|
||||
#define NAMESPACE b_area_iwa
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
#define NAMESPACE dup_b_area_iwa
|
||||
#include "common/IsSaveVar123.inc.c"
|
||||
#define NAMESPACE b_area_iwa
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
#define NAMESPACE dup2_b_area_iwa
|
||||
#include "common/IsSaveVar123.inc.c"
|
||||
#define NAMESPACE b_area_iwa
|
@ -1,5 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
#include "common/IsSaveVar123.inc.c"
|
1213
src/battle/area_iwa/actor/buzzar.c
Normal file
1213
src/battle/area_iwa/actor/buzzar.c
Normal file
File diff suppressed because it is too large
Load Diff
548
src/battle/area_iwa/actor/cleft.c
Normal file
548
src/battle/area_iwa/actor/cleft.c
Normal file
@ -0,0 +1,548 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/cleft.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_cleft
|
||||
|
||||
extern s32 N(idleAnimations_80218838)[];
|
||||
extern EvtSource N(init_802188D0);
|
||||
extern EvtSource N(idle_80218934);
|
||||
extern EvtSource N(takeTurn_8021A3EC);
|
||||
extern EvtSource N(handleEvent_80218C3C);
|
||||
|
||||
s32 N(defenseTable_80218710)[] = {
|
||||
ELEMENT_NORMAL, 2,
|
||||
ELEMENT_FIRE, 99,
|
||||
ELEMENT_MAGIC, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8021872C)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_FIRE, 99,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_80218740)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 40,
|
||||
STATUS_POISON, 50,
|
||||
STATUS_FROZEN, 100,
|
||||
STATUS_DIZZY, 50,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 50,
|
||||
STATUS_PARALYZE, 50,
|
||||
STATUS_SHRINK, 75,
|
||||
STATUS_STOP, 90,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, -1,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, -1,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_802187EC)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 22 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80218838),
|
||||
.defenseTable = N(defenseTable_80218710),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_SPIKY_TOP,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 246,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = 0,
|
||||
.type = ACTOR_TYPE_CLEFT,
|
||||
.level = 10,
|
||||
.maxHP = 2,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_802187EC)),
|
||||
.partsData = N(partsTable_802187EC),
|
||||
.script = N(init_802188D0),
|
||||
.statusTable = N(statusTable_80218740),
|
||||
.escapeChance = 80,
|
||||
.airLiftChance = 40,
|
||||
.spookChance = 40,
|
||||
.baseStatusChance = 40,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 95,
|
||||
.coinReward = 2,
|
||||
.size = { 44, 36 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 20 },
|
||||
.statusMessageOffset = { 10, 20 },
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_80218838)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_cleft_default_idle,
|
||||
STATUS_STONE, NPC_ANIM_cleft_default_still,
|
||||
STATUS_SLEEP, NPC_ANIM_cleft_default_sleep,
|
||||
STATUS_POISON, NPC_ANIM_cleft_default_idle,
|
||||
STATUS_STOP, NPC_ANIM_cleft_default_still,
|
||||
STATUS_STATIC, NPC_ANIM_cleft_default_idle,
|
||||
STATUS_PARALYZE, NPC_ANIM_cleft_default_still,
|
||||
STATUS_DIZZY, NPC_ANIM_cleft_default_dizzy,
|
||||
STATUS_FEAR, NPC_ANIM_cleft_default_dizzy,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_80218884)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_cleft_default_Anim_5,
|
||||
STATUS_STONE, NPC_ANIM_cleft_default_inverted_still,
|
||||
STATUS_SLEEP, NPC_ANIM_cleft_default_inverted_sleep,
|
||||
STATUS_POISON, NPC_ANIM_cleft_default_Anim_5,
|
||||
STATUS_STOP, NPC_ANIM_cleft_default_inverted_still,
|
||||
STATUS_STATIC, NPC_ANIM_cleft_default_Anim_5,
|
||||
STATUS_PARALYZE, NPC_ANIM_cleft_default_inverted_still,
|
||||
STATUS_DIZZY, NPC_ANIM_cleft_default_inverted_dizzy,
|
||||
STATUS_FEAR, NPC_ANIM_cleft_default_inverted_dizzy,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
#include "common/SetSpinSmashable.inc.c"
|
||||
|
||||
#include "common/StartRumbleWithParams.inc.c"
|
||||
|
||||
EvtSource N(init_802188D0) = {
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_80218934)))
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_8021A3EC)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_80218C3C)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_80218934) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80218944) = {
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 1)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 1, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_run)
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 16, 0)
|
||||
EVT_THREAD
|
||||
EVT_SET(LW(0), 0)
|
||||
EVT_LOOP(5)
|
||||
EVT_ADD(LW(0), -36)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, LW(0))
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.30078125))
|
||||
EVT_SUB(LW(1), 6)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 20, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(N(StartRumbleWithParams), 200, 10)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(1.0))
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 0, LW(0), LW(1), LW(2), 40, 8, EVT_FLOAT(0.0), 20, 0, 0, 0, 0, 0)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), 0, LW(2))
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_inverted_idle)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_80218884)))
|
||||
EVT_CALL(SetDefenseTable, ACTOR_SELF, 1, EVT_ADDR(N(defenseTable_8021872C)))
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 15)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, 0, -7)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_SPIKY_TOP, 0)
|
||||
EVT_CALL(N(SetSpinSmashable), 0)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_400, 1)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_80218C3C) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_CALL(GetLastElement, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_FLAG(DAMAGE_TYPE_BLAST)
|
||||
EVT_EXEC_WAIT(N(80218944))
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_END_IF
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_SWITCH
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_CALL(GetLastElement, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_FLAG(DAMAGE_TYPE_BLAST)
|
||||
EVT_EXEC_WAIT(N(80218944))
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_EXPLOSIVE, 1)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_SET_CONST(LW(2), -1)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_SET_CONST(LW(2), -1)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_EXPLOSIVE, 0)
|
||||
EVT_END_SWITCH
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_SET_CONST(LW(2), -1)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_SET_CONST(LW(2), -1)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_END_IF
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_run)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.6005859375))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_STAR_BEAM)
|
||||
EVT_CASE_EQ(EVENT_SPIKE_TAUNT)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_NOT_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_laugh)
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(3))
|
||||
EVT_IF_FLAG(LW(3), STATUS_FLAG_SHRINK)
|
||||
EVT_ADD(LW(0), -3)
|
||||
EVT_ADD(LW(1), 10)
|
||||
EVT_ELSE
|
||||
EVT_ADD(LW(0), -8)
|
||||
EVT_ADD(LW(1), 27)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1A, 0, LW(0), LW(1), LW(2), 20, 0, 0, 0, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_CASE_OR_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_inverted_idle)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_idle)
|
||||
EVT_END_IF
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_idle)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_inverted_idle)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_run)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_cleft_default_skid)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_inverted_dizzy)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_inverted_dizzy)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_cleft_default_skid)
|
||||
EVT_END_IF
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(802197AC) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(3.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_inverted_idle)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_Anim_5)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_SUB(LW(0), 1)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 16, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_inverted_idle)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_LOOP(5)
|
||||
EVT_ADD(LW(0), 36)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, LW(0))
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(1), 6)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.30078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(N(StartRumbleWithParams), 200, 10)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(1.0))
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(SetActorRotationOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), 0, LW(2))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_idle)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_80218838)))
|
||||
EVT_CALL(SetDefenseTable, ACTOR_SELF, 1, EVT_ADDR(N(defenseTable_80218710)))
|
||||
EVT_CALL(SetTargetOffset, ACTOR_SELF, 1, 0, 22)
|
||||
EVT_CALL(func_8027D4C8, ACTOR_SELF, 1, 0, -10)
|
||||
EVT_CALL(SetPartEventBits, ACTOR_SELF, 1, ACTOR_EVENT_FLAG_SPIKY_TOP, 1)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(N(SetSpinSmashable), 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_400, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80219BA0) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(MoveBattleCamOver, 30)
|
||||
EVT_THREAD
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 32, 4, 0, 10, 0, 0, 0, 0, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_charge_still)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_charge)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 0, -5)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(4.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_still)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x20D1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 2, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_charge)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 100)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetPartRotation, ACTOR_SELF, 1, 0, 0, 45)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_skid)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetPartRotation, ACTOR_SELF, 1, 0, 0, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_run)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_idle)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_charge)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 0, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_idle)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 15)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(2.400390625))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 6, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_idle)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_run)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_cleft_default_idle)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_8021A3EC) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_EXEC_WAIT(N(802197AC))
|
||||
EVT_ELSE
|
||||
EVT_EXEC_WAIT(N(80219BA0))
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
429
src/battle/area_iwa/actor/monty_mole.c
Normal file
429
src/battle/area_iwa/actor/monty_mole.c
Normal file
@ -0,0 +1,429 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/monty_mole.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_monty_mole
|
||||
|
||||
extern s32 N(idleAnimations_8021A59C)[];
|
||||
extern s32 N(idleAnimations_8021A5E8)[];
|
||||
extern EvtSource N(init_8021A7B0);
|
||||
extern EvtSource N(takeTurn_8021AFAC);
|
||||
extern EvtSource N(idle_8021A814);
|
||||
extern EvtSource N(handleEvent_8021A824);
|
||||
|
||||
s32 N(defenseTable_8021A450)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_8021A45C)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 90,
|
||||
STATUS_POISON, 80,
|
||||
STATUS_FROZEN, 100,
|
||||
STATUS_DIZZY, 90,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 10,
|
||||
STATUS_PARALYZE, 100,
|
||||
STATUS_SHRINK, 90,
|
||||
STATUS_STOP, 100,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, -1,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 1,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021A508)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_NO_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { -2, 16 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021A59C),
|
||||
.defenseTable = N(defenseTable_8021A450),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 249,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_MULTI_TARGET | ACTOR_PART_FLAG_80000000,
|
||||
.index = 2,
|
||||
.posOffset = { 0, 0, -15 },
|
||||
.targetOffset = { -2, 12 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021A59C),
|
||||
.defenseTable = N(defenseTable_8021A450),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 249,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_NO_TARGET | ACTOR_PART_FLAG_100000,
|
||||
.index = 3,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 0 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021A5E8),
|
||||
.defenseTable = N(defenseTable_8021A450),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc N(1) = {
|
||||
.flags = 0,
|
||||
.type = ACTOR_TYPE_MONTY_MOLE,
|
||||
.level = 8,
|
||||
.maxHP = 3,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021A508)),
|
||||
.partsData = N(partsTable_8021A508),
|
||||
.script = N(init_8021A7B0),
|
||||
.statusTable = N(statusTable_8021A45C),
|
||||
.escapeChance = 80,
|
||||
.airLiftChance = 70,
|
||||
.spookChance = 50,
|
||||
.baseStatusChance = 85,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 4,
|
||||
.powerBounceChance = 100,
|
||||
.coinReward = 1,
|
||||
.size = { 34, 18 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 20 },
|
||||
.statusMessageOffset = { 10, 20 },
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021A59C)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_monty_mole_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_monty_mole_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_monty_mole_Palette_00_Anim_14,
|
||||
STATUS_POISON, NPC_ANIM_monty_mole_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_monty_mole_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_monty_mole_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_monty_mole_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_monty_mole_Palette_00_Anim_14,
|
||||
STATUS_FEAR, NPC_ANIM_monty_mole_Palette_00_Anim_14,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021A5E8)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_monty_mole_Palette_00_Anim_F,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021A5F4)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_monty_mole_Palette_00_Anim_12,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(unk_missing_8021A600)[] = {
|
||||
0x00000001, 0x002F0006, 0x00000000,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021A60C)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_2000 | ACTOR_PART_FLAG_NO_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 0 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021A5F4),
|
||||
.defenseTable = NULL,
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
};
|
||||
|
||||
EvtSource N(init_8021A630) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetPartScale, ACTOR_SELF, 1, EVT_FLOAT(0.400390625), EVT_FLOAT(0.400390625), EVT_FLOAT(0.400390625))
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
ActorDesc N(2) = {
|
||||
.flags = ACTOR_FLAG_NO_SHADOW | ACTOR_FLAG_40000 | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY,
|
||||
.type = ACTOR_TYPE_MONTY_HOLE,
|
||||
.level = 9,
|
||||
.maxHP = 5,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021A60C)),
|
||||
.partsData = N(partsTable_8021A60C),
|
||||
.script = N(init_8021A630),
|
||||
.statusTable = NULL,
|
||||
.escapeChance = 80,
|
||||
.airLiftChance = 0,
|
||||
.spookChance = 80,
|
||||
.baseStatusChance = 80,
|
||||
.upAndAwayChance = 90,
|
||||
.spinSmashReq = 4,
|
||||
.powerBounceChance = 90,
|
||||
.coinReward = 2,
|
||||
.size = { 32, 18 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 20 },
|
||||
.statusMessageOffset = { 10, 20 },
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_8021A6B8) = { 0, 0xFFFFFC18, 0, };
|
||||
|
||||
Formation N(specialFormation_8021A6C4) = {
|
||||
{ .actor = &N(2), .home = { .vec = &N(vector3D_8021A6B8) },},
|
||||
};
|
||||
|
||||
Formation N(specialFormation_8021A6E0) = {
|
||||
{ .actor = &N(2), .home = { .vec = &N(vector3D_8021A6B8) }, .var0 = 1 },
|
||||
};
|
||||
|
||||
EvtSource N(8021A6FC) = {
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SHRINK)
|
||||
EVT_CALL(SummonEnemy, EVT_ADDR(N(specialFormation_8021A6E0)), 0)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SummonEnemy, EVT_ADDR(N(specialFormation_8021A6C4)), 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(1), LW(2), LW(3))
|
||||
EVT_SUB(LW(3), 1)
|
||||
EVT_CALL(SetActorPos, LW(0), LW(1), LW(2), LW(3))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(init_8021A7B0) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_8021AFAC)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021A814)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021A824)))
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_NO_SHADOW, 1)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_8021A814) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021A824) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastElement, LW(14))
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_IF_FLAG(LW(14), DAMAGE_TYPE_SMASH)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_7)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_6)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_8)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_5)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_END_IF
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_A)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_monty_mole_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_A)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_monty_mole_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_EXEC_WAIT(N(8021A6FC))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_C)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_CALL(GetLastElement, LW(0))
|
||||
EVT_IF_FLAG(LW(0), DAMAGE_TYPE_SMASH)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(2.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_11)
|
||||
EVT_WAIT_FRAMES(80)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_SURFACE)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_10)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_14)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_IF
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_5)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_6)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_EXEC_WAIT(N(8021A6FC))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_6)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_7)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_8)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_6)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_7)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_8)
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_TARGET_ONLY | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021A5F4)))
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_monty_mole_Palette_00_Anim_5)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_EXEC_WAIT(N(8021A6FC))
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SLEEP | STATUS_FLAG_FROZEN | STATUS_FLAG_FEAR | STATUS_FLAG_PARALYZE | STATUS_FLAG_DIZZY | STATUS_FLAG_STONE | STATUS_FLAG_STOP)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, -5, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_19)
|
||||
EVT_ELSE
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SHRINK)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, -9, 0)
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, -23, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_9)
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1000)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(2.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_11)
|
||||
EVT_WAIT_FRAMES(40)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_SURFACE)
|
||||
EVT_CALL(SetAnimationRate, ACTOR_SELF, 1, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_10)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_14)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CASE_EQ(EVENT_UP_AND_AWAY)
|
||||
EVT_EXEC_WAIT(N(8021A6FC))
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_8021AFAC) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(MoveBattleCamOver, 1)
|
||||
EVT_END_IF
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_SURFACE)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_monty_mole_Palette_00_Anim_4)
|
||||
EVT_WAIT_FRAMES(37)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(1), 20)
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 3, LW(0), LW(1), LW(2))
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 3, ACTOR_PART_FLAG_INVISIBLE, 0)
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SHRINK)
|
||||
EVT_CALL(SetPartScale, ACTOR_SELF, 3, EVT_FLOAT(0.400390625), EVT_FLOAT(0.400390625), EVT_FLOAT(0.400390625))
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetPartScale, ACTOR_SELF, 3, EVT_FLOAT(1.0), EVT_FLOAT(1.0), EVT_FLOAT(1.0))
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtPart, ACTOR_SELF, 3, SOUND_MOLE_THROW)
|
||||
EVT_CALL(SetPartSounds, ACTOR_SELF, 3, 1, 0, 0)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_NO_CONTACT, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 100)
|
||||
EVT_SET(LW(1), -5)
|
||||
EVT_CALL(SetPartMoveSpeed, ACTOR_SELF, 3, EVT_FLOAT(12.0))
|
||||
EVT_CALL(SetPartJumpGravity, ACTOR_SELF, 3, EVT_FLOAT(0.1005859375))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 3, NPC_ANIM_monty_mole_Palette_00_Anim_F)
|
||||
EVT_CALL(FlyPartTo, ACTOR_SELF, 3, LW(0), LW(1), LW(2), 0, 30, 0)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 3, ACTOR_PART_FLAG_INVISIBLE, 1)
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartMoveSpeed, ACTOR_SELF, 3, EVT_FLOAT(12.0))
|
||||
EVT_CALL(SetPartJumpGravity, ACTOR_SELF, 3, EVT_FLOAT(0.1005859375))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 3, NPC_ANIM_monty_mole_Palette_00_Anim_F)
|
||||
EVT_CALL(FlyPartTo, ACTOR_SELF, 3, LW(0), LW(1), LW(2), 0, 20, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_NO_CONTACT, 0, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 55)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetPartMoveSpeed, ACTOR_SELF, 3, EVT_FLOAT(6.0))
|
||||
EVT_CALL(SetPartJumpGravity, ACTOR_SELF, 3, EVT_FLOAT(0.1005859375))
|
||||
EVT_CALL(FlyPartTo, ACTOR_SELF, 3, LW(0), LW(1), LW(2), 0, 25, 0)
|
||||
EVT_CALL(SetPartMoveSpeed, ACTOR_SELF, 3, EVT_FLOAT(4.0))
|
||||
EVT_SUB(LW(0), 20)
|
||||
EVT_CALL(FlyPartTo, ACTOR_SELF, 3, LW(0), LW(1), LW(2), 0, 21, 0)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 3, ACTOR_PART_FLAG_INVISIBLE, 1)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
311
src/battle/area_iwa/actor/whacka.c
Normal file
311
src/battle/area_iwa/actor/whacka.c
Normal file
@ -0,0 +1,311 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/whacka.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_whacka
|
||||
|
||||
extern EvtSource N(init_8021FDA0);
|
||||
extern EvtSource N(takeTurn_80220634);
|
||||
extern EvtSource N(idle_8021FE5C);
|
||||
extern EvtSource N(handleEvent_8021FE90);
|
||||
extern EvtSource N(80220684);
|
||||
extern EvtSource N(80220764);
|
||||
|
||||
s32 N(idleAnimations_8021FC50)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_POISON, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_FEAR, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8021FC9C)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_8021FCA8)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 0,
|
||||
STATUS_POISON, 0,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 0,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 0,
|
||||
STATUS_PARALYZE, 0,
|
||||
STATUS_SHRINK, 0,
|
||||
STATUS_STOP, 0,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 0,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021FD54)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 30 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021FC50),
|
||||
.defenseTable = N(defenseTable_8021FC9C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 251,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = ACTOR_FLAG_NO_SHADOW | ACTOR_FLAG_40000,
|
||||
.type = ACTOR_TYPE_WHACKA,
|
||||
.level = 0,
|
||||
.maxHP = 99,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021FD54)),
|
||||
.partsData = N(partsTable_8021FD54),
|
||||
.script = N(init_8021FDA0),
|
||||
.statusTable = N(statusTable_8021FCA8),
|
||||
.escapeChance = 0,
|
||||
.airLiftChance = 0,
|
||||
.spookChance = 0,
|
||||
.baseStatusChance = 0,
|
||||
.upAndAwayChance = 0,
|
||||
.spinSmashReq = 4,
|
||||
.powerBounceChance = 50,
|
||||
.coinReward = 0,
|
||||
.size = { 47, 32 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -20, 40 },
|
||||
.statusMessageOffset = { 10, 30 },
|
||||
};
|
||||
|
||||
#include "common/IsSaveVar123.inc.c"
|
||||
|
||||
EvtSource N(init_8021FDA0) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80220634)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021FE5C)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021FE90)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_CALL(N(IsSaveVar123))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_8021FE5C) = {
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021FE90) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CASE_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80220684))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80220684))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80220684))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CASE_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80220684))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_80220634) = {
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80220764))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80220684) = {
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 5)
|
||||
EVT_ADD(LW(1), 20)
|
||||
EVT_ADD(LW(2), 10)
|
||||
EVT_CALL(MakeItemEntity, ITEM_WHACKAS_BUMP, LW(0), LW(1), LW(2), 12, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80220764) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_3)
|
||||
EVT_WAIT_FRAMES(40)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_CALL(SetBattleFlagBits2, 0x10000000, 1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(RemoveActor, ACTOR_SELF)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
115
src/battle/area_iwa/area.c
Normal file
115
src/battle/area_iwa/area.c
Normal file
@ -0,0 +1,115 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa
|
||||
|
||||
extern ActorDesc N(cleft);
|
||||
extern ActorDesc N(monty_mole_1);
|
||||
extern ActorDesc N(whacka);
|
||||
extern ActorDesc N(buzzar);
|
||||
|
||||
extern Stage N(iwa_01);
|
||||
extern Stage N(iwa_01b);
|
||||
extern Stage N(iwa_02);
|
||||
|
||||
Formation N(formation_00) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 1 }, .priority = 10 },
|
||||
};
|
||||
|
||||
Formation N(formation_01) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(cleft), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_02) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(cleft), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(cleft), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_03) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_04) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_05) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 10 },
|
||||
};
|
||||
|
||||
Formation N(formation_06) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_07) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_08) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_09) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(cleft), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0A) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(cleft), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_0B) = {
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(cleft), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_8021853C) = { 90, 70, 0, };
|
||||
|
||||
Formation N(formation_0C) = {
|
||||
{ .actor = &N(buzzar), .home = { .vec = &N(vector3D_8021853C) }, .priority = 10 },
|
||||
};
|
||||
|
||||
Formation N(formation_0D) = {
|
||||
{ .actor = &N(cleft), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(monty_mole_1), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(whacka), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
BattleList N(formationTable) = {
|
||||
BATTLE("シンエモン", N(formation_00), &N(iwa_01)),
|
||||
BATTLE("シンエモンx2", N(formation_01), &N(iwa_01)),
|
||||
BATTLE("シンエモンx3", N(formation_02), &N(iwa_01)),
|
||||
BATTLE("シンエモン,チョロプー", N(formation_03), &N(iwa_01)),
|
||||
BATTLE("シンエモン,チョロプーx2", N(formation_04), &N(iwa_01)),
|
||||
BATTLE("チョロプー", N(formation_05), &N(iwa_01)),
|
||||
BATTLE("チョロプーx2", N(formation_06), &N(iwa_01)),
|
||||
BATTLE("チョロプーx3", N(formation_07), &N(iwa_01)),
|
||||
BATTLE("チョロプーx4", N(formation_08), &N(iwa_01)),
|
||||
BATTLE("チョロプー,シンエモン", N(formation_09), &N(iwa_01)),
|
||||
BATTLE("チョロプーx2,シンエモン", N(formation_0A), &N(iwa_01)),
|
||||
BATTLE("チョロプー,シンエモン,チョロプー", N(formation_0B), &N(iwa_01)),
|
||||
BATTLE("ゲーハー", N(formation_0C), &N(iwa_02)),
|
||||
BATTLE("コブロン", N(formation_0D), &N(iwa_02)),
|
||||
{},
|
||||
};
|
||||
|
||||
StageList N(stageTable) = {
|
||||
{ "iwa_01", &N(iwa_01) },
|
||||
{ "iwa_01b", &N(iwa_01b) },
|
||||
{ "iwa_02", &N(iwa_02) },
|
||||
{},
|
||||
};
|
348
src/battle/area_iwa/stage/iwa_01.c
Normal file
348
src/battle/area_iwa/stage/iwa_01.c
Normal file
@ -0,0 +1,348 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/whacka.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_iwa_01
|
||||
|
||||
extern ActorDesc N(whacka);
|
||||
extern Formation N(specialFormation_802208E4);
|
||||
extern EvtSource N(init_80220A50);
|
||||
extern EvtSource N(takeTurn_802212E4);
|
||||
extern EvtSource N(idle_80220B0C);
|
||||
extern EvtSource N(handleEvent_80220B40);
|
||||
extern EvtSource N(80221414);
|
||||
extern EvtSource N(80221334);
|
||||
|
||||
EvtSource N(beforeBattle_80220860) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetGroupEnabled, 21, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80220894) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_802208A4)[] = {
|
||||
0x00000017, 0x00000018, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "iwa_tex",
|
||||
.shape = "iwa_bt01_shape",
|
||||
.hit = "iwa_bt01_hit",
|
||||
.bg = "iwa_bg\0",
|
||||
.preBattle = N(beforeBattle_80220860),
|
||||
.postBattle = N(afterBattle_80220894),
|
||||
.foregroundModelList = N(foregroundModelList_802208A4),
|
||||
.unk_1C = 1,
|
||||
.unk_20 = N(specialFormation_802208E4),
|
||||
.unk_24 = 0x200,
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_802208D8) = { 116, 0, -30 };
|
||||
|
||||
Formation N(specialFormation_802208E4) = {
|
||||
{ .actor = &N(whacka), .home = { .vec = &N(vector3D_802208D8) }},
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_80220900)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_POISON, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_FEAR, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8022094C)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_80220958)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 0,
|
||||
STATUS_POISON, 0,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 0,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 0,
|
||||
STATUS_PARALYZE, 0,
|
||||
STATUS_SHRINK, 0,
|
||||
STATUS_STOP, 0,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 0,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_80220A04)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 30 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_80220900),
|
||||
.defenseTable = N(defenseTable_8022094C),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 251,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc N(whacka) = {
|
||||
.flags = ACTOR_FLAG_NO_SHADOW | ACTOR_FLAG_40000,
|
||||
.type = ACTOR_TYPE_WHACKA,
|
||||
.level = 0,
|
||||
.maxHP = 99,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_80220A04)),
|
||||
.partsData = N(partsTable_80220A04),
|
||||
.script = N(init_80220A50),
|
||||
.statusTable = N(statusTable_80220958),
|
||||
.escapeChance = 0,
|
||||
.airLiftChance = 0,
|
||||
.spookChance = 0,
|
||||
.baseStatusChance = 0,
|
||||
.upAndAwayChance = 0,
|
||||
.spinSmashReq = 4,
|
||||
.powerBounceChance = 50,
|
||||
.coinReward = 0,
|
||||
.size = { 47, 32 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -20, 40 },
|
||||
.statusMessageOffset = { 10, 30 },
|
||||
};
|
||||
|
||||
#include "common/IsSaveVar123.inc.c"
|
||||
|
||||
EvtSource N(init_80220A50) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_802212E4)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_80220B0C)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_80220B40)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_CALL(N(IsSaveVar123))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_80220B0C) = {
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_80220B40) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CASE_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80221334))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80221334))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80221334))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CASE_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80221334))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_802212E4) = {
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80221414))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80221334) = {
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 5)
|
||||
EVT_ADD(LW(1), 20)
|
||||
EVT_ADD(LW(2), 10)
|
||||
EVT_CALL(MakeItemEntity, ITEM_WHACKAS_BUMP, LW(0), LW(1), LW(2), 12, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80221414) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_3)
|
||||
EVT_WAIT_FRAMES(40)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_CALL(SetBattleFlagBits2, 0x10000000, 1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(RemoveActor, ACTOR_SELF)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
31
src/battle/area_iwa/stage/iwa_01b.c
Normal file
31
src/battle/area_iwa/stage/iwa_01b.c
Normal file
@ -0,0 +1,31 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_iwa_01b
|
||||
|
||||
EvtSource N(beforeBattle_80221510) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_CALL(SetGroupEnabled, 13, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_80221544) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_80221554)[] = {
|
||||
0x00000017, 0x00000018, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "iwa_tex",
|
||||
.shape = "iwa_bt01_shape",
|
||||
.hit = "iwa_bt01_hit",
|
||||
.bg = "iwa_bg",
|
||||
.preBattle = N(beforeBattle_80221510),
|
||||
.postBattle = N(afterBattle_80221544),
|
||||
.foregroundModelList = N(foregroundModelList_80221554),
|
||||
};
|
343
src/battle/area_iwa/stage/iwa_02.c
Normal file
343
src/battle/area_iwa/stage/iwa_02.c
Normal file
@ -0,0 +1,343 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/whacka.h"
|
||||
|
||||
#define NAMESPACE b_area_iwa_iwa_02
|
||||
|
||||
extern ActorDesc N(whacka);
|
||||
extern EvtSource N(init_8022176C);
|
||||
extern EvtSource N(takeTurn_80222000);
|
||||
extern EvtSource N(idle_80221828);
|
||||
extern EvtSource N(handleEvent_8022185C);
|
||||
extern EvtSource N(80222050);
|
||||
extern EvtSource N(80222130);
|
||||
|
||||
EvtSource N(beforeBattle_80221590) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_802215B0) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_802215C0)[] = {
|
||||
0x00000011, 0x00000010, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "iwa_tex",
|
||||
.shape = "iwa_bt02_shape",
|
||||
.hit = "iwa_bt02_hit",
|
||||
.bg = "iwa_bg",
|
||||
.preBattle = N(beforeBattle_80221590),
|
||||
.postBattle = N(afterBattle_802215B0),
|
||||
.foregroundModelList = N(foregroundModelList_802215C0),
|
||||
};
|
||||
|
||||
Vec3i N(D_802215F4_4B17E4) = { 0, 0, 0 };
|
||||
|
||||
Formation N(specialFormation_whacka) = {
|
||||
{ .actor = &N(whacka), .home = { .vec = &N(D_802215F4_4B17E4) }},
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8022161C)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_POISON, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_whacka_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_FEAR, NPC_ANIM_whacka_Palette_00_Anim_1,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_80221668)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_80221674)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 0,
|
||||
STATUS_POISON, 0,
|
||||
STATUS_FROZEN, 0,
|
||||
STATUS_DIZZY, 0,
|
||||
STATUS_FEAR, 0,
|
||||
STATUS_STATIC, 0,
|
||||
STATUS_PARALYZE, 0,
|
||||
STATUS_SHRINK, 0,
|
||||
STATUS_STOP, 0,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 0,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 0,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_80221720)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 30 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8022161C),
|
||||
.defenseTable = N(defenseTable_80221668),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 251,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc N(whacka) = {
|
||||
.flags = ACTOR_FLAG_NO_SHADOW | ACTOR_FLAG_40000,
|
||||
.type = ACTOR_TYPE_WHACKA,
|
||||
.level = 0,
|
||||
.maxHP = 99,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_80221720)),
|
||||
.partsData = N(partsTable_80221720),
|
||||
.script = N(init_8022176C),
|
||||
.statusTable = N(statusTable_80221674),
|
||||
.escapeChance = 0,
|
||||
.airLiftChance = 0,
|
||||
.spookChance = 0,
|
||||
.baseStatusChance = 0,
|
||||
.upAndAwayChance = 0,
|
||||
.spinSmashReq = 4,
|
||||
.powerBounceChance = 50,
|
||||
.coinReward = 0,
|
||||
.size = { 47, 32 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -20, 40 },
|
||||
.statusMessageOffset = { 10, 30 },
|
||||
};
|
||||
|
||||
#include "common/IsSaveVar123.inc.c"
|
||||
|
||||
EvtSource N(init_8022176C) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_80222000)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_80221828)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8022185C)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_CALL(N(IsSaveVar123))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_80221828) = {
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8022185C) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CASE_EQ(EVENT_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80222050))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80222050))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(N(80222050))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CASE_EQ(EVENT_IMMUNE)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_4)
|
||||
EVT_EXEC_WAIT(N(80222050))
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_IF_GE(100, 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_ELSE
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_80222000) = {
|
||||
EVT_CALL(RandInt, 100, LW(0))
|
||||
EVT_IF_LE(LW(0), 100)
|
||||
EVT_EXEC_WAIT(N(80222130))
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80222050) = {
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x2073)
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_1)
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 5)
|
||||
EVT_ADD(LW(1), 20)
|
||||
EVT_ADD(LW(2), 10)
|
||||
EVT_CALL(MakeItemEntity, ITEM_WHACKAS_BUMP, LW(0), LW(1), LW(2), 12, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(80222130) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, SOUND_MOLE_DIG)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_whacka_Palette_00_Anim_3)
|
||||
EVT_WAIT_FRAMES(40)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_CALL(SetBattleFlagBits2, 0x10000000, 1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 1, ACTOR_PART_FLAG_NO_TARGET, 1)
|
||||
EVT_CALL(SetActorFlagBits, ACTOR_SELF, ACTOR_FLAG_DISABLED | ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY, 1)
|
||||
EVT_CALL(RemoveActor, ACTOR_SELF)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
@ -1,5 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_sbk
|
||||
|
||||
#include "common/UnkBattleFunc1.inc.c"
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE b_area_sbk
|
||||
|
||||
#include "common/UnkFloatFunc3.inc.c"
|
||||
|
||||
#include "common/GetModelPos.inc.c"
|
682
src/battle/area_sbk/actor/bandit.c
Normal file
682
src/battle/area_sbk/actor/bandit.c
Normal file
@ -0,0 +1,682 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/battle_bandit.h"
|
||||
#include "sprite/npc/world_parakarry.h"
|
||||
|
||||
#define NAMESPACE b_area_sbk_bandit
|
||||
|
||||
extern EvtSource N(init_8021D750);
|
||||
extern EvtSource N(init_8021D7C4);
|
||||
extern EvtSource N(takeTurn_8021E900);
|
||||
extern EvtSource N(idle_8021D810);
|
||||
extern EvtSource N(handleEvent_8021DF88);
|
||||
|
||||
BSS s32 D_80220160[];
|
||||
|
||||
s32 N(idleAnimations_8021D510)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_battle_bandit_Palette_00_Anim_1,
|
||||
STATUS_STONE, NPC_ANIM_battle_bandit_Palette_00_Anim_0,
|
||||
STATUS_SLEEP, NPC_ANIM_battle_bandit_Palette_00_Anim_10,
|
||||
STATUS_POISON, NPC_ANIM_battle_bandit_Palette_00_Anim_1,
|
||||
STATUS_STOP, NPC_ANIM_battle_bandit_Palette_00_Anim_0,
|
||||
STATUS_STATIC, NPC_ANIM_battle_bandit_Palette_00_Anim_1,
|
||||
STATUS_PARALYZE, NPC_ANIM_battle_bandit_Palette_00_Anim_0,
|
||||
STATUS_DIZZY, NPC_ANIM_battle_bandit_Palette_00_Anim_11,
|
||||
STATUS_FEAR, NPC_ANIM_battle_bandit_Palette_00_Anim_11,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021D55C)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_battle_bandit_Palette_00_Anim_2,
|
||||
STATUS_STONE, NPC_ANIM_battle_bandit_Palette_00_Anim_4,
|
||||
STATUS_SLEEP, NPC_ANIM_battle_bandit_Palette_00_Anim_10,
|
||||
STATUS_POISON, NPC_ANIM_battle_bandit_Palette_00_Anim_2,
|
||||
STATUS_STOP, NPC_ANIM_battle_bandit_Palette_00_Anim_4,
|
||||
STATUS_STATIC, NPC_ANIM_battle_bandit_Palette_00_Anim_2,
|
||||
STATUS_PARALYZE, NPC_ANIM_battle_bandit_Palette_00_Anim_4,
|
||||
STATUS_DIZZY, NPC_ANIM_battle_bandit_Palette_00_Anim_11,
|
||||
STATUS_FEAR, NPC_ANIM_battle_bandit_Palette_00_Anim_11,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(idleAnimations_8021D5A8)[] = {
|
||||
STATUS_NORMAL, NPC_ANIM_battle_bandit_Palette_00_Anim_14,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
s32 N(defenseTable_8021D5B4)[] = {
|
||||
ELEMENT_NORMAL, 0,
|
||||
ELEMENT_END,
|
||||
};
|
||||
|
||||
s32 N(statusTable_8021D5C0)[] = {
|
||||
STATUS_NORMAL, 0,
|
||||
STATUS_DEFAULT, 0,
|
||||
STATUS_SLEEP, 70,
|
||||
STATUS_POISON, 20,
|
||||
STATUS_FROZEN, 100,
|
||||
STATUS_DIZZY, 90,
|
||||
STATUS_FEAR, 50,
|
||||
STATUS_STATIC, 30,
|
||||
STATUS_PARALYZE, 100,
|
||||
STATUS_SHRINK, 90,
|
||||
STATUS_STOP, 100,
|
||||
STATUS_DEFAULT_TURN_MOD, 0,
|
||||
STATUS_SLEEP_TURN_MOD, 0,
|
||||
STATUS_POISON_TURN_MOD, 0,
|
||||
STATUS_FROZEN_TURN_MOD, 0,
|
||||
STATUS_DIZZY_TURN_MOD, 0,
|
||||
STATUS_FEAR_TURN_MOD, 0,
|
||||
STATUS_STATIC_TURN_MOD, 0,
|
||||
STATUS_PARALYZE_TURN_MOD, 1,
|
||||
STATUS_SHRINK_TURN_MOD, 0,
|
||||
STATUS_STOP_TURN_MOD, 0,
|
||||
STATUS_END,
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021D66C)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_MULTI_TARGET,
|
||||
.index = 1,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { -2, 28 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021D510),
|
||||
.defenseTable = N(defenseTable_8021D5B4),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 244,
|
||||
},
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_INVISIBLE | ACTOR_PART_FLAG_NO_TARGET,
|
||||
.index = 2,
|
||||
.posOffset = { 0, 30, 0 },
|
||||
.targetOffset = { 0, 0 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021D5A8),
|
||||
.defenseTable = N(defenseTable_8021D5B4),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
};
|
||||
|
||||
ActorPartDesc N(partsTable_8021D6B4)[] = {
|
||||
{
|
||||
.flags = ACTOR_PART_FLAG_NO_TARGET,
|
||||
.index = 2,
|
||||
.posOffset = { 0, 0, 0 },
|
||||
.targetOffset = { 0, 0 },
|
||||
.opacity = 255,
|
||||
.idleAnimations = N(idleAnimations_8021D5A8),
|
||||
.defenseTable = N(defenseTable_8021D5B4),
|
||||
.eventFlags = ACTOR_EVENT_FLAG_0,
|
||||
.elementImmunityFlags = 0,
|
||||
.unk_1C = 0,
|
||||
},
|
||||
};
|
||||
|
||||
ActorDesc NAMESPACE = {
|
||||
.flags = 0,
|
||||
.type = ACTOR_TYPE_BANDIT,
|
||||
.level = 9,
|
||||
.maxHP = 5,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021D66C)),
|
||||
.partsData = N(partsTable_8021D66C),
|
||||
.script = N(init_8021D750),
|
||||
.statusTable = N(statusTable_8021D5C0),
|
||||
.escapeChance = 40,
|
||||
.airLiftChance = 90,
|
||||
.spookChance = 90,
|
||||
.baseStatusChance = 90,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 80,
|
||||
.coinReward = 1,
|
||||
.size = { 26, 32 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 25 },
|
||||
.statusMessageOffset = { 10, 25 },
|
||||
};
|
||||
|
||||
ActorDesc N(2) = {
|
||||
.flags = ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_NO_DMG_APPLY,
|
||||
.type = ACTOR_TYPE_BANDIT,
|
||||
.level = 9,
|
||||
.maxHP = 5,
|
||||
.partCount = ARRAY_COUNT(N(partsTable_8021D6B4)),
|
||||
.partsData = N(partsTable_8021D6B4),
|
||||
.script = N(init_8021D7C4),
|
||||
.statusTable = N(statusTable_8021D5C0),
|
||||
.escapeChance = 40,
|
||||
.airLiftChance = 90,
|
||||
.spookChance = 90,
|
||||
.baseStatusChance = 90,
|
||||
.upAndAwayChance = 95,
|
||||
.spinSmashReq = 0,
|
||||
.powerBounceChance = 80,
|
||||
.coinReward = 1,
|
||||
.size = { 26, 32 },
|
||||
.hpBarOffset = { 0, 0 },
|
||||
.statusIconOffset = { -10, 25 },
|
||||
.statusMessageOffset = { 10, 25 },
|
||||
};
|
||||
|
||||
Vec3i N(vector3D_8021D728) = { 0, 0xFFFFFC18, 0 };
|
||||
|
||||
Formation N(specialFormation_8021D734) = {
|
||||
{ .actor = &N(2), .home = { .vec = &N(vector3D_8021D728) }},
|
||||
};
|
||||
|
||||
EvtSource N(init_8021D750) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(takeTurn_8021E900)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(idle_8021D810)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021DF88)))
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021D7B4) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(init_8021D7C4) = {
|
||||
EVT_CALL(BindTakeTurn, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021D7B4)))
|
||||
EVT_CALL(BindIdle, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021D7B4)))
|
||||
EVT_CALL(BindHandleEvent, ACTOR_SELF, EVT_ADDR(N(handleEvent_8021D7B4)))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(idle_8021D810) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(8021D820) = {
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 0)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021D510)))
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 2, ACTOR_PART_FLAG_100000, 0)
|
||||
EVT_CALL(SummonEnemy, EVT_ADDR(N(specialFormation_8021D734)), 0)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(GetPartOffset, ACTOR_SELF, 2, LW(1), LW(2), LW(3))
|
||||
EVT_CALL(SetActorPos, LW(10), LW(1), LW(2), LW(3))
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 2, ACTOR_PART_FLAG_INVISIBLE, 1)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_CALL(SetActorVar, LW(10), 1, LW(0))
|
||||
EVT_CALL(SetActorJumpGravity, LW(10), EVT_FLOAT(1.0))
|
||||
EVT_CALL(RandInt, 360, LW(0))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(1), LW(2), LW(3))
|
||||
EVT_ADD(LW(2), 30)
|
||||
EVT_CALL(SetActorPos, LW(10), LW(1), LW(2), LW(3))
|
||||
EVT_CALL(SetActorSounds, LW(10), 2, 0, 0)
|
||||
EVT_CALL(AddVectorPolar, LW(1), LW(3), EVT_FLOAT(40.0), LW(0))
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(1), 0, LW(3))
|
||||
EVT_CALL(JumpToGoal, LW(10), 20, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_CALL(AddVectorPolar, LW(1), LW(3), EVT_FLOAT(20.0), LW(0))
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(1), 0, LW(3))
|
||||
EVT_CALL(JumpToGoal, LW(10), 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_CALL(AddVectorPolar, LW(1), LW(3), EVT_FLOAT(10.0), LW(0))
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(1), 0, LW(3))
|
||||
EVT_CALL(JumpToGoal, LW(10), 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetBattleFlags, LW(1))
|
||||
EVT_IF_FLAG(LW(1), BS_FLAGS1_80000)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_IF_NOT_FLAG(LW(1), BS_FLAGS1_100)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_WAIT_FRAMES(15)
|
||||
EVT_CALL(SetActorJumpGravity, LW(10), EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetActorSpeed, LW(10), EVT_FLOAT(6.0))
|
||||
EVT_SET(LW(0), -70)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_SET(LW(2), 10)
|
||||
EVT_LABEL(5)
|
||||
EVT_CALL(GetActorPos, LW(10), LW(3), LW(4), LW(5))
|
||||
EVT_IF_EQ(LW(3), LW(0))
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_IF_LT(LW(3), LW(0))
|
||||
EVT_SET(LW(4), LW(0))
|
||||
EVT_SUB(LW(4), LW(3))
|
||||
EVT_IF_LT(LW(4), 30)
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, LW(10), 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_ELSE
|
||||
EVT_SET(LW(4), LW(3))
|
||||
EVT_ADD(LW(3), 30)
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(3), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, LW(10), 0, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_SET(LW(4), LW(3))
|
||||
EVT_SUB(LW(4), LW(0))
|
||||
EVT_IF_LT(LW(4), 30)
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, LW(10), 5, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(3), 30)
|
||||
EVT_CALL(SetGoalPos, LW(10), LW(3), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, LW(10), 0, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x212)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_GOTO(5)
|
||||
EVT_LABEL(10)
|
||||
EVT_CALL(EnableActorBlur, LW(10), 1)
|
||||
EVT_CALL(SetTargetActor, LW(10), ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, LW(10))
|
||||
EVT_CALL(JumpToGoal, LW(10), 15, FALSE, FALSE, FALSE)
|
||||
EVT_CALL(GetGoalPos, LW(10), LW(0), LW(1), LW(2))
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_49, 0, LW(0), LW(1), LW(2), EVT_FLOAT(1.0), 0, 0, 0, 0, 0, 0, 0, 0)
|
||||
EVT_CALL(PlaySoundAtActor, LW(10), 0x211)
|
||||
EVT_CALL(GetActorVar, LW(10), 1, LW(0))
|
||||
EVT_CALL(AddCoin, LW(0))
|
||||
EVT_CALL(RemoveActor, LW(10))
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(handleEvent_8021DF88) = {
|
||||
EVT_USE_ARRAY(D_80220160)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(GetLastEvent, ACTOR_SELF, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(EVENT_HIT_COMBO)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CASE_OR_EQ(EVENT_HIT)
|
||||
EVT_CASE_OR_EQ(EVENT_SPIN_SMASH_LAUNCH_HIT)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_BURN_HIT)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_A)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_battle_bandit_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CASE_EQ(EVENT_BURN_DEATH)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_A)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_battle_bandit_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoBurnHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_B)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_HIT)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CASE_EQ(EVENT_SPIN_SMASH_DEATH)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoSpinSmashHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_SHOCK_HIT)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoJumpBack)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_EXEC_WAIT(DoReturnHome)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.6005859375))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 5, FALSE, TRUE, FALSE)
|
||||
EVT_CASE_EQ(EVENT_SHOCK_DEATH)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoShockHit)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_RETURN
|
||||
EVT_CASE_OR_EQ(EVENT_UNKNOWN_TRIGGER)
|
||||
EVT_CASE_OR_EQ(EVENT_IMMUNE)
|
||||
EVT_CASE_OR_EQ(EVENT_AIR_LIFT_FAILED)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_2)
|
||||
EVT_END_SWITCH
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_EXEC_WAIT(DoImmune)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(EVENT_DEATH)
|
||||
EVT_CASE_OR_EQ(EVENT_SPIN_SMASH_LAUNCH_DEATH)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoNormalHit)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoDeath)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_EQ(EVENT_RECOVER_STATUS)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_EXEC_WAIT(DoRecover)
|
||||
EVT_CASE_EQ(EVENT_SCARE_AWAY)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoScareAway)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_RETURN
|
||||
EVT_CASE_EQ(EVENT_BEGIN_AIR_LIFT)
|
||||
EVT_EXEC_GET_TID(N(8021D820), UW(0))
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_EXEC_WAIT(DoAirLift)
|
||||
EVT_LOOP(0)
|
||||
EVT_IS_THREAD_RUNNING(UW(0), LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_CASE_EQ(EVENT_BLOW_AWAY)
|
||||
EVT_SET_CONST(LW(0), 1)
|
||||
EVT_SET_CONST(LW(1), NPC_ANIM_battle_bandit_Palette_00_Anim_9)
|
||||
EVT_SET_CONST(LW(2), NPC_ANIM_world_parakarry_Palette_00_Anim_0)
|
||||
EVT_EXEC_WAIT(DoBlowAway)
|
||||
EVT_RETURN
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(takeTurn_8021E900) = {
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, FALSE)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 0)
|
||||
EVT_CALL(SetTargetActor, ACTOR_SELF, ACTOR_PLAYER)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 0, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_8)
|
||||
EVT_WAIT_FRAMES(30)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(10.0))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, 300, 0, 0)
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_40000, 1)
|
||||
EVT_CALL(func_8027D32C, ACTOR_SELF)
|
||||
EVT_CALL(RemoveActor, ACTOR_SELF)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_63)
|
||||
EVT_CALL(BattleCamTargetActor, ACTOR_SELF)
|
||||
EVT_CALL(func_8024ECF8, -1, 1, 0)
|
||||
EVT_CALL(GetBattlePhase, LW(0))
|
||||
EVT_IF_EQ(LW(0), PHASE_FIRST_STRIKE)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 50)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ELSE
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 50, 0, 0)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(6.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_WAIT_FRAMES(6)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(2.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(AddGoalPos, ACTOR_SELF, 35, 0, 0)
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x20C2)
|
||||
EVT_CALL(SetActorSounds, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), 0, 0, 1, BS_FLAGS1_10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_MISS)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_LUCKY)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_D)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(6.0))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(0.5))
|
||||
EVT_CALL(GetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 30)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_SUB(LW(0), 20)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 8, FALSE, TRUE, FALSE)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_IF_EQ(LW(10), HIT_RESULT_LUCKY)
|
||||
EVT_CALL(EnemyTestTarget, ACTOR_SELF, LW(0), DAMAGE_TYPE_TRIGGER_LUCKY, 0, 0, 0)
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 180)
|
||||
EVT_CALL(AddActorDecoration, ACTOR_SELF, 1, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_CALL(RemoveActorDecoration, ACTOR_SELF, 1, 0)
|
||||
EVT_CALL(SetActorYaw, ACTOR_SELF, 0)
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_D)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_CALL(ResetAllActorSounds, ACTOR_SELF)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnemyDamageTarget, ACTOR_SELF, LW(0), 0, 0, 0, 2, BS_FLAGS1_SP_EVT_ACTIVE)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_HIT)
|
||||
EVT_CASE_OR_EQ(HIT_RESULT_QUAKE_IMMUNE)
|
||||
EVT_CALL(GetLastDamage, ACTOR_PLAYER, LW(0))
|
||||
EVT_IF_LE(LW(0), 0)
|
||||
EVT_SET(LW(0), 1)
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetBattleFlags, LW(0))
|
||||
EVT_IF_FLAG(LW(0), BS_FLAGS1_ATK_BLOCKED)
|
||||
EVT_SET(LW(0), 1)
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetStatusFlags, ACTOR_SELF, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_SHRINK)
|
||||
EVT_SET(LW(0), 0)
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetStatusFlags, ACTOR_PLAYER, LW(0))
|
||||
EVT_IF_FLAG(LW(0), STATUS_FLAG_STONE)
|
||||
EVT_SET(LW(0), 0)
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_CALL(AddCoin, 0)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET(LW(0), 1)
|
||||
EVT_CASE_LT(10)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_SET(LW(0), 2)
|
||||
EVT_CASE_GE(10)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 1, 10)
|
||||
EVT_SET(LW(0), 2)
|
||||
EVT_END_SWITCH
|
||||
EVT_LABEL(10)
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_1)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 30)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_E)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x20C3)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_10)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_7)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_ADD(LW(10), 30)
|
||||
EVT_SET(LW(11), 0)
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_MUL(LW(0), -1)
|
||||
EVT_CALL(AddCoin, LW(0))
|
||||
EVT_THREAD
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 2, ACTOR_PART_FLAG_100000, 1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 2, ACTOR_PART_FLAG_INVISIBLE, 0)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartPos, ACTOR_SELF, 2, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetPartJumpGravity, ACTOR_SELF, 2, EVT_FLOAT(1.0))
|
||||
EVT_ADD(LW(11), 30)
|
||||
EVT_CALL(JumpPartTo, ACTOR_SELF, 2, LW(10), LW(11), LW(12), 22, 1)
|
||||
EVT_CALL(SetPartFlagBits, ACTOR_SELF, 2, ACTOR_PART_FLAG_100000, 0)
|
||||
EVT_END_THREAD
|
||||
EVT_THREAD
|
||||
EVT_CALL(GetActorVar, ACTOR_SELF, 1, LW(0))
|
||||
EVT_LOOP(LW(0))
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_SELF, 0x212)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_THREAD
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_SELF, EVT_FLOAT(1.80078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(10), LW(11), LW(12))
|
||||
EVT_CALL(JumpToGoal, ACTOR_SELF, 10, FALSE, TRUE, FALSE)
|
||||
EVT_CALL(SetIdleAnimations, ACTOR_SELF, 1, EVT_ADDR(N(idleAnimations_8021D55C)))
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_E)
|
||||
EVT_CALL(SetActorVar, ACTOR_SELF, 0, 1)
|
||||
EVT_WAIT_FRAMES(7)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_F)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetAnimation, ACTOR_SELF, 1, NPC_ANIM_battle_bandit_Palette_00_Anim_8)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_CALL(YieldTurn)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_SELF)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_SELF, EVT_FLOAT(8.0))
|
||||
EVT_CALL(RunToGoal, ACTOR_SELF, 0, FALSE)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(EnableIdleScript, ACTOR_SELF, 1)
|
||||
EVT_CALL(UseIdleAnimation, ACTOR_SELF, TRUE)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
1432
src/battle/area_sbk/actor/pokey.c
Normal file
1432
src/battle/area_sbk/actor/pokey.c
Normal file
File diff suppressed because it is too large
Load Diff
134
src/battle/area_sbk/area.c
Normal file
134
src/battle/area_sbk/area.c
Normal file
@ -0,0 +1,134 @@
|
||||
#include "common.h"
|
||||
#include "battle/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_sbk
|
||||
|
||||
extern ActorDesc N(pokey);
|
||||
extern ActorDesc N(bandit);
|
||||
|
||||
extern Stage N(sbk_02);
|
||||
|
||||
Formation N(formation_00) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 10 },
|
||||
};
|
||||
|
||||
Formation N(formation_01) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_02) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_03) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(pokey), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_04) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_05) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_06) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(bandit), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_07) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_08) = {
|
||||
{ .actor = &N(pokey), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(pokey), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_09) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 10 },
|
||||
};
|
||||
|
||||
Formation N(formation_0A) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0B) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_0C) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(bandit), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_0D) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 9 },
|
||||
};
|
||||
|
||||
Formation N(formation_0E) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
Formation N(formation_0F) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(bandit), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(pokey), .home = { .index = 2 }, .priority = 8 },
|
||||
{ .actor = &N(pokey), .home = { .index = 3 }, .priority = 7 },
|
||||
};
|
||||
|
||||
Formation N(formation_10) = {
|
||||
{ .actor = &N(bandit), .home = { .index = 0 }, .priority = 10 },
|
||||
{ .actor = &N(pokey), .home = { .index = 1 }, .priority = 9 },
|
||||
{ .actor = &N(bandit), .home = { .index = 2 }, .priority = 8 },
|
||||
};
|
||||
|
||||
BattleList N(formationTable) = {
|
||||
BATTLE("サンボ", N(formation_00), &N(sbk_02)),
|
||||
BATTLE("サンボx2", N(formation_01), &N(sbk_02)),
|
||||
BATTLE("サンボx3", N(formation_02), &N(sbk_02)),
|
||||
BATTLE("きいろサンボx4", N(formation_03), &N(sbk_02)),
|
||||
BATTLE("サンボ,ボロドー", N(formation_04), &N(sbk_02)),
|
||||
BATTLE("サンボx2,ボロドー", N(formation_05), &N(sbk_02)),
|
||||
BATTLE("サンボx2,ボロドーx2", N(formation_06), &N(sbk_02)),
|
||||
BATTLE("サンボ,ボロドー,サンボ", N(formation_07), &N(sbk_02)),
|
||||
BATTLE("サンボx2,ボロドー,サンボ", N(formation_08), &N(sbk_02)),
|
||||
BATTLE("ボロドー", N(formation_09), &N(sbk_02)),
|
||||
BATTLE("ボロドーx2", N(formation_0A), &N(sbk_02)),
|
||||
BATTLE("ボロドーx3", N(formation_0B), &N(sbk_02)),
|
||||
BATTLE("ボロドーx4", N(formation_0C), &N(sbk_02)),
|
||||
BATTLE("ボロドー,サンボ", N(formation_0D), &N(sbk_02)),
|
||||
BATTLE("ボロドーx2,サンボ", N(formation_0E), &N(sbk_02)),
|
||||
BATTLE("ボロドーx2,サンボx2", N(formation_0F), &N(sbk_02)),
|
||||
BATTLE("ボロドー,サンボ,ボロドー", N(formation_10), &N(sbk_02)),
|
||||
{},
|
||||
};
|
||||
|
||||
StageList N(stageTable) = {
|
||||
{ "sbk_01", &N(sbk_02) },
|
||||
{},
|
||||
};
|
63
src/battle/area_sbk/stage/sbk_02.c
Normal file
63
src/battle/area_sbk/stage/sbk_02.c
Normal file
@ -0,0 +1,63 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "battle/battle.h"
|
||||
#include "script_api/battle.h"
|
||||
|
||||
#define NAMESPACE b_area_sbk_sbk_02
|
||||
|
||||
#include "common/UnkFloatFunc3.inc.c"
|
||||
|
||||
#include "common/GetModelPos.inc.c"
|
||||
|
||||
EvtSource N(8021F720) = {
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_SET(LW(7), LW(1))
|
||||
EVT_MUL(LW(7), 10)
|
||||
EVT_CALL(N(GetModelPos))
|
||||
EVT_LABEL(0)
|
||||
EVT_ADD(LW(7), 1)
|
||||
EVT_IF_GT(LW(7), 3599)
|
||||
EVT_SUB(LW(7), 3600)
|
||||
EVT_END_IF
|
||||
EVT_CALL(N(UnkFloatFunc3), LW(7), LW(0), LW(1), LW(2))
|
||||
EVT_CALL(TranslateModel, LW(10), LW(0), LW(1), LW(2))
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_GOTO(0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(beforeBattle_8021F800) = {
|
||||
EVT_CALL(SetSpriteShading, -1)
|
||||
EVT_SET(LW(0), 1)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_EXEC(N(8021F720))
|
||||
EVT_SET(LW(0), 3)
|
||||
EVT_SET(LW(1), 120)
|
||||
EVT_EXEC(N(8021F720))
|
||||
EVT_SET(LW(0), 5)
|
||||
EVT_SET(LW(1), 240)
|
||||
EVT_EXEC(N(8021F720))
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(afterBattle_8021F8E8) = {
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 N(foregroundModelList_8021F8F8)[] = {
|
||||
0x00000028, 0x00000027, 0x00000026, 0x00000025, 0x00000000,
|
||||
};
|
||||
|
||||
Stage NAMESPACE = {
|
||||
.texture = "sbk_tex",
|
||||
.shape = "sbk_bt02_shape",
|
||||
.hit = "sbk_bt02_hit",
|
||||
.bg = "sbk_bg",
|
||||
.preBattle = N(beforeBattle_8021F800),
|
||||
.postBattle = N(afterBattle_8021F8E8),
|
||||
.foregroundModelList = N(foregroundModelList_8021F8F8),
|
||||
};
|
@ -66,20 +66,20 @@ BattleArea gBattleAreas[0x30] = {
|
||||
{
|
||||
AREA(area_iwa),
|
||||
.name = "エリア IWA",
|
||||
.battles = 0x802185B8,
|
||||
.stages = 0x802186E4,
|
||||
.battles = &b_area_iwa_formationTable,
|
||||
.stages = &b_area_iwa_stageTable,
|
||||
},
|
||||
{
|
||||
AREA(area_sbk),
|
||||
.name = "エリア SBK",
|
||||
.battles = 0x8021FE80,
|
||||
.stages = 0x8021FFE8,
|
||||
.battles = &b_area_sbk_formationTable,
|
||||
.stages = &b_area_sbk_stageTable,
|
||||
},
|
||||
{
|
||||
AREA(area_isk_part_1),
|
||||
.name = "エリア ISK その1",
|
||||
.battles = 0x80224700,
|
||||
.stages = 0x802248A4,
|
||||
.battles = &b_area_isk_part_1_formationTable,
|
||||
.stages = &b_area_isk_part_1_stageTable,
|
||||
},
|
||||
{
|
||||
AREA(area_isk_part_2),
|
||||
|
@ -31,4 +31,13 @@ extern StageList b_area_trd_part_2_stageTable;
|
||||
extern BattleList b_area_trd_part_3_formationTable;
|
||||
extern StageList b_area_trd_part_3_stageTable;
|
||||
|
||||
extern BattleList b_area_iwa_formationTable;
|
||||
extern StageList b_area_iwa_stageTable;
|
||||
|
||||
extern BattleList b_area_sbk_formationTable;
|
||||
extern StageList b_area_sbk_stageTable;
|
||||
|
||||
extern BattleList b_area_isk_part_1_formationTable;
|
||||
extern StageList b_area_isk_part_1_stageTable;
|
||||
|
||||
#endif
|
||||
|
@ -15,7 +15,7 @@ s32 N(D_802A10F0)[] = {
|
||||
|
||||
#include "world/common/UnkMoveFunc1.inc.c"
|
||||
|
||||
EvtSource D_802A1130_765D50 = {
|
||||
EvtSource N(CheckForAPress) = {
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_BEFORE_JUMP)
|
||||
EVT_LOOP(5)
|
||||
EVT_CALL(CheckButtonPress, A_BUTTON, LW(0))
|
||||
@ -46,7 +46,7 @@ EvtSource D_802A11AC_765DCC = {
|
||||
EVT_CALL(CancelablePlayerRunToGoal, 0, LW(0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_EXEC_WAIT(D_802A1130_765D50)
|
||||
EVT_EXEC_WAIT(N(CheckForAPress))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_BEFORE_JUMP)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
|
@ -18,8 +18,8 @@ s32 N(D_802A10F0)[] = {
|
||||
EvtSource N(CheckForAPress) = {
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_BEFORE_JUMP)
|
||||
EVT_LOOP(5)
|
||||
EVT_CALL(CheckButtonPress, 32768, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(CheckButtonPress, A_BUTTON, LW(0))
|
||||
EVT_IF_EQ(LW(0), TRUE)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE battle_move_hammer
|
||||
|
||||
#include "world/common/IsBerserkerEquipped.inc.c"
|
||||
|
||||
#include "world/common/IsRightOnEquipped.inc.c"
|
942
src/battle/move/hammer/hammer.c
Normal file
942
src/battle/move/hammer/hammer.c
Normal file
@ -0,0 +1,942 @@
|
||||
#include "common.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "sprite/npc/world_bombette.h"
|
||||
#include "battle/action_cmd/hammer.h"
|
||||
|
||||
#define NAMESPACE battle_move_hammer
|
||||
|
||||
extern EvtSource D_802A3168_00736708;
|
||||
extern EvtSource D_802A3C4C_007371EC;
|
||||
|
||||
#include "world/common/IsBerserkerEquipped.inc.c"
|
||||
|
||||
#include "world/common/IsRightOnEquipped.inc.c"
|
||||
|
||||
EvtSource D_802A10B0_734650 = {
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 32)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_26)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A118C_0073472C = {
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, -33, 0, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_26)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1204_007347A4 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000D)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000D)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1388_00734928 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30014)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30014)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A150C_00734AAC = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001B)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001B)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1690_00734C30 = {
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000E)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(func_802A9258_422258, 0, 36, 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000F)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30011)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30012)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A18AC_00734E4C = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_E)
|
||||
EVT_CALL(MoveBattleCamOver, 5)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1998_00734F38 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1A64_00735004 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_29)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(D_802A1B40) = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_734650)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1204_007347A4)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000E)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000F)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000F)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30010)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_EQ(LW(0), 2)
|
||||
EVT_CALL(SetActionCommandMode, 3)
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30011)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2115)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30012)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2118)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2000_007355A0 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_734650)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1388_00734928)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30015)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30016)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30017)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30016)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30017)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30018)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2116)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30019)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2119)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A23E8_735988 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_734650)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A150C_00734AAC)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001C)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001D)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001E)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001D)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001E)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001F)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2117)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30020)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211A)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(D_802A27D0) = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073472C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1204_007347A4)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000E)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3000F)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2115)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30011)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30012)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2118)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2AFC_0073609C = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073472C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1388_00734928)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30015)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30016)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_LOOP(60)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2116)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30018)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30019)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2119)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2DA0_00736340 = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073472C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A150C_00734AAC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001C)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001D)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_LOOP(60)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 0x40000, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2117)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_3001F)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30020)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211A)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3044_007365E4 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET(LW(13), 45)
|
||||
EVT_SET(LW(14), 1)
|
||||
EVT_SET(LW(15), 2)
|
||||
EVT_EXEC_WAIT(D_802A3168_00736708)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_SET(LW(13), 45)
|
||||
EVT_SET(LW(14), 2)
|
||||
EVT_SET(LW(15), 4)
|
||||
EVT_EXEC_WAIT(D_802A3168_00736708)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_SET(LW(13), 45)
|
||||
EVT_SET(LW(14), 3)
|
||||
EVT_SET(LW(15), 6)
|
||||
EVT_EXEC_WAIT(D_802A3168_00736708)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3168_00736708 = {
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(N(D_802A1B40))
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A2000_007355A0)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A23E8_735988)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(GetActionSuccessCopy, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(StartRumble, 7)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(StartRumble, 7)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 25, 0, 0, 16)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_HIT_NORMAL)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 64, 25, 0, LW(15), 112)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_HIT_NORMAL)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 64, 25, 0, LW(14), 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_EXEC_WAIT(D_802A18AC_00734E4C)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A369C_00736C3C = {
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET(LW(9), 1)
|
||||
EVT_SET_CONST(LW(10), NPC_ANIM_world_bombette_normal_celebrate)
|
||||
EVT_SET_CONST(LW(11), NPC_ANIM_world_bombette_normal_anim_11)
|
||||
EVT_SET_CONST(LW(12), ANIM_30012)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_SET(LW(9), 2)
|
||||
EVT_SET_CONST(LW(10), ANIM_30016)
|
||||
EVT_SET_CONST(LW(11), ANIM_30017)
|
||||
EVT_SET_CONST(LW(12), ANIM_30019)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_SET(LW(9), 3)
|
||||
EVT_SET_CONST(LW(10), ANIM_3001D)
|
||||
EVT_SET_CONST(LW(11), ANIM_3001E)
|
||||
EVT_SET_CONST(LW(12), ANIM_30020)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 32)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetActorPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(func_8024E664, 43)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, LW(10))
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, LW(11))
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, LW(12))
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2115)
|
||||
EVT_CALL(StartRumble, 7)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2116)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2117)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 25, 0, 0, 16)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_HIT_NORMAL)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 64, 25, 0, LW(9), 48)
|
||||
EVT_EXEC_WAIT(D_802A18AC_00734E4C)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3B28_007370C8 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET(LW(13), 75)
|
||||
EVT_SET(LW(14), 1)
|
||||
EVT_SET(LW(15), 2)
|
||||
EVT_EXEC_WAIT(D_802A3C4C_007371EC)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_SET(LW(13), 66)
|
||||
EVT_SET(LW(14), 2)
|
||||
EVT_SET(LW(15), 4)
|
||||
EVT_EXEC_WAIT(D_802A3C4C_007371EC)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_SET(LW(13), 57)
|
||||
EVT_SET(LW(14), 3)
|
||||
EVT_SET(LW(15), 6)
|
||||
EVT_EXEC_WAIT(D_802A3C4C_007371EC)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3C4C_007371EC = {
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(N(D_802A1B40))
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A2000_007355A0)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A23E8_735988)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 25, 0, LW(9), 16)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(StartRumble, 10)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActionSuccessCopy, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(StartRumble, 10)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(StartRumble, 8)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.30078125))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.6005859375))
|
||||
EVT_END_THREAD
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(StartRumble, 10)
|
||||
EVT_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(1.900390625))
|
||||
EVT_END_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 25, 0, 0, 16)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_HIT_NORMAL)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 64, 25, 0, LW(15), 112)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_HIT_NORMAL)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10E)
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 64, 25, 0, LW(14), 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_EXEC_WAIT(D_802A18AC_00734E4C)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A64_00735004)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
@ -1,23 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE battle_move_jump
|
||||
|
||||
#include "world/common/UnkMoveFunc1.inc.c"
|
||||
|
||||
ApiStatus func_802A10E4_73D944(Evt* script, s32 isInitialCall) {
|
||||
script->varTable[15] = 1;
|
||||
|
||||
switch (gPlayerData.bootsLevel) {
|
||||
case 0:
|
||||
script->varTable[15] = 1;
|
||||
break;
|
||||
case 1:
|
||||
script->varTable[15] = 2;
|
||||
break;
|
||||
case 2:
|
||||
script->varTable[15] = 3;
|
||||
break;
|
||||
}
|
||||
|
||||
return ApiStatus_DONE2;
|
||||
}
|
926
src/battle/move/jump/jump.c
Normal file
926
src/battle/move/jump/jump.c
Normal file
@ -0,0 +1,926 @@
|
||||
#include "common.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "battle/action_cmd/jump.h"
|
||||
|
||||
#define NAMESPACE battle_move_jump
|
||||
|
||||
extern EvtSource D_802A4018_740878;
|
||||
extern EvtSource D_802A2720_73EF80;
|
||||
extern EvtSource D_802A2ABC_73F31C;
|
||||
extern EvtSource D_802A2DE8_73F648;
|
||||
extern EvtSource D_802A3188_73F9E8;
|
||||
extern EvtSource D_802A3378_73FBD8;
|
||||
extern EvtSource D_802A34EC_73FD4C;
|
||||
extern EvtSource D_802A36D8_73FF38;
|
||||
extern EvtSource D_802A39C4_740224;
|
||||
extern EvtSource D_802A3CF0_740550;
|
||||
|
||||
s32 D_802A1140_73D9A0[] = {
|
||||
9, 3, 9, 3,
|
||||
9, 3, 8, 3,
|
||||
7, 3, 6, 2,
|
||||
5, 2, 4, 2,
|
||||
};
|
||||
|
||||
#include "world/common/UnkMoveFunc1.inc.c"
|
||||
|
||||
EvtSource N(CheckForAPress) = {
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_BEFORE_JUMP)
|
||||
EVT_LOOP(5)
|
||||
EVT_CALL(CheckButtonPress, A_BUTTON, LW(0))
|
||||
EVT_IF_EQ(LW(0), TRUE)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource N(MoveToJump) = {
|
||||
EVT_CALL(SetGoalToFirstTarget, ACTOR_SELF)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 40)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_SUB(LW(3), EVT_FLOAT(70.0))
|
||||
EVT_IF_LT(LW(0), LW(3))
|
||||
EVT_SET(LW(3), LW(0))
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_26)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(CancelablePlayerRunToGoal, 0, LW(0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_EXEC_WAIT(N(CheckForAPress))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_BEFORE_JUMP)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1370_73DBD0 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(6), LW(7), LW(8))
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(7), LW(8), LW(9))
|
||||
EVT_IF_GT(LW(6), LW(7))
|
||||
EVT_SUB(LW(6), LW(7))
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(7), LW(6))
|
||||
EVT_SET(LW(6), LW(7))
|
||||
EVT_END_IF
|
||||
EVT_SUB(LW(6), 20)
|
||||
EVT_DIVF(LW(6), EVT_FLOAT(10.5888671875))
|
||||
EVT_ADDF(LW(6), 15)
|
||||
EVT_SET(LW(10), LW(6))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1458_73DCB8 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(6), LW(7), LW(8))
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(7), LW(8), LW(9))
|
||||
EVT_IF_GT(LW(6), LW(7))
|
||||
EVT_SUB(LW(6), LW(7))
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(7), LW(6))
|
||||
EVT_SET(LW(6), LW(7))
|
||||
EVT_END_IF
|
||||
EVT_SUB(LW(6), 20)
|
||||
EVT_DIVF(LW(6), EVT_FLOAT(22.5))
|
||||
EVT_ADDF(LW(6), 15)
|
||||
EVT_SET(LW(10), LW(6))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1540_73DDA0 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(6), LW(7), LW(8))
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(7), LW(8), LW(9))
|
||||
EVT_IF_GT(LW(6), LW(7))
|
||||
EVT_SUB(LW(6), LW(7))
|
||||
EVT_ELSE
|
||||
EVT_SUB(LW(7), LW(6))
|
||||
EVT_SET(LW(6), LW(7))
|
||||
EVT_END_IF
|
||||
EVT_SUB(LW(6), 20)
|
||||
EVT_DIVF(LW(6), EVT_FLOAT(18.0))
|
||||
EVT_ADDF(LW(6), 22)
|
||||
EVT_SET(LW(10), LW(6))
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1628_73DE88 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_D)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 40)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_10009)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(1.30078125))
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(N(UnkMoveFunc1))
|
||||
EVT_CALL(func_80273444, LW(0), 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -20, 0, 0)
|
||||
EVT_CALL(func_80273444, 6, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1814_73E074 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_D)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 50)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_10009)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(N(UnkMoveFunc1))
|
||||
EVT_CALL(func_80273444, LW(0), 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -30, 0, 0)
|
||||
EVT_CALL(func_80273444, 6, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1A00_73E260 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_29)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 40)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_10009)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(1.0))
|
||||
EVT_CALL(N(UnkMoveFunc1))
|
||||
EVT_CALL(func_80273444, LW(0), 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -20, 0, 0)
|
||||
EVT_CALL(func_80273444, 6, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1BEC_73E44C = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_D)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 60)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_10009)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(0.80078125))
|
||||
EVT_CALL(N(UnkMoveFunc1))
|
||||
EVT_CALL(func_80273444, LW(0), 0, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -20, 0, 0)
|
||||
EVT_CALL(func_80273444, 6, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10009)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1DD8_73E638 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_D)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 60)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_FALL_BACK, ANIM_FALL_BACK, ANIM_10009)
|
||||
EVT_CALL(N(UnkMoveFunc1))
|
||||
EVT_CALL(func_80273444, LW(0), 0, 0)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(1.0))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -30, 0, 0)
|
||||
EVT_CALL(func_80273444, 8, 0, 2)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(1.0))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -20, 0, 0)
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(func_80273444, 6, 0, 2)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(1.0))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(func_80273444, 4, 0, 2)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A203C_73E89C = {
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, 0, 0, ANIM_1000C)
|
||||
EVT_CALL(PlayerLandJump)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_1000C)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(1.0))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, SOUND_162)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_GET_UP)
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_DUST_OFF)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(SetBattleFlagBits, BS_FLAGS1_100, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_D)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A21D4_73EA34 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_EXEC_WAIT(N(MoveToJump))
|
||||
EVT_EXEC_WAIT(D_802A1370_73DBD0)
|
||||
EVT_CALL(func_802A9120_421B10, LW(10), 3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_34)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_30000)
|
||||
EVT_CALL(func_80274A18, LW(10), 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2280 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_EXEC_WAIT(N(MoveToJump))
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_EXEC_WAIT(D_802A1458_73DCB8)
|
||||
EVT_SET(LW(11), LW(10))
|
||||
EVT_ADD(LW(11), 14)
|
||||
EVT_ADD(LW(11), -3)
|
||||
EVT_CALL(func_802A9120_421B10, LW(11), 3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_37)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_1000A, ANIM_1000B)
|
||||
EVT_CALL(func_802752AC, LW(10), 0)
|
||||
EVT_WAIT_FRAMES(7)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(func_802752AC, 3, 1)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(func_802752AC, 5, 1)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A23D4_73EC34 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_EXEC_WAIT(N(MoveToJump))
|
||||
EVT_EXEC_WAIT(D_802A1540_73DDA0)
|
||||
EVT_CALL(func_8026919C, EVT_ADDR(D_802A1140_73D9A0))
|
||||
EVT_SET(LW(11), LW(10))
|
||||
EVT_SUB(LW(11), 4)
|
||||
EVT_ADD(LW(11), -3)
|
||||
EVT_CALL(func_802A9120_421B10, LW(11), 3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_38)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, 524288, ANIM_30000)
|
||||
EVT_CALL(func_80275F00, LW(10), 0)
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_SET(LW(9), 0)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_SET(LW(9), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_30000)
|
||||
EVT_CALL(SetActorRotation, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, -2, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(SetActorDispOffset, ACTOR_SELF, 0, 0, 0)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802A9120_421B10, 13, 3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_39)
|
||||
EVT_CALL(func_80275F00, 15, 2)
|
||||
EVT_GOTO(10)
|
||||
EVT_ELSE
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802A9120_421B10, 2, 3)
|
||||
EVT_CALL(func_80275F00, 4, 1)
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_LABEL(10)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2650_73EEB0 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetBattleFlags2, LW(0))
|
||||
EVT_IF_FLAG(LW(0), BS_FLAGS2_200)
|
||||
EVT_EXEC_WAIT(D_802A4018_740878)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(D_802A2720_73EF80)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A2ABC_73F31C)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A2DE8_73F648)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2720_73EF80 = {
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_EQ(LW(0), 2)
|
||||
EVT_CALL(SetActionCommandMode, 3)
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_27)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 24, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_1000C)
|
||||
EVT_CALL(func_80274A18, 24, 3)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2ABC_73F31C = {
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_27)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 37, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(EnablePlayerBlur, 1)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_1000A, ANIM_1000B)
|
||||
EVT_CALL(func_802752AC, 20, 4)
|
||||
EVT_WAIT_FRAMES(7)
|
||||
EVT_CALL(func_802752AC, 3, 5)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2DE8_73F648 = {
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_28)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 25, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(EnablePlayerBlur, 1)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR_STILL, ANIM_1000C)
|
||||
EVT_CALL(func_80275F00, 25, 4)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A30F4_73F954 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(D_802A3188_73F9E8)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A3378_73FBD8)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A34EC_73FD4C)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
ApiStatus N(GetJumpDamage)(Evt* script, s32 isInitialCall) {
|
||||
script->varTable[15] = 1;
|
||||
|
||||
switch (gPlayerData.bootsLevel) {
|
||||
case 0:
|
||||
script->varTable[15] = 1;
|
||||
break;
|
||||
case 1:
|
||||
script->varTable[15] = 2;
|
||||
break;
|
||||
case 2:
|
||||
script->varTable[15] = 3;
|
||||
break;
|
||||
}
|
||||
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
EvtSource D_802A3188_73F9E8 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_SUB(LW(3), 40)
|
||||
EVT_SET(LW(4), 40)
|
||||
EVT_CALL(SetActorPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(func_8024E664, 34)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_SUB(LW(0), LW(3))
|
||||
EVT_SUB(LW(0), 20)
|
||||
EVT_DIVF(LW(0), EVT_FLOAT(10.5888671875))
|
||||
EVT_ADDF(LW(0), 15)
|
||||
EVT_SET(LW(10), LW(0))
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorJumpGravity, ACTOR_PLAYER, EVT_FLOAT(1.0))
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_30000)
|
||||
EVT_CALL(func_80274A18, LW(10), 0)
|
||||
EVT_CALL(N(GetJumpDamage))
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, LW(15), 48)
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3378_73FBD8 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_SUB(LW(3), 40)
|
||||
EVT_SET(LW(4), 40)
|
||||
EVT_CALL(SetActorPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_EXEC_WAIT(D_802A1458_73DCB8)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_37)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_1000A, ANIM_1000B)
|
||||
EVT_CALL(func_802752AC, LW(10), 0)
|
||||
EVT_WAIT_FRAMES(7)
|
||||
EVT_CALL(func_802752AC, 3, 1)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(func_8024E664, 34)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 4, 48)
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A34EC_73FD4C = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(GetGoalPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_SUB(LW(3), 40)
|
||||
EVT_SET(LW(4), 40)
|
||||
EVT_CALL(SetActorPos, ACTOR_PLAYER, LW(3), LW(4), LW(5))
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_EXEC_WAIT(D_802A1540_73DDA0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_38)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR_STILL, ANIM_30000)
|
||||
EVT_CALL(func_80275F00, LW(10), 0)
|
||||
EVT_SET(LW(10), 4)
|
||||
EVT_CALL(func_80275F00, LW(10), 1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 6, 48)
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3644_73FEA4 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(D_802A36D8_73FF38)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A39C4_740224)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A3CF0_740550)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A36D8_73FF38 = {
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_27)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 24, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_1000C)
|
||||
EVT_CALL(func_80274A18, 24, 3)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A39C4_740224 = {
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_27)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 37, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(EnablePlayerBlur, 1)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_1000A, ANIM_1000B)
|
||||
EVT_CALL(func_802752AC, 20, 4)
|
||||
EVT_WAIT_FRAMES(7)
|
||||
EVT_CALL(func_802752AC, 3, 5)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 347, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 2, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3CF0_740550 = {
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_EXEC_WAIT(D_802A21D4_73EA34)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_28)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 25, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(EnablePlayerBlur, 1)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR_STILL, ANIM_1000C)
|
||||
EVT_CALL(func_80275F00, 25, 4)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 348, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 3, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A4018_740878 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_EXEC_WAIT(N(MoveToJump))
|
||||
EVT_EXEC_WAIT(D_802A1370_73DBD0)
|
||||
EVT_CALL(func_802A9120_421B10, LW(10), 3)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_34)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, -5, 10, 0)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_30000)
|
||||
EVT_CALL(func_80274A18, LW(10), 0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_EQ(LW(0), 2)
|
||||
EVT_CALL(SetActionCommandMode, 3)
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 128, 0, 0, 1, 0)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_EXEC_WAIT(D_802A203C_73E89C)
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_IF
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 80)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_OR_EQ(0)
|
||||
EVT_CASE_OR_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A1A00_73E260)
|
||||
EVT_RETURN
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_CASE_OR_EQ(1)
|
||||
EVT_CASE_OR_EQ(3)
|
||||
EVT_END_CASE_GROUP
|
||||
EVT_END_SWITCH
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_27)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_35)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(func_80269524, LW(15))
|
||||
EVT_CALL(CloseActionCommandInfo)
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_JUMP)
|
||||
EVT_CALL(action_command_jump_CreateHudElements)
|
||||
EVT_CALL(func_802694A4, 0)
|
||||
EVT_CALL(func_802A9120_421B10, 24, 3)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(SetJumpAnimations, ACTOR_PLAYER, 0, ANIM_MIDAIR_STILL, ANIM_MIDAIR, ANIM_1000C)
|
||||
EVT_CALL(func_80274A18, 24, 3)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(SetActorSounds, ACTOR_PLAYER, 3, 346, 0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 128, 0, 0, 1, 224)
|
||||
EVT_CALL(func_80269550, LW(15))
|
||||
EVT_EXEC_WAIT(D_802A1628_73DE88)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
@ -1,7 +0,0 @@
|
||||
#include "common.h"
|
||||
|
||||
#define NAMESPACE battle_move_quake_hammer
|
||||
|
||||
#include "world/common/IsBerserkerEquipped.inc.c"
|
||||
|
||||
#include "world/common/IsRightOnEquipped.inc.c"
|
739
src/battle/move/quake_hammer/quake_hammer.c
Normal file
739
src/battle/move/quake_hammer/quake_hammer.c
Normal file
@ -0,0 +1,739 @@
|
||||
#include "common.h"
|
||||
#include "effects.h"
|
||||
#include "script_api/battle.h"
|
||||
#include "battle/action_cmd/hammer.h"
|
||||
|
||||
#define NAMESPACE battle_move_quake_hammer
|
||||
|
||||
extern EvtSource D_802A3168_0073D038;
|
||||
|
||||
#include "world/common/IsBerserkerEquipped.inc.c"
|
||||
|
||||
#include "world/common/IsRightOnEquipped.inc.c"
|
||||
|
||||
EvtSource D_802A10B0_73AF80 = {
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_CALL(GetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_SUB(LW(0), 32)
|
||||
EVT_CALL(SetGoalPos, ACTOR_SELF, LW(0), LW(1), LW(2))
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_26)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A118C_0073B05C = {
|
||||
EVT_CALL(SetGoalPos, ACTOR_PLAYER, -33, 0, 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_26)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(5.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1204_0073B0D4 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000D)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000D)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1388_0073B258 = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030014)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030014)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A150C_0073B3DC = {
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(10)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_ADD(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001B)
|
||||
EVT_END_LOOP
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001B)
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_LT(3)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CASE_LT(5)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CASE_LT(7)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CASE_LT(9)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CASE_LT(11)
|
||||
EVT_WAIT_FRAMES(0)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1690_0073B560 = {
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000E)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(func_802A9258_422258, 0, 36, 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000F)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030011)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030012)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_44)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A18AC_0073B77C = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_E)
|
||||
EVT_CALL(MoveBattleCamOver, 5)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1998_0073B868 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1A64_0073B934 = {
|
||||
EVT_CALL(func_80276EFC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_29)
|
||||
EVT_CALL(func_802693F0)
|
||||
EVT_WAIT_FRAMES(20)
|
||||
EVT_CALL(EnablePlayerBlur, -1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_CALL(SetGoalToHome, ACTOR_PLAYER)
|
||||
EVT_CALL(SetActorSpeed, ACTOR_PLAYER, EVT_FLOAT(8.0))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_RUNNING)
|
||||
EVT_CALL(PlayerRunToGoal, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A1B40 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_73AF80)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1204_0073B0D4)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000E)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000F)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000F)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030010)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_EQ(LW(0), 2)
|
||||
EVT_CALL(SetActionCommandMode, 3)
|
||||
EVT_LOOP(0)
|
||||
EVT_CALL(GetActionCommandMode, LW(0))
|
||||
EVT_IF_LT(LW(0), 2)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030011)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2115)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030012)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2118)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2000_0073BED0 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_73AF80)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1388_0073B258)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030015)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030016)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030017)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030016)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030017)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030018)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2116)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030019)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2119)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A23E8 = {
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A10B0_73AF80)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A150C_0073B3DC)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 64, 0, 0, 0, 16)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(SetBattleCamOffsetZ, 8)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001C)
|
||||
EVT_WAIT_FRAMES(4)
|
||||
EVT_CALL(N(IsBerserkerEquipped))
|
||||
EVT_IF_EQ(LW(0), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001D)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001E)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_ELSE
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(1), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001D)
|
||||
EVT_SUB(LW(1), 10)
|
||||
EVT_WAIT_FRAMES(LW(1))
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001E)
|
||||
EVT_WAIT_FRAMES(5)
|
||||
EVT_END_IF
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001F)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2117)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030020)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211A)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A27D0 = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073B05C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1204_0073B0D4)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000E)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03000F)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_CALL(SetActionResult, 0)
|
||||
EVT_SET(LW(1), 0)
|
||||
EVT_LOOP(30)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionResult, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_IF_NE(LW(1), 1)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030010)
|
||||
EVT_SET(LW(1), 1)
|
||||
EVT_END_IF
|
||||
EVT_END_IF
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2115)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030011)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030012)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2118)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2AFC_0073C9CC = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073B05C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A1388_0073B258)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030015)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030016)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_LOOP(60)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2116)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030018)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030019)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2119)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A2DA0_0073CC70 = {
|
||||
EVT_CALL(ChooseNextTarget, 10, LW(0))
|
||||
EVT_CALL(LoadActionCommand, ACTION_COMMAND_SMASH)
|
||||
EVT_CALL(action_command_hammer_CreateHudElements)
|
||||
EVT_EXEC_WAIT(D_802A118C_0073B05C)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(AddGoalPos, ACTOR_PLAYER, 0, 0, 0)
|
||||
EVT_EXEC_WAIT(D_802A150C_0073B3DC)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_43)
|
||||
EVT_CALL(AddBattleCamZoom, 80)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x10B)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001C)
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001D)
|
||||
EVT_CALL(N(IsRightOnEquipped))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_LOOP(45)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_NE(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_END_IF
|
||||
EVT_ADD(LW(13), 6)
|
||||
EVT_CALL(func_802A9258_422258, 0, LW(13), 3)
|
||||
EVT_LOOP(60)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(CheckButtonDown, 262144, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_BREAK_LOOP
|
||||
EVT_END_IF
|
||||
EVT_END_LOOP
|
||||
EVT_LABEL(0)
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(GetActionSuccess, LW(0))
|
||||
EVT_IF_EQ(LW(0), 0)
|
||||
EVT_GOTO(0)
|
||||
EVT_END_IF
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2117)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x03001F)
|
||||
EVT_WAIT_FRAMES(3)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, 0x030020)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211A)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3044_0073CF14 = {
|
||||
EVT_CALL(func_802694A4, 1)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_SET(LW(13), 80)
|
||||
EVT_SET(LW(14), 1)
|
||||
EVT_SET(LW(15), 2)
|
||||
EVT_EXEC_WAIT(D_802A3168_0073D038)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_SET(LW(13), 80)
|
||||
EVT_SET(LW(14), 1)
|
||||
EVT_SET(LW(15), 2)
|
||||
EVT_EXEC_WAIT(D_802A3168_0073D038)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_SET(LW(13), 80)
|
||||
EVT_SET(LW(14), 1)
|
||||
EVT_SET(LW(15), 2)
|
||||
EVT_EXEC_WAIT(D_802A3168_0073D038)
|
||||
EVT_END_SWITCH
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource D_802A3168_0073D038 = {
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_EXEC_WAIT(D_802A27D0)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_EXEC_WAIT(D_802A2AFC_0073C9CC)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_EXEC_WAIT(D_802A2DA0_0073CC70)
|
||||
EVT_END_SWITCH
|
||||
EVT_CHILD_THREAD
|
||||
EVT_WAIT_FRAMES(8)
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 24)
|
||||
EVT_ADD(LW(1), 10)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 60, 8, 0, 30, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 60, 8, 33, 30, 0, 0, 0, 0, 0)
|
||||
EVT_WAIT_FRAMES(2)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 1, LW(0), LW(1), LW(2), 60, 8, 66, 30, 0, 0, 0, 0, 0)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(0.2001953125))
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(1.0))
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(2.0))
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(1.0))
|
||||
EVT_CALL(ShakeCam, 1, 0, 3, EVT_FLOAT(0.7001953125))
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(0.400390625))
|
||||
EVT_CALL(ShakeCam, 1, 0, 6, EVT_FLOAT(0.1005859375))
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(0.05078125))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(GetActorPos, ACTOR_PLAYER, LW(0), LW(1), LW(2))
|
||||
EVT_ADD(LW(0), 24)
|
||||
EVT_ADD(LW(1), 10)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 0, LW(0), LW(1), LW(2), 72, 8, 0, 30, 0, 0, 0, 0, 0)
|
||||
EVT_CALL(PlayEffect, EFFECT_ID_1D, 0, LW(0), LW(1), LW(2), 72, 8, 24, 30, 0, 0, 0, 0, 0)
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(StartRumble, 9)
|
||||
EVT_CHILD_THREAD
|
||||
EVT_CALL(ShakeCam, 1, 0, 2, EVT_FLOAT(0.1005859375))
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(0.5))
|
||||
EVT_CALL(ShakeCam, 1, 0, 10, EVT_FLOAT(1.0))
|
||||
EVT_CALL(ShakeCam, 1, 0, 5, EVT_FLOAT(0.5))
|
||||
EVT_CALL(ShakeCam, 1, 0, 3, EVT_FLOAT(0.3505859375))
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(0.2001953125))
|
||||
EVT_CALL(ShakeCam, 1, 0, 6, EVT_FLOAT(0.05078125))
|
||||
EVT_CALL(ShakeCam, 1, 0, 4, EVT_FLOAT(0.025390625))
|
||||
EVT_END_CHILD_THREAD
|
||||
EVT_END_SWITCH
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_IF_GT(LW(0), 0)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_46)
|
||||
EVT_CALL(MoveBattleCamOver, 5)
|
||||
EVT_ELSE
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_46)
|
||||
EVT_CALL(MoveBattleCamOver, 50)
|
||||
EVT_END_IF
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211B)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211C)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211D)
|
||||
EVT_END_SWITCH
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(GetMenuSelection, LW(0), LW(1), LW(2))
|
||||
EVT_SWITCH(LW(1))
|
||||
EVT_CASE_EQ(0)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2118)
|
||||
EVT_CASE_EQ(1)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x2119)
|
||||
EVT_CASE_EQ(2)
|
||||
EVT_CALL(PlaySoundAtActor, ACTOR_PLAYER, 0x211A)
|
||||
EVT_END_SWITCH
|
||||
EVT_SET(LW(9), 0)
|
||||
EVT_CALL(InitTargetIterator)
|
||||
EVT_LABEL(10)
|
||||
EVT_CALL(SetGoalToTarget, ACTOR_PLAYER)
|
||||
EVT_CALL(PlayerTestEnemy, LW(0), 2097152, 29, 0, 0, 16)
|
||||
EVT_IF_EQ(LW(0), 6)
|
||||
EVT_GOTO(11)
|
||||
EVT_END_IF
|
||||
EVT_CALL(DidActionSucceed, LW(0))
|
||||
EVT_SWITCH(LW(0))
|
||||
EVT_CASE_GT(0)
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 941623296, 25, 0, LW(15), 112)
|
||||
EVT_CASE_DEFAULT
|
||||
EVT_CALL(PlayerDamageEnemy, LW(0), 941623296, 25, 0, LW(14), 48)
|
||||
EVT_END_SWITCH
|
||||
EVT_LABEL(11)
|
||||
EVT_CALL(ChooseNextTarget, 0, LW(1))
|
||||
EVT_ADD(LW(9), 1)
|
||||
EVT_CALL(GetTargetListLength, LW(1))
|
||||
EVT_IF_LT(LW(9), LW(1))
|
||||
EVT_GOTO(10)
|
||||
EVT_END_IF
|
||||
EVT_THREAD
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_CALL(SetAnimation, ACTOR_PLAYER, 0, ANIM_10002)
|
||||
EVT_END_THREAD
|
||||
EVT_WAIT_FRAMES(10)
|
||||
EVT_EXEC_WAIT(D_802A1998_0073B868)
|
||||
EVT_CALL(UseBattleCamPreset, BTL_CAM_PRESET_C)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
@ -1,7 +1,7 @@
|
||||
#include "common.h"
|
||||
|
||||
ApiStatus N(ChompChainInit)(Evt* script, s32 isInitialCall) {
|
||||
Actor* actor = get_actor(script->owner1.actor);
|
||||
Actor* actor = get_actor(script->owner1.actorID);
|
||||
ActorPart* actorPart;
|
||||
ChompChainAnimationState* it;
|
||||
s32 partOffset = 3;
|
||||
|
@ -371,6 +371,7 @@ replace_funcs = {
|
||||
"BindNpcInteract" :{0:"NpcIDs"},
|
||||
"BindTakeTurn" :{0:"ActorIDs"},
|
||||
|
||||
"CheckButtonDown" :{0:"Hex", 1:"Bool"},
|
||||
"ContinueSpeech" :{1:"CustomAnim", 2:"CustomAnim", 4:"CustomMsg"},
|
||||
"CopyBuffs" :{0:"ActorIDs", 1:"ActorIDs"},
|
||||
"CopyStatusEffects" :{0:"ActorIDs", 1:"ActorIDs"},
|
||||
@ -389,10 +390,13 @@ replace_funcs = {
|
||||
"EnemyDamageTarget" :{0:"ActorIDs", 1:"HitResults", 2:"DamageTypes", 4:"StatusFlags", 6:"BattleStatusFlags1"},
|
||||
"EnemyTestTarget" :{0:"ActorIDs", 1:"HitResults", 2:"DamageTypes", 3:"StatusFlags", 5:"BattleStatusFlags1"},
|
||||
|
||||
"FallToGoal" :{0:"ActorIDs"},
|
||||
"FindKeyItem" :{0:"ItemIDs"},
|
||||
"FlyPartTo" :{0:"ActorIDs"},
|
||||
"FlyToGoal" :{0:"ActorIDs"},
|
||||
"ForceHomePos" :{0:"ActorIDs"},
|
||||
|
||||
"func_8026DF88" :{0:"ActorIDs"},
|
||||
"func_8026EA7C" :{0:"ActorIDs"},
|
||||
"func_8026EBF8" :{0:"ActorIDs"},
|
||||
"func_8026ED20" :{0:"ActorIDs"},
|
||||
@ -403,6 +407,7 @@ replace_funcs = {
|
||||
"func_802CFE2C" :{0:"NpcIDs"},
|
||||
"func_802D2520" :{0:"PlayerAnims"},
|
||||
|
||||
"GetAnimation" :{0:"ActorIDs", 2:"CustomAnim"},
|
||||
"GetActorFlags" :{0:"ActorIDs", 1:"ActorFlags"},
|
||||
"GetActorHP" :{0:"ActorIDs"},
|
||||
"GetActorPos" :{0:"ActorIDs"},
|
||||
@ -414,12 +419,14 @@ replace_funcs = {
|
||||
"GetEnemyMaxHP" :{0:"ActorIDs"},
|
||||
"GetGoalPos" :{0:"ActorIDs"},
|
||||
"GetHomePos" :{0:"ActorIDs"},
|
||||
"GetIdleGoal" :{0:"ActorIDs"},
|
||||
"GetIndexFromHome" :{0:"ActorIDs"},
|
||||
"GetIndexFromPos" :{0:"ActorIDs"},
|
||||
"GetItemPower" :{0:"ItemIDs"},
|
||||
"GetLastDamage" :{0:"ActorIDs"},
|
||||
"GetLastElement" :{0:"DamageTypes"},
|
||||
"GetLastEvent" :{0:"ActorIDs", 1:"Events"},
|
||||
"GetPartOffset" :{0:"ActorIDs"},
|
||||
"GetPartPos" :{0:"ActorIDs"},
|
||||
"GetPartRotation" :{0:"ActorIDs"},
|
||||
"GetNpcPos" :{0:"NpcIDs"},
|
||||
@ -431,6 +438,7 @@ replace_funcs = {
|
||||
"HPBarToHome" :{0:"ActorIDs"},
|
||||
|
||||
"IdleFlyToGoal" :{0:"ActorIDs"},
|
||||
"IdleJumpToGoal" :{0:"ActorIDs"},
|
||||
"IdleRunToGoal" :{0:"ActorIDs"},
|
||||
"InterpNpcYaw" :{0:"NpcIDs"},
|
||||
|
||||
@ -438,7 +446,7 @@ replace_funcs = {
|
||||
"JumpToGoal" :{0:"ActorIDs", 2:"Bool", 3:"Bool", 4:"Bool"},
|
||||
|
||||
"LandJump" :{0:"ActorIDs"},
|
||||
"LoadActionCommand" :{0:"ActionCommandDmaTable"},
|
||||
"LoadActionCommand" :{0:"ActionCommand"},
|
||||
|
||||
"MakeEntity" :{0:"Hex"},
|
||||
"MakeItemEntity" :{0:"ItemIDs"},
|
||||
@ -470,6 +478,7 @@ replace_funcs = {
|
||||
"SetActorDispOffset" :{0:"ActorIDs"},
|
||||
"SetActorFlagBits" :{0:"ActorIDs", 1:"ActorFlags"},
|
||||
"SetActorIdleSpeed" :{0:"ActorIDs"},
|
||||
"SetActorIdleJumpGravity" :{0:"ActorIDs"},
|
||||
"SetActorJumpGravity" :{0:"ActorIDs"},
|
||||
"SetActorPos" :{0:"ActorIDs"},
|
||||
"SetActorRotation" :{0:"ActorIDs"},
|
||||
@ -497,6 +506,7 @@ replace_funcs = {
|
||||
"SetHomePos" :{0:"ActorIDs"},
|
||||
"SetIdleAnimations" :{0:"ActorIDs"},
|
||||
"SetIdleGoal" :{0:"ActorIDs"},
|
||||
"SetIdleGoalToHome" :{0:"ActorIDs"},
|
||||
"SetJumpAnimations" :{0:"ActorIDs", 2:"PlayerAnims", 3:"PlayerAnims", 4:"PlayerAnims"},
|
||||
"SetMusicTrack" :{1:"SongIDs"},
|
||||
|
||||
@ -756,8 +766,12 @@ class ScriptDisassembler:
|
||||
self.indent -= 1
|
||||
|
||||
if self.prelude:
|
||||
self.prefix_line(f"EvtSource {self.script_name} = {{")
|
||||
self.write_line("};")
|
||||
try:
|
||||
self.prefix_line(f"EvtSource D_{self.script_name - info[0] + info[2]:08X}_{self.script_name:08X} = {{")
|
||||
self.write_line("};")
|
||||
except:
|
||||
self.prefix_line(f"EvtSource {self.script_name} = {{")
|
||||
self.write_line("};")
|
||||
self.done = True
|
||||
elif opcode == 0x02: self.write_line(f"EVT_RETURN")
|
||||
elif opcode == 0x03: self.write_line(f"EVT_LABEL({self.var(argv[0])})")
|
||||
|
@ -736,7 +736,7 @@ def disassemble(bytes, midx, symbol_map={}, comments=True, romstart=0, namespace
|
||||
if var0 == 0 and var1 == 0 and var2 == 0 and var3 == 0:
|
||||
pass
|
||||
else:
|
||||
out += f", {var1}, {var2} {var3}, {var4}"
|
||||
out += f", {var0}, {var1} {var2}, {var3}"
|
||||
|
||||
out += " },\n"
|
||||
|
||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,6 +1,13 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
.section .rodata
|
||||
|
||||
dlabel D_80224920_4EF060
|
||||
.double 0.2, 0.0
|
||||
|
||||
.section .text
|
||||
|
||||
glabel b_area_isk_part_1_ChompChainUpdate
|
||||
/* 4E2C0C 802184CC 27BDFF98 */ addiu $sp, $sp, -0x68
|
||||
/* 4E2C10 802184D0 AFBF0038 */ sw $ra, 0x38($sp)
|
||||
@ -151,7 +158,7 @@ glabel b_area_isk_part_1_ChompChainUpdate
|
||||
/* 4E2E2C 802186EC 4602A081 */ sub.s $f2, $f20, $f2
|
||||
/* 4E2E30 802186F0 4406B000 */ mfc1 $a2, $f22
|
||||
/* 4E2E34 802186F4 44051000 */ mfc1 $a1, $f2
|
||||
/* 4E2E38 802186F8 0C086116 */ jal b_area_isk_part_1_ChompChainUpdateHelperFunc2
|
||||
/* 4E2E38 802186F8 0C086116 */ jal b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc2
|
||||
/* 4E2E3C 802186FC 27A40018 */ addiu $a0, $sp, 0x18
|
||||
/* 4E2E40 80218700 C7A00018 */ lwc1 $f0, 0x18($sp)
|
||||
/* 4E2E44 80218704 3C013FE0 */ lui $at, 0x3fe0
|
||||
@ -210,7 +217,7 @@ glabel b_area_isk_part_1_ChompChainUpdate
|
||||
/* 4E2F04 802187C4 8E050018 */ lw $a1, 0x18($s0)
|
||||
.L802187C8:
|
||||
/* 4E2F08 802187C8 4406B000 */ mfc1 $a2, $f22
|
||||
/* 4E2F0C 802187CC 0C0860F0 */ jal b_area_isk_part_1_ChompChainUpdateHelperFunc
|
||||
/* 4E2F0C 802187CC 0C0860F0 */ jal b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc
|
||||
/* 4E2F10 802187D0 0240202D */ daddu $a0, $s2, $zero
|
||||
/* 4E2F14 802187D4 C6000018 */ lwc1 $f0, 0x18($s0)
|
||||
/* 4E2F18 802187D8 3C014010 */ lui $at, 0x4010
|
||||
|
@ -3444,8 +3444,7 @@ segments:
|
||||
vram: 0x802A1000
|
||||
subsegments:
|
||||
- [0x415D90, c, 415D90]
|
||||
- [0x4200D0, .data, 415D90]
|
||||
- [0x420500]
|
||||
- [0x4200D0]
|
||||
- type: code
|
||||
start: 0x4219F0
|
||||
vram: 0x802A9000
|
||||
@ -3835,36 +3834,56 @@ segments:
|
||||
type: code
|
||||
start: 0x4D01F0
|
||||
vram: 0x80218000
|
||||
subalign: 4
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x4D01F0, c]
|
||||
- [0x4D02B0, c]
|
||||
- [0x4D0310, c]
|
||||
- [0x4D0360, c]
|
||||
- [0x4D03B0, c]
|
||||
- [0x4D0400, data]
|
||||
- [0x4D01F0, c, area]
|
||||
- [0x4D01F0, c, actor/cleft]
|
||||
- [0x4D02B0, c, actor/monty_mole]
|
||||
- [0x4D02B0, c, actor/buzzar]
|
||||
- [0x4D0310, c, actor/whacka]
|
||||
- [0x4D0360, c, stage/iwa_01]
|
||||
- [0x4D03B0, c, stage/iwa_01b]
|
||||
- [0x4D03B0, c, stage/iwa_02]
|
||||
- [0x4D0400]
|
||||
- dir: battle/area_sbk
|
||||
type: code
|
||||
start: 0x4DA5E0
|
||||
vram: 0x80218000
|
||||
subalign: 16 # BSS alignment hack
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x4DA5E0, c]
|
||||
- [0x4DA6B0, c]
|
||||
- [0x4DA860, data]
|
||||
- [0x4DA5E0, c, actor/pokey]
|
||||
- [0x4DA6B0, c, actor/bandit]
|
||||
- [0x4DA6B0, c, stage/sbk_02]
|
||||
- [0x4DA860, c, area]
|
||||
- [0x4DA860]
|
||||
- dir: battle/area_isk_part_1
|
||||
type: code
|
||||
start: 0x4E2740
|
||||
vram: 0x80218000
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x4E2740, c]
|
||||
- [0x4E2810, c]
|
||||
- [0x4E28E0, c]
|
||||
- [0x4E29B0, c]
|
||||
- [0x4E30C0, c]
|
||||
- [0x4E3190, c]
|
||||
- [0x4E3350, data]
|
||||
- [0x4E2740, c, actor/pokey_mummy]
|
||||
- [0x4E2810, c, actor/swooper]
|
||||
- [0x4E28E0, c, actor/buzzy_beetle]
|
||||
- [0x4E29B0, c, actor/stone_chomp]
|
||||
- [0x4E2FF0, c, stage/isk_00]
|
||||
- [0x4E2FF0, c, stage/isk_01]
|
||||
- [0x4E2FF0, c, stage/isk_02]
|
||||
- [0x4E2FF0, c, stage/isk_03]
|
||||
- [0x4E2FF0, c, stage/isk_04]
|
||||
- [0x4E30C0, c, stage/isk_05]
|
||||
- [0x4E3190, c, stage/isk_06]
|
||||
- [0x4E3200, c, stage/isk_07]
|
||||
- [0x4E3200, c, stage/isk_07]
|
||||
- [0x4E3270, c, stage/isk_03b]
|
||||
- [0x4E3270, c, stage/isk_02b]
|
||||
- [0x4E3270, c, stage/isk_02c]
|
||||
- [0x4E3270, c, stage/isk_06b]
|
||||
- [0x4E32E0, c, stage/isk_08]
|
||||
- [0x4E3350, c, area]
|
||||
- [0x4E3350]
|
||||
- dir: battle/area_isk_part_2
|
||||
type: code
|
||||
start: 0x4EF4A0
|
||||
@ -4668,8 +4687,8 @@ segments:
|
||||
vram: 0x802A1000
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x7345A0, c]
|
||||
- [0x734650, data]
|
||||
- [0x7345A0, c, hammer]
|
||||
- [0x734650]
|
||||
- dir: battle/move/spin_smash
|
||||
type: code
|
||||
start: 0x737890
|
||||
@ -4684,16 +4703,16 @@ segments:
|
||||
vram: 0x802A1000
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x73AED0, c]
|
||||
- [0x73AF80, data]
|
||||
- [0x73AED0, c, quake_hammer]
|
||||
- [0x73AF80]
|
||||
- dir: battle/move/jump
|
||||
type: code
|
||||
start: 0x73D860
|
||||
vram: 0x802A1000
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x73D860, c]
|
||||
- [0x73D9A0, data]
|
||||
- [0x73D860, c, jump]
|
||||
- [0x73D9A0]
|
||||
- dir: battle/move/multibounce
|
||||
type: code
|
||||
start: 0x740CC0
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -113,14 +113,6 @@ D_80220754 = 0x80220754;
|
||||
D_80220760 = 0x80220760;
|
||||
D_80220770 = 0x80220770;
|
||||
D_80220780 = 0x80220780;
|
||||
D_80224D60 = 0x80224D60;
|
||||
D_80224D64 = 0x80224D64;
|
||||
D_80224D70 = 0x80224D70;
|
||||
D_80224D74 = 0x80224D74;
|
||||
D_80224D80 = 0x80224D80;
|
||||
D_80224D90 = 0x80224D90;
|
||||
D_80224DA0 = 0x80224DA0;
|
||||
D_80224DB0 = 0x80224DB0;
|
||||
D_8022AD80_4C3F70 = 0x8022AD80;
|
||||
D_8022ADD0 = 0x8022ADD0;
|
||||
D_8022B550 = 0x8022B550;
|
||||
|
Loading…
Reference in New Issue
Block a user