3#include "sprite/npc/BattleGoombario.h"
5#define NAMESPACE A(goombario_clone)
12s32 N(DefaultAnims)[] = {
25s32 N(DefenseTable)[] = {
30s32 N(StatusTable)[] = {
59 .posOffset = { 0, 0, 0 },
60 .targetOffset = { 0, 20 },
62 .idleAnimations = N(DefaultAnims),
63 .defenseTable = N(DefenseTable),
65 .elementImmunityFlags = 0,
66 .projectileTargetOffset = { -1, -9 },
72 .type = ACTOR_TYPE_GHOST_GOOMBARIO,
73 .level = ACTOR_LEVEL_GHOST_GOOMBARIO,
76 .partsData = N(ActorParts),
77 .initScript = &N(EVS_Init),
78 .statusTable = N(StatusTable),
81 .hurricaneChance = 70,
83 .upAndAwayChance = 95,
85 .powerBounceChance = 90,
88 .healthBarOffset = { 0, 0 },
89 .statusIconOffset = { -10, 20 },
90 .statusTextOffset = { 10, 20 },
117 ExecWait(
A(EVS_Duplighost_OnHitElectric))
213#include "world/common/todo/UnkFunc62.inc.c"
216EvtScript N(EVS_HeadbonkFollowthrough) = {
218 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
227 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Fall)
244 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_PreHeadbonk)
249 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
253 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_PreHeadbonk)
257 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
261 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_PreHeadbonk)
265 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
269 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Run)
271 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
283 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Run)
286 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Idle)
325 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_PreHeadbonk)
330 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk)
334 Call(SetJumpAnimations,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk)
343 Call(SetJumpAnimations,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk)
344 Call(N(ActorJumpToPos))
353 ExecWait(N(EVS_HeadbonkFollowthrough))
395 Call(SetJumpAnimations,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk)
410 Call(SetJumpAnimations,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk)
423 Call(SetAnimation,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk)
435 Call(SetJumpAnimations,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk, ANIM_BattleGoombario_Headbonk)
463 ExecWait(N(EVS_HeadbonkFollowthrough))
472API_CALLABLE(N(CalculateTattleCamBoomLength)) {
477 script->varTable[1] += targetActor->
size.
y / 2;
478 script->varTable[1] += targetActor->
size.
y / 4;
480 script->varTable[1] -= targetActor->
size.
y / 2;
481 script->varTable[1] -= targetActor->
size.
y / 4;
484 script->varTable[3] = 126 + MAX(targetActor->
size.
x, targetActor->
size.
y);
488API_CALLABLE(N(OpenTattleWindow)) {
489 Bytecode* args = script->ptrReadPos;
491 evt_set_variable(script, *args++, (s32) fx_tattle_window(0, 106.0f, 144.0f, 0, 1.0f, 0));
495API_CALLABLE(N(HideTattleWindow)) {
496 Bytecode* args = script->ptrReadPos;
503API_CALLABLE(N(CloseTattleWindow)) {
504 Bytecode* args = script->ptrReadPos;
525 Call(EnableBattleStatusBar, FALSE)
534 Call(N(CalculateTattleCamBoomLength))
542 Call(ActorSpeak, MSG_EnemyTattle_Mario,
ACTOR_SELF, PRT_MAIN, ANIM_BattleGoombario_Talk, ANIM_BattleGoombario_Idle)
547 Call(EnableBattleStatusBar, TRUE)
struct TattleWindowFXData * tattleWindow
@ FX_INSTANCE_FLAG_DISMISS
@ BS_FLAGS1_TRIGGER_EVENTS
@ BS_FLAGS1_INCLUDE_POWER_UPS
@ STATUS_TURN_MOD_DEFAULT
@ STATUS_TURN_MOD_PARALYZE
@ SOUND_GOOMBARIO_HEADBONK
@ SOUND_TATTLE_WINDOW_OPEN
@ ACTOR_FLAG_UPSIDE_DOWN
HP bar offset below actor (e.g. Swooper when upside-down).
@ ACTOR_PART_FLAG_PRIMARY_TARGET
@ DAMAGE_TYPE_TRIGGER_LUCKY
s32 evt_get_variable(Evt *script, Bytecode var)
s32 evt_set_variable(Evt *script, Bytecode var, s32 value)
Actor * get_actor(s32 actorID)
EvtScript EVS_Enemy_ScareAway
EvtScript EVS_Enemy_Death
EvtScript EVS_Enemy_SpinSmashHit
EvtScript EVS_Enemy_AirLift
EvtScript EVS_Enemy_BlowAway
EvtScript EVS_Enemy_Recover
EvtScript EVS_Enemy_BurnHit
EvtScript EVS_Enemy_NoDamageHit
ApiStatus SetCamEnabled(Evt *script, b32 isInitialCall)
ApiStatus SetCamViewport(Evt *script, b32 isInitialCall)
ApiStatus SetCamLookTarget(Evt *script, b32 isInitialCall)
ApiStatus RandInt(Evt *script, b32 isInitialCall)
ApiStatus ShakeCam(Evt *script, b32 isInitialCall)
ApiStatus SetNoInterpCamParams(Evt *script, b32 isInitialCall)
ApiStatus SetCamNoDraw(Evt *script, b32 isInitialCall)
ApiStatus SetCamPerspective(Evt *script, b32 isInitialCall)
#define Else
Marks the end of an if statement and the start of the else block.
#define Switch(LVAR)
Marks the start of a switch statement.
#define Ref(sym)
Address/pointer constant.
#define DivF(VAR, FLOAT_VALUE)
#define Set(VAR, INT_VALUE)
Sets the given variable to a given value casted to an integer.
#define AddF(VAR, FLOAT_VALUE)
#define CaseEq(RVAR)
Marks the start of a switch case that executes only if LVAR == RVAR. It also marks the end of any pre...
#define EndChildThread
Marks the end of a child thread block.
#define Sub(VAR, INT_VALUE)
#define End
Signals the end of EVT script data. A script missing this will likely crash on load.
#define Add(VAR, INT_VALUE)
#define EndLoop
Marks the end of a loop.
#define EndCaseGroup
Marks the end of a switch case group (CaseOrEq and/or CaseAndEq), stopping fallthrough.
#define Goto(LABEL_ID)
Moves execution to the given label.
#define NPC_DISPOSE_POS_Y
#define IfGt(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR <= RVAR.
#define IfLt(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR < RVAR.
#define Label(LABEL_ID)
Marks this point in the script as a Goto target.
#define CaseOrEq(RVAR)
Marks the start of a switch case that executes only if LVAR == RVAR.
#define EndIf
Marks the end of an if statement or an else block.
#define CaseDefault
Marks the start of a switch case that executes unconditionally. It also marks the end of any previous...
#define ExecWait(EVT_SOURCE)
Launches a new child thread.
#define Thread
Marks the start of a thread block.
#define EndThread
Marks the end of a thread block.
#define SetF(VAR, FLOAT_VALUE)
Sets the given variable to a given value, but supports Floats.
#define IfFlag(LVAR, RVAR)
Marks the beginning of an if statement that only executes if the RVAR flag is set on LVAR,...
#define Wait(NUM_FRAMES)
Blocks for the given number of frames.
#define EndSwitch
Marks the end of a switch statement and any case.
#define IfEq(LVAR, RVAR)
Marks the beginning of an if statement that only executes if LVAR == RVAR.
#define Call(FUNC, ARGS...)
Calls a given C EVT API function with any number of arguments.
#define ChildThread
Marks the start of a child thread block.
#define Loop(TIMES)
Marks the beginning of a loop.
#define SetConst(VAR, CONST)
Sets the given variable to a given value, skipping the evt_get_variable call.
#define Return
Kills the current EVT thread.
#define ACTOR_BY_POS(_name, _pos, _priority, args...)