4API_CALLABLE(N(SwooperAI_Main)) {
8 Enemy* enemy = script->owner1.enemy;
12 f32 x, y, z, hitDepth;
25 script->functionTemp[0] = 0;
33 enemy->varTable[1] = y;
40 enemy->
aiFlags &= ~AI_FLAG_SUSPEND;
43 switch (script->functionTemp[0]) {
48 script->functionTemp[1] = 0;
49 script->functionTemp[0] = 1;
52 if (script->functionTemp[1] <= 0) {
56 script->functionTemp[0] = 10;
59 script->functionTemp[1]--;
61 if (script->functionTemp[0] != 10) {
75 y = enemy->varTable[1];
81 script->functionTemp[0] = 11;
98 script->functionTemp[0] = 12;
108 y = enemy->varTable[1];
109 y2 = (y + 10.0) - npc->
pos.
y;
118 npc->
flags &= ~NPC_FLAG_UPSIDE_DOWN;
119 enemy->varTable[0] = 5;
121 script->functionTemp[0] = 13;
143 }
else if (npc->
jumpVel < -2.5) {
151 if (angleDiff < 0.0f) {
163 enemy->varTable[0]--;
164 if (enemy->varTable[0] <= 0) {
165 enemy->varTable[0] = 5;
170 script->functionTemp[0] = 14;
179 script->functionTemp[0] = 15;
183 script->functionTemp[0] = 0;
#define npc_raycast_down_sides
@ AI_FLAG_SKIP_IDLE_ANIM_AFTER_FLEE
s32 evt_get_variable(Evt *script, Bytecode var)
void ai_enemy_play_sound(Npc *npc, s32 arg1, s32 arg2)
f32 dist2D(f32 ax, f32 ay, f32 bx, f32 by)
b32 npc_test_move_simple_with_slipping(s32, f32 *, f32 *, f32 *, f32, f32, f32, f32)
f32 get_clamped_angle_diff(f32, f32)
enum TerritoryShape shape
enum TerritoryShape detectShape
s32 basic_ai_check_player_dist(EnemyDetectVolume *arg0, Enemy *arg1, f32 arg2, f32 arg3, b8 arg4)
Npc * get_npc_unsafe(s32 npcID)
void npc_move_heading(Npc *npc, f32 speed, f32 yaw)
s32 skipPlayerDetectChance
EnemyTerritoryWander wander
EnemyTerritory * territory
PlayerStatus gPlayerStatus