mirror of
https://github.com/pmret/papermario.git
synced 2024-11-08 12:02:30 +01:00
Match more overworld partner functions (#541)
* decomp watt overworld functions * fix struct that was wrongly changed * run coverage.py * requested changes for watt.c and decomp a function from sbk_02 * run coverage.py * more style changes * decomp all functions in 92A2B0.c * run coverage.py * use map_var instead of hex constant, other style changes * pull sbk_02.h changes * ...actually merge master correctly * decomp most functions in nok_04 * decomp most of 9EDBF0.C, fix warnings in UnkFunc41.inc.c and warnings/decomp in lakilester.c * run coverage.py * code review changes + few extra functions * decomp lakilester functions and fix style in other files * decomp more laki overworld functions * add close match for func_802BDDD8_321928 * requested changes * more requested style changes * style changes * last of review changes * another small style fix * ...accidentally deleted the f on a float immediate * decomp world sushie/watt files * run coverage.py * small style fixes * fix 2 warnings in watt.c * decomp kooper world functions * requested style changes * couple more style changes * decomp kooper world functions * last style changes * decomp more kooper world functions * match world kooper file except 2 non_equivalent * non matching of last world bow function * migrate data.s file to bombette.c, also decomp various overoworld partner functions * match more overworld partner functions * style changes * update variable names * some requested changes done * add enums and other cleanup to overworld partner files * run coverage.py * add a space to watt file * remove raw pointers from partner files plus other requested changes * remove goompa raw pointer Co-authored-by: root <root@DESKTOP-HK751F2.localdomain> Co-authored-by: Rainchus <Rainchus@github.com>
This commit is contained in:
parent
cf8f817af2
commit
d9c72e432b
@ -2254,7 +2254,7 @@ typedef struct PopupMessage {
|
||||
typedef struct unkPartnerStruct {
|
||||
/* 0x000 */ s32 unk_00;
|
||||
/* 0x004 */ s32 unk_04;
|
||||
/* 0x008 */ s32 unk_08;
|
||||
/* 0x008 */ s32 flags;
|
||||
/* 0x00c */ f32 unk_0C;
|
||||
/* 0x010 */ f32 unk_10;
|
||||
/* 0x014 */ f32 unk_14;
|
||||
|
@ -1618,8 +1618,8 @@ enum NpcFlags {
|
||||
NPC_FLAG_ENABLE_HIT_SCRIPT = 0x00000008,
|
||||
NPC_FLAG_HAS_SHADOW = 0x00000010, ///< Set by default and by enable_npc_shadow
|
||||
NPC_FLAG_NO_AI = 0x00000020, ///< Disable movement AI and collision (idle animation plays)
|
||||
NPC_FLAG_80 = 0x00000080, // TODO
|
||||
NPC_FLAG_40 = 0x00000040,
|
||||
NPC_FLAG_80 = 0x00000080, // TODO
|
||||
NPC_FLAG_100 = 0x00000100, // TODO
|
||||
NPC_FLAG_GRAVITY = 0x00000200, ///< Enables gravity. Does nothing if NPC_FLAG_NO_Y_MOVEMENT is set.
|
||||
NPC_FLAG_LOCK_ANIMS = 0x00000400, ///< Do not allow scripts to change animation
|
||||
@ -1650,9 +1650,18 @@ enum NpcFlags {
|
||||
enum PlayerStatusFlags {
|
||||
PLAYER_STATUS_FLAGS_JUMPING = 0x00000002,
|
||||
PLAYER_STATUS_FLAGS_FALLING = 0x00000004,
|
||||
PLAYER_STATUS_FLAGS_100 = 0x00000100,
|
||||
PLAYER_STATUS_FLAGS_200 = 0x00000200,
|
||||
PLAYER_STATUS_FLAGS_400 = 0x00000400,
|
||||
PLAYER_STATUS_FLAGS_800 = 0x00000800,
|
||||
PLAYER_STATUS_FLAGS_1000 = 0x00001000,
|
||||
PLAYER_STATUS_FLAGS_INPUT_DISABLED = 0x00002000,
|
||||
PLAYER_STATUS_FLAGS_4000 = 0x00004000,
|
||||
PLAYER_STATUS_FLAGS_8000 = 0x00008000,
|
||||
PLAYER_STATUS_FLAGS_40000 = 0x00040000,
|
||||
PLAYER_STATUS_FLAGS_HAS_CONVERSATION_NPC = 0x02000000,
|
||||
PLAYER_STATUS_FLAGS_CAMERA_DOESNT_FOLLOW = 0x04000000,
|
||||
PLAYER_STATUS_FLAGS_10000000 = 0x10000000,
|
||||
PLAYER_STATUS_FLAGS_ACTION_STATE_CHANGED = 0x80000000,
|
||||
};
|
||||
|
||||
@ -2210,6 +2219,7 @@ enum DebuffTypes {
|
||||
enum GlobalOverrides {
|
||||
GLOBAL_OVERRIDES_DISABLE_RENDER_WORLD = 0x00000002,
|
||||
GLOBAL_OVERRIDES_ENABLE_TRANSITION_STENCIL = 0x00000020,
|
||||
GLOBAL_OVERRIDES_40 = 0x00000040,
|
||||
GLOBAL_OVERRIDES_DISABLE_BATTLES = 0x00000100,
|
||||
GLOBAL_OVERRIDES_WINDOWS_IN_FRONT_OF_CURTAINS = 0x00010000,
|
||||
GLOBAL_OVERRIDES_DISABLE_MENUS = 0x00040000,
|
||||
|
@ -380,6 +380,12 @@ extern s32 D_8029FBD0;
|
||||
extern s32 D_800F7BE8[];
|
||||
extern s32 D_800F7BBC[];
|
||||
|
||||
//partner temporary space
|
||||
extern unkPartnerStruct D_802BE940;
|
||||
extern unkPartnerStruct D_802BDF40;
|
||||
extern unkPartnerStruct D_802BD600;
|
||||
|
||||
//various
|
||||
extern s32 D_802C05CC;
|
||||
|
||||
extern s16 gCurrentCamID;
|
||||
|
@ -10,7 +10,6 @@ static char* N(exit_str_1) = "\0\0\0\0";
|
||||
static char* N(exit_str_2) = "sam_11";
|
||||
static char* N(exit_str_3) = "flo_19";
|
||||
|
||||
//INCLUDE_ASM(s32, "EB9D90", func_80240F40_EB9D90);
|
||||
ApiStatus func_80240F40_EB9D90(Evt* script, s32 isInitialCall) {
|
||||
Bytecode* args = script->ptrReadPos;
|
||||
s32 var1 = *args++;
|
||||
|
@ -1,64 +1,120 @@
|
||||
#include "common.h"
|
||||
#include "../src/world/partners.h"
|
||||
|
||||
extern s32 D_802BE934;
|
||||
extern f64 D_802BE900_319650;
|
||||
extern s32 D_802BE92C;
|
||||
extern s32 D_802BE928;
|
||||
extern s32 D_802BE924;
|
||||
extern s32 D_802BE920;
|
||||
extern unkPartnerStruct* D_802BE89C_3195EC;
|
||||
|
||||
extern struct unkPartnerStruct* D_802BE89C_3195EC;
|
||||
ApiStatus func_802BD338_318088(Evt* evt, s32 arg1);
|
||||
ApiStatus func_802BD758_3184A8(Evt* evt, s32 isInitialCall);
|
||||
ApiStatus func_802BE4E8_319238(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802BD300_318050(Evt* script, s32 isInitialCall);
|
||||
void entity_interacts_with_current_partner(s32 arg0);
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BD100_317E50);
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BD2D8_318028);
|
||||
|
||||
ApiStatus func_802BD300_318050(Evt* script, s32 isInitialCall) {
|
||||
Npc* unk = script->owner2.npc; // todo what is this
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(unk);
|
||||
void func_802BD100_317E50(Npc* npc) {
|
||||
f32 sp20, sp24, sp28;
|
||||
f32 phi_f20 = 0.0f;
|
||||
|
||||
while (phi_f20 < 360.0f) {
|
||||
sp20 = npc->pos.x;
|
||||
sp24 = npc->pos.y;
|
||||
sp28 = npc->pos.z;
|
||||
if (npc_test_move_taller_with_slipping(0x100000, &sp20, &sp24, &sp28, 30.0f, clamp_angle(npc->yaw + phi_f20),
|
||||
npc->collisionHeight, npc->collisionRadius) != 0) {
|
||||
break;
|
||||
} else {
|
||||
phi_f20 += 45.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if (phi_f20 >= 360.0f) {
|
||||
phi_f20 = 0.0f;
|
||||
|
||||
while (phi_f20 < 360.0f) {
|
||||
sp20 = npc->pos.x;
|
||||
sp24 = npc->pos.y;
|
||||
sp28 = npc->pos.z;
|
||||
if (npc_test_move_taller_with_slipping(0x40000, &sp20, &sp24, &sp28, 30.0f, clamp_angle(npc->yaw + phi_f20),
|
||||
npc->collisionHeight, npc->collisionRadius) != 0) {
|
||||
break;
|
||||
} else {
|
||||
phi_f20 += 45.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if (!(phi_f20 >= 360.0f)) {
|
||||
if (D_8010C978 >= 0 && (D_8010C978 & 0x4000) != 0) {
|
||||
entity_interacts_with_current_partner(D_8010C978 & ~0x4000);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (D_8010C978 >= 0 && (D_8010C978 & 0x4000) != 0) {
|
||||
entity_interacts_with_current_partner(D_8010C978 & ~0x4000);
|
||||
}
|
||||
}
|
||||
return partner_get_out(unk) != 0;
|
||||
}
|
||||
|
||||
s32 func_802BD338_318088(Evt* evt, s32 arg1) {
|
||||
void func_802BD2D8_318028(Npc* bombette) {
|
||||
bombette->collisionHeight = 28;
|
||||
bombette->collisionRadius = 24;
|
||||
D_802BE928 = 0;
|
||||
D_802BE924 = 0;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD300_318050(Evt* script, s32 isInitialCall) {
|
||||
Npc* bombette = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(bombette);
|
||||
}
|
||||
|
||||
return partner_get_out(bombette) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD338_318088(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* npc;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
Npc* bombette = script->owner2.npc;
|
||||
f32 sp10, sp14, tempY;
|
||||
Entity* entity;
|
||||
|
||||
npc = evt->owner2.npc;
|
||||
if (arg1 != 0) {
|
||||
partner_walking_enable(npc, 1);
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(bombette, 1);
|
||||
mem_clear(D_802BE89C_3195EC, sizeof(*D_802BE89C_3195EC));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[3]++;
|
||||
npc->flags |= 0x10000;
|
||||
bombette->flags |= NPC_FLAG_DIRTY_SHADOW;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
return 0;
|
||||
partner_walking_update_player_tracking(bombette);
|
||||
partner_walking_update_motion(bombette);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BE89C_3195EC->unk_04) {
|
||||
case 0:
|
||||
D_802BE89C_3195EC->unk_04 = 1;
|
||||
D_802BE89C_3195EC->unk_08 = npc->flags;
|
||||
D_802BE89C_3195EC->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BE89C_3195EC->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BE89C_3195EC->flags = bombette->flags;
|
||||
D_802BE89C_3195EC->unk_0C = fabsf(dist2D(bombette->pos.x, bombette->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BE89C_3195EC->unk_10 = atan2(entity->position.x, entity->position.z,
|
||||
bombette->pos.x, bombette->pos.z);
|
||||
D_802BE89C_3195EC->unk_14 = 6.0f;
|
||||
D_802BE89C_3195EC->unk_18 = 50.0f;
|
||||
D_802BE89C_3195EC->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BE89C_3195EC->unk_00 = 120;
|
||||
bombette->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
bombette->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BE89C_3195EC->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BE89C_3195EC->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BE89C_3195EC->unk_0C);
|
||||
|
||||
bombette->pos.x = entity->position.x + (sp10 * D_802BE89C_3195EC->unk_0C);
|
||||
bombette->pos.z = entity->position.z - (sp14 * D_802BE89C_3195EC->unk_0C);
|
||||
D_802BE89C_3195EC->unk_10 = clamp_angle(D_802BE89C_3195EC->unk_10 - D_802BE89C_3195EC->unk_14);
|
||||
|
||||
if (D_802BE89C_3195EC->unk_0C > 20.0f) {
|
||||
D_802BE89C_3195EC->unk_0C--;
|
||||
} else if (D_802BE89C_3195EC->unk_0C < 19.0f) {
|
||||
@ -66,16 +122,16 @@ s32 func_802BD338_318088(Evt* evt, s32 arg1) {
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BE89C_3195EC->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
|
||||
D_802BE89C_3195EC->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BE89C_3195EC->unk_18 > 150.0f) {
|
||||
D_802BE89C_3195EC->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BE89C_3195EC->unk_10);
|
||||
D_802BE89C_3195EC->unk_14 += D_802BE900_319650;
|
||||
bombette->pos.y += tempY;
|
||||
bombette->renderYaw = clamp_angle(360.0f - D_802BE89C_3195EC->unk_10);
|
||||
D_802BE89C_3195EC->unk_14 += 0.8;
|
||||
|
||||
if (D_802BE89C_3195EC->unk_14 > 40.0f) {
|
||||
D_802BE89C_3195EC->unk_14 = 40.0f;
|
||||
}
|
||||
@ -85,13 +141,13 @@ s32 func_802BD338_318088(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BE89C_3195EC->unk_08;
|
||||
bombette->flags = D_802BE89C_3195EC->flags;
|
||||
D_802BE89C_3195EC->unk_00 = 0x1E;
|
||||
D_802BE89C_3195EC->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
partner_walking_update_player_tracking(bombette);
|
||||
partner_walking_update_motion(bombette);
|
||||
|
||||
if (--D_802BE89C_3195EC->unk_00 == 0) {
|
||||
D_802BE89C_3195EC->unk_04 = 0;
|
||||
@ -99,10 +155,17 @@ s32 func_802BD338_318088(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BD6DC_31842C);
|
||||
void func_802BD6DC_31842C(Npc* npc) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
npc->flags = D_802BE89C_3195EC->flags;
|
||||
D_802BE89C_3195EC->unk_04 = 0;
|
||||
partner_clear_player_tracking(npc);
|
||||
}
|
||||
}
|
||||
|
||||
s32 func_802BD720_318470(void) {
|
||||
if (gPartnerActionStatus.actionState.b[0] != 0) {
|
||||
@ -119,14 +182,133 @@ s32 func_802BD748(void) {
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BD758_3184A8);
|
||||
|
||||
ApiStatus func_802BE4E8_319238(Evt* script, s32 isInitialCall) {
|
||||
s32 unk = script->owner2.npc; // todo what is this
|
||||
Npc* bombette = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(unk);
|
||||
partner_init_put_away(bombette);
|
||||
}
|
||||
return partner_put_away(unk) != 0;
|
||||
|
||||
return partner_put_away(bombette) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BE520_319270);
|
||||
s32 func_802BE520_319270(Npc* bombette, Npc* enemy) {
|
||||
f32 adjustedDistanceX, adjustedDistanceY, adjustedDistanceZ;
|
||||
f32 temp_f6, temp_f20, npcZPos, bombetteZPos, npcXPos, bombetteXPos;
|
||||
s32 slippingResult;
|
||||
f32 distance;
|
||||
s32 ret;
|
||||
f32 temp2;
|
||||
f32 height;
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/bombette", func_802BE6E8_319438);
|
||||
if (D_802BE928 == 0) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
npcXPos = enemy->pos.x;
|
||||
bombetteXPos = bombette->pos.x;
|
||||
adjustedDistanceX = enemy->pos.x - bombette->pos.x;
|
||||
|
||||
adjustedDistanceY = (enemy->pos.y + (f32)(enemy->collisionHeight * 0.5) - bombette->pos.y);
|
||||
|
||||
npcZPos = enemy->pos.z;
|
||||
bombetteZPos = bombette->pos.z;
|
||||
adjustedDistanceZ = npcZPos - bombetteZPos;
|
||||
|
||||
temp_f6 = enemy->collisionRadius * 0.55;
|
||||
height = 35.0f;
|
||||
temp2 = sqrtf(SQ(adjustedDistanceX) + SQ(adjustedDistanceY) + SQ(adjustedDistanceZ));
|
||||
ret = FALSE;
|
||||
|
||||
if (temp2 < (temp_f6 + height)) {
|
||||
ret = TRUE;
|
||||
}
|
||||
|
||||
temp_f20 = atan2(npcXPos, npcZPos, bombetteXPos, bombetteZPos);
|
||||
distance = dist2D(npcXPos, npcZPos, bombetteXPos, bombetteZPos);
|
||||
|
||||
adjustedDistanceX = bombette->pos.x;
|
||||
adjustedDistanceY = bombette->pos.y;
|
||||
adjustedDistanceZ = bombette->pos.z;
|
||||
|
||||
slippingResult = npc_test_move_taller_with_slipping(0, &adjustedDistanceX, &adjustedDistanceY, &adjustedDistanceZ,
|
||||
distance, temp_f20, height, 2.0f);
|
||||
|
||||
if (slippingResult) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
void func_802BE6E8_319438(Npc* bombette) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* bombetteActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (bombetteActionStatus->actionState.b[0] != 0) {
|
||||
if (D_802BE92C) {
|
||||
enable_player_input();
|
||||
}
|
||||
|
||||
D_802BE928 = 0;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_JUMPING;
|
||||
bombette->jumpVelocity = 0.0f;
|
||||
bombette->flags &= ~NPC_FLAG_NO_Y_MOVEMENT;
|
||||
|
||||
set_action_state(ACTION_STATE_IDLE);
|
||||
partner_clear_player_tracking(bombette);
|
||||
|
||||
bombetteActionStatus->actionState.b[0] = 0;
|
||||
bombetteActionStatus->actionState.b[3] = 0;
|
||||
|
||||
bombette->pos.x = playerStatus->position.x;
|
||||
bombette->pos.y = playerStatus->position.y;
|
||||
bombette->pos.z = playerStatus->position.z;
|
||||
|
||||
if (D_802BE920 == 0) {
|
||||
add_vec2D_polar(&bombette->pos.x, &bombette->pos.z,
|
||||
playerStatus->colliderDiameter / 4, clamp_angle(playerStatus->targetYaw + 90.0f));
|
||||
} else {
|
||||
add_vec2D_polar(&bombette->pos.x, &bombette->pos.z,
|
||||
playerStatus->colliderDiameter / 4, clamp_angle(playerStatus->targetYaw - 90.0f));
|
||||
}
|
||||
|
||||
bombette->jumpVelocity = 0.0f;
|
||||
bombette->pos.y = playerStatus->position.y;
|
||||
bombette->rotation.x = 0.0f;
|
||||
bombette->rotation.z = 0.0f;
|
||||
bombette->currentAnim.w = 0x30003;
|
||||
partner_clear_player_tracking(bombette);
|
||||
disable_npc_blur(bombette);
|
||||
|
||||
if (D_802BE924) {
|
||||
D_802BE924 = 0;
|
||||
sfx_stop_sound(0x80000000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
EvtSource bombetteGetOut = {
|
||||
EVT_CALL(func_802BD300_318050)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
unkPartnerStruct* D_802BE89C_3195EC = &D_802BE940;
|
||||
|
||||
EvtSource bombetteUpdate = {
|
||||
EVT_CALL(func_802BD338_318088)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource bombetteUseAbility = {
|
||||
EVT_CALL(func_802BD758_3184A8)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
||||
EvtSource bombettePutAway = {
|
||||
EVT_CALL(func_802BE4E8_319238)
|
||||
EVT_RETURN
|
||||
EVT_END
|
||||
};
|
||||
|
@ -13,58 +13,60 @@ extern struct unkPartnerStruct* D_802BDFFC_32494C;
|
||||
void func_802BDDF0_324740(Npc* partner);
|
||||
s32 func_802BD540_323E90(void);
|
||||
|
||||
void func_802BD100_323A50(Npc* partner) {
|
||||
partner->collisionHeight = 26;
|
||||
partner->collisionRadius = 24;
|
||||
partner->renderMode = RENDER_MODE_SURFACE_XLU_LAYER1;
|
||||
void func_802BD100_323A50(Npc* bow) {
|
||||
bow->collisionHeight = 26;
|
||||
bow->collisionRadius = 24;
|
||||
bow->renderMode = RENDER_MODE_SURFACE_XLU_LAYER1;
|
||||
D_802BE0C4 = FALSE;
|
||||
D_802BE0C0 = FALSE;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD130_323A80(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* bow = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(owner);
|
||||
partner_init_get_out(bow);
|
||||
}
|
||||
return partner_get_out(owner) != 0;
|
||||
|
||||
return partner_get_out(bow) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD168_323AB8(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* npc = script->owner2.npc;
|
||||
Npc* bow = script->owner2.npc;
|
||||
Entity* entity;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
f32 sp10, sp14, tempY;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_flying_enable(npc, 1);
|
||||
partner_flying_enable(bow, 1);
|
||||
mem_clear(D_802BDFFC_32494C, sizeof(*D_802BDFFC_32494C));
|
||||
D_8010C954 = 0;
|
||||
D_8010C954 = NULL;
|
||||
}
|
||||
|
||||
entity = D_8010C954;
|
||||
playerData->unk_2F4[9]++;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(bow);
|
||||
partner_flying_update_motion(bow);
|
||||
return 0;
|
||||
}
|
||||
|
||||
switch (D_802BDFFC_32494C->unk_04){
|
||||
case 0:
|
||||
D_802BDFFC_32494C->unk_04 = 1;
|
||||
D_802BDFFC_32494C->unk_08 = npc->flags;
|
||||
D_802BDFFC_32494C->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BDFFC_32494C->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BDFFC_32494C->flags = bow->flags;
|
||||
D_802BDFFC_32494C->unk_0C = fabsf(dist2D(bow->pos.x, bow->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BDFFC_32494C->unk_10 = atan2(entity->position.x, entity->position.z, bow->pos.x, bow->pos.z);
|
||||
D_802BDFFC_32494C->unk_14 = 6.0f;
|
||||
D_802BDFFC_32494C->unk_18 = 50.0f;
|
||||
D_802BDFFC_32494C->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BDFFC_32494C->unk_00 = 120;
|
||||
bow->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
bow->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BDFFC_32494C->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BDFFC_32494C->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BDFFC_32494C->unk_0C);
|
||||
bow->pos.x = entity->position.x + (sp10 * D_802BDFFC_32494C->unk_0C);
|
||||
bow->pos.z = entity->position.z - (sp14 * D_802BDFFC_32494C->unk_0C);
|
||||
D_802BDFFC_32494C->unk_10 = clamp_angle(D_802BDFFC_32494C->unk_10 - D_802BDFFC_32494C->unk_14);
|
||||
if (D_802BDFFC_32494C->unk_0C > 20.0f) {
|
||||
D_802BDFFC_32494C->unk_0C -= 1.0f;
|
||||
@ -74,12 +76,15 @@ ApiStatus func_802BD168_323AB8(Evt* script, s32 isInitialCall) {
|
||||
|
||||
tempY = sin_rad((D_802BDFFC_32494C->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
D_802BDFFC_32494C->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BDFFC_32494C->unk_18 > 150.0f) {
|
||||
D_802BDFFC_32494C->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BDFFC_32494C->unk_10);
|
||||
|
||||
bow->pos.y += tempY;
|
||||
bow->renderYaw = clamp_angle(360.0f - D_802BDFFC_32494C->unk_10);
|
||||
D_802BDFFC_32494C->unk_14 += 0.8;
|
||||
|
||||
if (D_802BDFFC_32494C->unk_14 > 40.0f) {
|
||||
D_802BDFFC_32494C->unk_14 = 40.0f;
|
||||
}
|
||||
@ -88,13 +93,14 @@ ApiStatus func_802BD168_323AB8(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BDFFC_32494C->unk_08;
|
||||
D_802BDFFC_32494C->unk_00 = 0x1E;
|
||||
bow->flags = D_802BDFFC_32494C->flags;
|
||||
D_802BDFFC_32494C->unk_00 = 30;
|
||||
D_802BDFFC_32494C->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(bow);
|
||||
partner_flying_update_motion(bow);
|
||||
|
||||
if (--D_802BDFFC_32494C->unk_00 == 0) {
|
||||
D_802BDFFC_32494C->unk_04 = 0;
|
||||
D_8010C954 = 0;
|
||||
@ -104,30 +110,56 @@ ApiStatus func_802BD168_323AB8(Evt* script, s32 isInitialCall) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
void func_802BD4FC_323E4C(Npc* partner) {
|
||||
if (D_8010C954 != 0) {
|
||||
D_8010C954 = 0;
|
||||
partner->flags = D_802BDFFC_32494C->unk_08;
|
||||
void func_802BD4FC_323E4C(Npc* bow) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
bow->flags = D_802BDFFC_32494C->flags;
|
||||
D_802BDFFC_32494C->unk_04 = 0;
|
||||
partner_clear_player_tracking(partner);
|
||||
partner_clear_player_tracking(bow);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef NON_MATCHING
|
||||
s32 func_802BD540_323E90(void) {
|
||||
f32 sp20, sp24, sp28;
|
||||
f32 temp_f12, temp_f22;
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
f32 tempX, tempZ;
|
||||
|
||||
if (gGameStatusPtr->areaID != AREA_OMO) {
|
||||
return -1;
|
||||
} else {
|
||||
if (gPlayerStatus.extraVelocity.x != 0.0f || gPlayerStatus.extraVelocity.z != 0.0f) {
|
||||
temp_f22 = atan2(0.0f, 0.0f, gPlayerStatus.extraVelocity.x, gPlayerStatus.extraVelocity.z);
|
||||
temp_f12 = temp_f22 + 180.0f;
|
||||
sp20 = gPlayerStatus.position.x;
|
||||
sp24 = gPlayerStatus.position.z;
|
||||
sp28 = gPlayerStatus.position.y + (gPlayerStatus.colliderHeight * 0.5f);
|
||||
add_vec2D_polar(&sp20, &sp24, gPlayerStatus.colliderDiameter * 0.5f, clamp_angle(temp_f12));
|
||||
return player_test_lateral_overlap(0, &gPlayerStatus, &sp20, &sp28, &sp24,
|
||||
gPlayerStatus.colliderDiameter, temp_f22);
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
#else
|
||||
INCLUDE_ASM(s32, "world/partner/bow", func_802BD540_323E90);
|
||||
#endif
|
||||
|
||||
ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
CollisionStatus* collisionStatus = &gCollisionStatus;
|
||||
Npc* npc = script->owner2.npc;
|
||||
Npc* bow = script->owner2.npc;
|
||||
f32 distance;
|
||||
|
||||
if (isInitialCall) {
|
||||
func_802BD4FC_323E4C(npc);
|
||||
if (!(playerStatus->animFlags & 0x100000)) {
|
||||
func_802BD4FC_323E4C(bow);
|
||||
if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) {
|
||||
if (func_800EA52C(9) != 0) {
|
||||
if (playerStatus->animFlags & 0x200000) {
|
||||
playerStatus->animFlags &= ~0x200000;
|
||||
if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_200000) {
|
||||
playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_200000;
|
||||
script->functionTemp[2] = disable_player_input();
|
||||
D_802BE0C4 = TRUE;
|
||||
script->functionTemp[0] = 20;
|
||||
@ -144,10 +176,11 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
|
||||
switch (script->functionTemp[0]) {
|
||||
case 40:
|
||||
if (playerStatus->statusMenuCounterinputEnabledCounter != 0) {
|
||||
if (playerStatus->statusMenuCounterinputEnabledCounter) {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
playerStatus->flags |= 0x100;
|
||||
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_100;
|
||||
script->functionTemp[1] = 3;
|
||||
script->functionTemp[2] = disable_player_input();
|
||||
D_802BE0C4 = TRUE;
|
||||
@ -160,7 +193,7 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
|
||||
enable_player_input();
|
||||
D_802BE0C4 = FALSE;
|
||||
playerStatus->flags &= ~0x100;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
script->functionTemp[1]--;
|
||||
@ -170,7 +203,7 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
enable_player_input();
|
||||
D_802BE0C4 = FALSE;
|
||||
}
|
||||
playerStatus->flags &= ~0x100;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
script->functionTemp[0] = 20;
|
||||
@ -180,8 +213,8 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
|
||||
switch (script->functionTemp[0]) {
|
||||
case 20:
|
||||
if (playerStatus->flags & 0x800) {
|
||||
playerStatus->flags &= ~0x100;
|
||||
if (playerStatus->flags & PLAYER_STATUS_FLAGS_800) {
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
if (D_802BE0C4) {
|
||||
enable_player_input();
|
||||
D_802BE0C4 = FALSE;
|
||||
@ -193,79 +226,85 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
D_802BE0C0 = TRUE;
|
||||
npc->flags &= ~0xA00;
|
||||
bow->flags &= ~(NPC_FLAG_NO_Y_MOVEMENT | NPC_FLAG_GRAVITY);
|
||||
partnerActionStatus->actionState.b[0] = 1;
|
||||
partnerActionStatus->actionState.b[3] = 9;
|
||||
playerStatus->flags |= 0x8000;
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_8000;
|
||||
func_800EF4E0();
|
||||
npc->moveToPos.x = playerStatus->position.x;
|
||||
npc->moveToPos.y = playerStatus->position.y + (playerStatus->colliderHeight * 0.5f);
|
||||
npc->moveToPos.z = playerStatus->position.z;
|
||||
npc->currentAnim.w = 0x50002;
|
||||
npc->yaw = playerStatus->targetYaw;
|
||||
add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z, -2.0f, gCameras[gCurrentCameraID].currentYaw);
|
||||
add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z,
|
||||
playerStatus->colliderDiameter * 0.5f, npc->yaw);
|
||||
npc->duration = 5;
|
||||
npc->yaw = atan2(npc->pos.x, npc->pos.z, playerStatus->position.x, playerStatus->position.z);
|
||||
bow->moveToPos.x = playerStatus->position.x;
|
||||
bow->moveToPos.y = playerStatus->position.y + (playerStatus->colliderHeight * 0.5f);
|
||||
bow->moveToPos.z = playerStatus->position.z;
|
||||
bow->currentAnim.w = 0x50002;
|
||||
bow->yaw = playerStatus->targetYaw;
|
||||
add_vec2D_polar(&bow->moveToPos.x, &bow->moveToPos.z, -2.0f, gCameras[gCurrentCameraID].currentYaw);
|
||||
add_vec2D_polar(&bow->moveToPos.x, &bow->moveToPos.z,
|
||||
playerStatus->colliderDiameter * 0.5f, bow->yaw);
|
||||
bow->duration = 5;
|
||||
bow->yaw = atan2(bow->pos.x, bow->pos.z, playerStatus->position.x, playerStatus->position.z);
|
||||
set_action_state(ACTION_STATE_RIDE);
|
||||
suggest_player_anim_clearUnkFlag(0x10002);
|
||||
script->functionTemp[0]++;
|
||||
break;
|
||||
case 21:
|
||||
if (collisionStatus->currentFloor >= 0 && (playerStatus->animFlags & 0x100000) == 0) {
|
||||
npc->moveToPos.x = playerStatus->position.x;
|
||||
npc->moveToPos.y = playerStatus->position.y + (playerStatus->colliderHeight * 0.5f);
|
||||
npc->moveToPos.z = playerStatus->position.z;
|
||||
npc->pos.x += ((npc->moveToPos.x - npc->pos.x) / npc->duration);
|
||||
npc->pos.y += ((npc->moveToPos.y - npc->pos.y) / npc->duration);
|
||||
npc->pos.z += ((npc->moveToPos.z - npc->pos.z) / npc->duration);
|
||||
D_802BE0E4 = playerStatus->position.x - npc->pos.x;
|
||||
D_802BE0E8 = playerStatus->position.y - npc->pos.y;
|
||||
D_802BE0EC = playerStatus->position.z - npc->pos.z;
|
||||
npc->duration--;
|
||||
if (npc->duration == 0) {
|
||||
npc->yaw = playerStatus->targetYaw;
|
||||
func_8003D624(npc, 7, playerStatus->alpha1, 0, 0, 0, 0);
|
||||
if (collisionStatus->currentFloor >= 0 &&
|
||||
(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000) == 0) {
|
||||
bow->moveToPos.x = playerStatus->position.x;
|
||||
bow->moveToPos.y = playerStatus->position.y + (playerStatus->colliderHeight * 0.5f);
|
||||
bow->moveToPos.z = playerStatus->position.z;
|
||||
bow->pos.x += ((bow->moveToPos.x - bow->pos.x) / bow->duration);
|
||||
bow->pos.y += ((bow->moveToPos.y - bow->pos.y) / bow->duration);
|
||||
bow->pos.z += ((bow->moveToPos.z - bow->pos.z) / bow->duration);
|
||||
D_802BE0E4 = playerStatus->position.x - bow->pos.x;
|
||||
D_802BE0E8 = playerStatus->position.y - bow->pos.y;
|
||||
D_802BE0EC = playerStatus->position.z - bow->pos.z;
|
||||
bow->duration--;
|
||||
if (bow->duration == 0) {
|
||||
bow->yaw = playerStatus->targetYaw;
|
||||
func_8003D624(bow, 7, playerStatus->alpha1, 0, 0, 0, 0);
|
||||
suggest_player_anim_setUnkFlag(0x10014);
|
||||
sfx_play_sound_at_npc(SOUND_BOW_VANISH, 0, -4);
|
||||
script->functionTemp[0] = 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
func_802BDDF0_324740(npc);
|
||||
|
||||
func_802BDDF0_324740(bow);
|
||||
return ApiStatus_DONE2;
|
||||
case 1:
|
||||
if (collisionStatus->currentFloor >= 0) {
|
||||
playerStatus->alpha1 -= 8;
|
||||
if (playerStatus->alpha1 <= 128) {
|
||||
playerStatus->alpha1 = 128;
|
||||
npc->renderMode = 0x16;
|
||||
bow->renderMode = RENDER_MODE_SURFACE_XLU_LAYER2;
|
||||
script->functionTemp[0]++;
|
||||
playerStatus->flags &= ~0x100;
|
||||
npc->flags |= 0x40;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
bow->flags |= 0x40;
|
||||
}
|
||||
get_shadow_by_index(npc->shadowIndex)->unk_05 = playerStatus->alpha1 >> 1;
|
||||
func_8003D624(npc, 7, playerStatus->alpha1, 0, 0, 0, 0);
|
||||
npc->pos.x = playerStatus->position.x - D_802BE0E4;
|
||||
npc->pos.y = playerStatus->position.y - D_802BE0E8;
|
||||
npc->pos.z = playerStatus->position.z - D_802BE0EC;
|
||||
|
||||
get_shadow_by_index(bow->shadowIndex)->unk_05 = playerStatus->alpha1 >> 1;
|
||||
func_8003D624(bow, 7, playerStatus->alpha1, 0, 0, 0, 0);
|
||||
bow->pos.x = playerStatus->position.x - D_802BE0E4;
|
||||
bow->pos.y = playerStatus->position.y - D_802BE0E8;
|
||||
bow->pos.z = playerStatus->position.z - D_802BE0EC;
|
||||
break;
|
||||
}
|
||||
func_802BDDF0_324740(npc);
|
||||
|
||||
func_802BDDF0_324740(bow);
|
||||
return ApiStatus_DONE2;
|
||||
case 2:
|
||||
if (collisionStatus->currentFloor < 0) {
|
||||
func_802BDDF0_324740(npc);
|
||||
func_802BDDF0_324740(bow);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
npc->pos.x = playerStatus->position.x - D_802BE0E4;
|
||||
npc->pos.y = playerStatus->position.y - D_802BE0E8;
|
||||
npc->pos.z = playerStatus->position.z - D_802BE0EC;
|
||||
|
||||
bow->pos.x = playerStatus->position.x - D_802BE0E4;
|
||||
bow->pos.y = playerStatus->position.y - D_802BE0E8;
|
||||
bow->pos.z = playerStatus->position.z - D_802BE0EC;
|
||||
|
||||
distance = dist2D(0.0f, 0.0f, partnerActionStatus->stickX, partnerActionStatus->stickY);
|
||||
if ((collisionStatus->currentFloor < 0) || distance > 10.0f ||
|
||||
partnerActionStatus->pressedButtons & (BUTTON_B | BUTTON_C_DOWN) || playerStatus->flags & 0x800) {
|
||||
partnerActionStatus->pressedButtons & (BUTTON_B | BUTTON_C_DOWN) ||
|
||||
playerStatus->flags & PLAYER_STATUS_FLAGS_800) {
|
||||
if (func_802BD540_323E90() < 0) {
|
||||
script->functionTemp[0]++;
|
||||
script->functionTemp[1] = 3;
|
||||
@ -285,69 +324,67 @@ ApiStatus func_802BD694_323FE4(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
sfx_play_sound_at_npc(SOUND_BOW_APPEAR, 0, -4);
|
||||
func_802BDDF0_324740(npc);
|
||||
func_802BDDF0_324740(bow);
|
||||
return ApiStatus_DONE1;
|
||||
}
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void func_802BDDF0_324740(Npc* partner) {
|
||||
void func_802BDDF0_324740(Npc* bow) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
s32 actionState;
|
||||
|
||||
playerStatus->alpha1 = 255;
|
||||
func_8003D624(partner, 0, 0, 0, 0, 0, 0);
|
||||
partner->renderMode = 0x11;
|
||||
get_shadow_by_index(partner->shadowIndex)->unk_05 = playerStatus->alpha1 >> 1;
|
||||
func_8003D624(bow, 0, 0, 0, 0, 0, 0);
|
||||
bow->renderMode = RENDER_MODE_SURFACE_XLU_LAYER1;
|
||||
get_shadow_by_index(bow->shadowIndex)->unk_05 = playerStatus->alpha1 >> 1;
|
||||
|
||||
if (D_802BE0C4) {
|
||||
enable_player_input();
|
||||
}
|
||||
|
||||
playerStatus->flags &= ~0x8002;
|
||||
partner->flags &= ~0x42;
|
||||
playerStatus->flags &= ~(PLAYER_STATUS_FLAGS_8000 | PLAYER_STATUS_FLAGS_JUMPING);
|
||||
bow->flags &= ~(NPC_FLAG_40 | NPC_FLAG_2);
|
||||
D_802BE0C4 = FALSE;
|
||||
actionState = ACTION_STATE_IDLE;
|
||||
if (playerStatus->flags & 0x800) {
|
||||
|
||||
if (playerStatus->flags & PLAYER_STATUS_FLAGS_800) {
|
||||
actionState = ACTION_STATE_HIT_LAVA;
|
||||
}
|
||||
|
||||
set_action_state(actionState);
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
playerStatus->flags &= ~0x100;
|
||||
partner_clear_player_tracking(partner);
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
partner_clear_player_tracking(bow);
|
||||
D_802BE0C0 = FALSE;
|
||||
}
|
||||
|
||||
ApiStatus func_802BDF08_324858(Evt* script, s32 isInitialCall) {
|
||||
Npc* partner = script->owner2.npc;
|
||||
Npc* bow = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(partner);
|
||||
partner_init_put_away(bow);
|
||||
if (D_802BE0C0) {
|
||||
sfx_play_sound_at_npc(SOUND_BOW_APPEAR, 0, -4);
|
||||
}
|
||||
func_802BDDF0_324740(partner);
|
||||
}
|
||||
if (partner_put_away(partner)) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
func_802BDDF0_324740(bow);
|
||||
}
|
||||
|
||||
return partner_put_away(bow) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void func_802BDF64_3248B4(Npc* partner) {
|
||||
void func_802BDF64_3248B4(Npc* bow) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (D_802BE0C0) {
|
||||
enable_player_input();
|
||||
set_action_state(ACTION_STATE_IDLE);
|
||||
partner_clear_player_tracking(partner);
|
||||
partner_clear_player_tracking(bow);
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
D_802BE0C0 = FALSE;
|
||||
partner->flags &= ~0x2;
|
||||
bow->flags &= ~NPC_FLAG_2;
|
||||
}
|
||||
}
|
||||
|
@ -2,30 +2,31 @@
|
||||
#include "goombaria.h"
|
||||
#include "../partners.h"
|
||||
|
||||
void world_goombaria_init(Npc* partner) {
|
||||
partner->collisionHeight = 24;
|
||||
partner->collisionRadius = 20;
|
||||
void world_goombaria_init(Npc* goombaria) {
|
||||
goombaria->collisionHeight = 24;
|
||||
goombaria->collisionRadius = 20;
|
||||
}
|
||||
|
||||
ApiStatus GoombariaTakeOut(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* goombaria = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(owner);
|
||||
partner_init_get_out(goombaria);
|
||||
}
|
||||
return partner_get_out(owner) != 0;
|
||||
|
||||
return partner_get_out(goombaria) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus GoombariaUpdate(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* goombaria = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(owner, TRUE);
|
||||
partner_walking_enable(goombaria, TRUE);
|
||||
}
|
||||
|
||||
partner_walking_update_player_tracking(owner);
|
||||
partner_walking_update_motion(owner);
|
||||
partner_walking_update_player_tracking(goombaria);
|
||||
partner_walking_update_motion(goombaria);
|
||||
playerData->unk_2F4[PARTNER_GOOMBARIA]++;
|
||||
|
||||
return ApiStatus_BLOCK;
|
||||
@ -36,12 +37,13 @@ ApiStatus GoombariaUseAbility(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
ApiStatus GoombariaPutAway(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* goombaria = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(owner);
|
||||
partner_init_put_away(goombaria);
|
||||
}
|
||||
return partner_put_away(owner) != 0;
|
||||
|
||||
return partner_put_away(goombaria) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
EvtSource world_goombaria_take_out = {
|
||||
|
@ -1,11 +1,15 @@
|
||||
#include "common.h"
|
||||
#include "sprite/npc/world_goombario.h"
|
||||
#include "goombario.h"
|
||||
#include "../src/world/partners.h"
|
||||
|
||||
ApiStatus func_802BD188_3170A8(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802BD1D0_3170F0(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802BD5D8_3174F8(Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802BDB30_317A50(Evt* script, s32 isInitialCall);
|
||||
extern s32 D_802BDF60;
|
||||
|
||||
extern unkPartnerStruct* D_802BDD88_317CA8;
|
||||
|
||||
s32 func_802BD100_317020(s32 arg0) {
|
||||
s32 i;
|
||||
@ -13,32 +17,130 @@ s32 func_802BD100_317020(s32 arg0) {
|
||||
for (i = 0; i < 0x40; i++) {
|
||||
Trigger* trigger = get_trigger_by_id(i);
|
||||
|
||||
if (trigger != NULL && trigger->flags.flags & 0x100 && trigger->params2 == arg0) {
|
||||
if (trigger != NULL && trigger->flags.flags & TRIGGER_WALL_PRESS_A && trigger->params2 == arg0) {
|
||||
return trigger->unk_2C;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void world_goombario_init(Npc* partner) {
|
||||
partner->collisionHeight = 24;
|
||||
partner->collisionRadius = 20;
|
||||
void world_goombario_init(Npc* goombario) {
|
||||
goombario->collisionHeight = 24;
|
||||
goombario->collisionRadius = 20;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BD188_3170A8, Evt* script, s32 isInitialCall);
|
||||
ApiStatus func_802BD188_3170A8(Evt* script, s32 isInitialCall) {
|
||||
Npc* goombario = script->owner2.npc;
|
||||
D_802BDF60 = -1;
|
||||
|
||||
INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BD1D0_3170F0, Evt* script, s32 isInitialCall);
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(goombario);
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/goombario", func_802BD564_317484);
|
||||
return partner_get_out(goombario) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
s32 world_goombario_can_pause(Npc* partner) {
|
||||
s32 func_802BD1D0_3170F0(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* npc = script->owner2.npc;
|
||||
Entity* entity;
|
||||
f32 sp10, sp14, tempY;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(npc, 1);
|
||||
mem_clear(D_802BDD88_317CA8, sizeof(*D_802BDD88_317CA8));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[1]++;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
return 0;
|
||||
}
|
||||
|
||||
switch (D_802BDD88_317CA8->unk_04) {
|
||||
case 0:
|
||||
D_802BDD88_317CA8->unk_04 = 1;
|
||||
D_802BDD88_317CA8->flags = npc->flags;
|
||||
D_802BDD88_317CA8->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BDD88_317CA8->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BDD88_317CA8->unk_14 = 6.0f;
|
||||
D_802BDD88_317CA8->unk_18 = 50.0f;
|
||||
D_802BDD88_317CA8->unk_00 = 120;
|
||||
npc->flags |= NPC_FLAG_ENABLE_HIT_SCRIPT | NPC_FLAG_40 | NPC_FLAG_100 | NPC_FLAG_40000;
|
||||
npc->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BDD88_317CA8->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BDD88_317CA8->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BDD88_317CA8->unk_0C);
|
||||
D_802BDD88_317CA8->unk_10 = clamp_angle(D_802BDD88_317CA8->unk_10 - D_802BDD88_317CA8->unk_14);
|
||||
|
||||
if (D_802BDD88_317CA8->unk_0C > 20.0f) {
|
||||
D_802BDD88_317CA8->unk_0C--;
|
||||
} else if (D_802BDD88_317CA8->unk_0C < 19.0f) {
|
||||
D_802BDD88_317CA8->unk_0C++;
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BDD88_317CA8->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
D_802BDD88_317CA8->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BDD88_317CA8->unk_18 > 150.0f) {
|
||||
D_802BDD88_317CA8->unk_18 = 150.0f;
|
||||
}
|
||||
|
||||
npc->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BDD88_317CA8->unk_10);
|
||||
D_802BDD88_317CA8->unk_14 += 0.8;
|
||||
|
||||
if (D_802BDD88_317CA8->unk_14 > 40.0f) {
|
||||
D_802BDD88_317CA8->unk_14 = 40.0f;
|
||||
}
|
||||
|
||||
if (--D_802BDD88_317CA8->unk_00 == 0) {
|
||||
D_802BDD88_317CA8->unk_04++;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BDD88_317CA8->flags;
|
||||
D_802BDD88_317CA8->unk_00 = 30;
|
||||
D_802BDD88_317CA8->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
|
||||
if (--D_802BDD88_317CA8->unk_00 == 0) {
|
||||
D_802BDD88_317CA8->unk_04 = 0;
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void func_802BD564_317484(Npc* goombario) {
|
||||
if (D_8010C954) {
|
||||
D_8010C954 = 0;
|
||||
goombario->flags = D_802BDD88_317CA8->flags;
|
||||
D_802BDD88_317CA8->unk_04 = 0;
|
||||
partner_clear_player_tracking (goombario);
|
||||
}
|
||||
}
|
||||
|
||||
s32 world_goombario_can_pause(Npc* goombario) {
|
||||
PartnerActionStatus* goombarioActionStatus = &gPartnerActionStatus;
|
||||
s32 new_var;
|
||||
|
||||
if (gPartnerActionStatus.actionState.b[0] != 0) {
|
||||
if (goombarioActionStatus->actionState.b[0] != 0) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if ((partner->flags & 0x1800) != 0x1000) {
|
||||
if ((goombario->flags & (NPC_FLAG_1000 | NPC_FLAG_NO_Y_MOVEMENT)) != NPC_FLAG_1000) {
|
||||
return new_var = 0;
|
||||
do { } while (new_var); // why though
|
||||
}
|
||||
@ -50,31 +152,49 @@ s32 world_goombario_can_pause(Npc* partner) {
|
||||
// has big jumptable at rodata 802BDE88
|
||||
INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BD5D8_3174F8, Evt* script, s32 isInitialCall);
|
||||
|
||||
INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BDB30_317A50, Evt* script, s32 isInitialCall);
|
||||
#ifdef NON_EQUIVALENT //something with the symbol is broken
|
||||
ApiStatus func_802BDB30_317A50(Evt* script, s32 isInitialCall) {
|
||||
PartnerActionStatus* goombarioActionStatus = &gPartnerActionStatus;
|
||||
|
||||
ApiStatus func_802BDB84(Evt* script, s32 isInitialCall) {
|
||||
s32 unk = script->owner2.npc; // todo what is this?
|
||||
set_time_freeze_mode(0);
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(unk);
|
||||
if (D_802BDF64_3248B4 != 0) {
|
||||
D_802BDF64_3248B4 = 0;
|
||||
enable_player_input();
|
||||
}
|
||||
|
||||
return partner_put_away(unk) != 0;
|
||||
goombarioActionStatus->actionState.b[0] = 0;
|
||||
goombarioActionStatus->actionState.b[3] = 0;
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
#else
|
||||
INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BDB30_317A50, Evt* script, s32 isInitialCall);
|
||||
#endif
|
||||
|
||||
ApiStatus func_802BDB84(Evt* script, s32 isInitialCall) {
|
||||
Npc* goombario = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(goombario);
|
||||
}
|
||||
|
||||
return partner_put_away(goombario) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void world_goombario_pre_battle(Npc* partner) {
|
||||
PartnerActionStatus* actionStatus = &gPartnerActionStatus;
|
||||
void world_goombario_pre_battle(Npc* goombario) {
|
||||
PartnerActionStatus* goombarioActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (actionStatus->actionState.b[0] != 0) {
|
||||
if (goombarioActionStatus->actionState.b[0] != 0) {
|
||||
set_time_freeze_mode(TIME_FREEZE_NORMAL);
|
||||
enable_player_input();
|
||||
CancelMessageAndBlock();
|
||||
partner_clear_player_tracking(partner);
|
||||
actionStatus->actionState.b[0] = 0;
|
||||
actionStatus->actionState.b[3] = 0;
|
||||
disable_npc_blur(partner);
|
||||
partner_clear_player_tracking(goombario);
|
||||
goombarioActionStatus->actionState.b[0] = 0;
|
||||
goombarioActionStatus->actionState.b[3] = 0;
|
||||
disable_npc_blur(goombario);
|
||||
}
|
||||
actionStatus->actionState.b[3] = 1;
|
||||
|
||||
goombarioActionStatus->actionState.b[3] = 1;
|
||||
}
|
||||
|
||||
s32 D_802BDC40_317B60[] = {
|
||||
@ -96,7 +216,7 @@ EvtSource world_goombario_take_out = {
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 D_802BDD88_317CA8 = 0x802BDF40;
|
||||
unkPartnerStruct* D_802BDD88_317CA8 = &D_802BDF40;
|
||||
|
||||
EvtSource world_goombario_update = {
|
||||
EVT_CALL(func_802BD1D0_3170F0)
|
||||
@ -114,7 +234,8 @@ EvtSource world_goombario_use_ability = {
|
||||
EVT_RETURN
|
||||
EVT_END_IF
|
||||
EVT_IF_EQ(EVT_VAR(1), 0)
|
||||
EVT_CALL(SpeakToPlayer, NPC_PARTNER, NPC_ANIM_world_goombario_normal_talk, NPC_ANIM_world_goombario_normal_idle, 0, EVT_VAR(0))
|
||||
EVT_CALL(SpeakToPlayer, NPC_PARTNER, NPC_ANIM_world_goombario_normal_talk,
|
||||
NPC_ANIM_world_goombario_normal_idle, 0, EVT_VAR(0))
|
||||
EVT_END_IF
|
||||
EVT_WAIT_FRAMES(1)
|
||||
EVT_CALL(func_802BDB30_317A50)
|
||||
|
@ -1,8 +1,8 @@
|
||||
#include "common.h"
|
||||
#include "goompa.h"
|
||||
#include "../src/world/partners.h"
|
||||
|
||||
static s32 goompa_802BD600;
|
||||
|
||||
extern unkPartnerStruct* D_802BD58C_324E9C;
|
||||
ApiStatus func_802BD14C_324A5C(Evt* script, s32 isInitialCall);
|
||||
|
||||
void world_goompa_init(Npc* partner) {
|
||||
@ -11,29 +11,118 @@ void world_goompa_init(Npc* partner) {
|
||||
}
|
||||
|
||||
ApiStatus GoompaTakeOut(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* goompa = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(owner);
|
||||
partner_init_get_out(goompa);
|
||||
}
|
||||
return partner_get_out(owner) != 0;
|
||||
|
||||
return partner_get_out(goompa) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/goompa", func_802BD14C_324A5C);
|
||||
ApiStatus func_802BD14C_324A5C(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* goompa = script->owner2.npc;
|
||||
f32 sp10, sp14, tempY;
|
||||
Entity* entity;
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/goompa", func_802BD4E0_324DF0);
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(goompa, 1);
|
||||
mem_clear(D_802BD58C_324E9C, sizeof(*D_802BD58C_324E9C));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[5]++;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_walking_update_player_tracking(goompa);
|
||||
partner_walking_update_motion(goompa);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BD58C_324E9C->unk_04) {
|
||||
case 0:
|
||||
D_802BD58C_324E9C->unk_04 = 1;
|
||||
D_802BD58C_324E9C->flags = goompa->flags;
|
||||
D_802BD58C_324E9C->unk_0C = fabsf(dist2D(goompa->pos.x, goompa->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BD58C_324E9C->unk_10 = atan2(entity->position.x, entity->position.z, goompa->pos.x, goompa->pos.z);
|
||||
D_802BD58C_324E9C->unk_14 = 6.0f;
|
||||
D_802BD58C_324E9C->unk_18 = 50.0f;
|
||||
D_802BD58C_324E9C->unk_00 = 120;
|
||||
goompa->flags |= NPC_FLAG_ENABLE_HIT_SCRIPT | NPC_FLAG_40 | NPC_FLAG_100 | NPC_FLAG_40000;
|
||||
goompa->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BD58C_324E9C->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
goompa->pos.x = entity->position.x + (sp10 * D_802BD58C_324E9C->unk_0C);
|
||||
goompa->pos.z = entity->position.z - (sp14 * D_802BD58C_324E9C->unk_0C);
|
||||
D_802BD58C_324E9C->unk_10 = clamp_angle(D_802BD58C_324E9C->unk_10 - D_802BD58C_324E9C->unk_14);
|
||||
|
||||
if (D_802BD58C_324E9C->unk_0C > 20.0f) {
|
||||
D_802BD58C_324E9C->unk_0C--;
|
||||
} else if (D_802BD58C_324E9C->unk_0C < 19.0f) {
|
||||
D_802BD58C_324E9C->unk_0C++;
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BD58C_324E9C->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
D_802BD58C_324E9C->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BD58C_324E9C->unk_18 > 150.0f) {
|
||||
D_802BD58C_324E9C->unk_18 = 150.0f;
|
||||
}
|
||||
|
||||
goompa->pos.y += tempY;
|
||||
goompa->renderYaw = clamp_angle(360.0f - D_802BD58C_324E9C->unk_10);
|
||||
D_802BD58C_324E9C->unk_14 += 0.8;
|
||||
|
||||
if (D_802BD58C_324E9C->unk_14 > 40.0f) {
|
||||
D_802BD58C_324E9C->unk_14 = 40.0f;
|
||||
}
|
||||
|
||||
if (--D_802BD58C_324E9C->unk_00 == 0) {
|
||||
D_802BD58C_324E9C->unk_04++;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
goompa->flags = D_802BD58C_324E9C->flags;
|
||||
D_802BD58C_324E9C->unk_00 = 30;
|
||||
D_802BD58C_324E9C->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_walking_update_player_tracking(goompa);
|
||||
partner_walking_update_motion(goompa);
|
||||
|
||||
if (--D_802BD58C_324E9C->unk_00 == 0) {
|
||||
D_802BD58C_324E9C->unk_04 = 0;
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void func_802BD4E0_324DF0(Npc* goompa) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
goompa->flags = D_802BD58C_324E9C->flags;
|
||||
D_802BD58C_324E9C->unk_04 = 0;
|
||||
partner_clear_player_tracking(goompa);
|
||||
}
|
||||
}
|
||||
|
||||
ApiStatus GoompaUseAbility(Evt* script, s32 isInitialCall) {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
ApiStatus GoompaPutAway(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* goompa = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(owner);
|
||||
partner_init_put_away(goompa);
|
||||
}
|
||||
return partner_put_away(owner) != 0;
|
||||
|
||||
return partner_put_away(goompa) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
EvtSource world_goompa_take_out = {
|
||||
@ -42,7 +131,7 @@ EvtSource world_goompa_take_out = {
|
||||
EVT_END
|
||||
};
|
||||
|
||||
s32 D_802BD58C_324E9C = &goompa_802BD600;
|
||||
unkPartnerStruct* D_802BD58C_324E9C = &D_802BD600;
|
||||
|
||||
EvtSource world_goompa_update = {
|
||||
EVT_CALL(func_802BD14C_324A5C)
|
||||
|
@ -1,56 +1,114 @@
|
||||
#include "common.h"
|
||||
#include "../src/world/partners.h"
|
||||
|
||||
extern unkPartnerStruct* D_802BEB60_31CB80;
|
||||
s32 entity_interacts_with_current_partner(s32);
|
||||
s32 test_item_entity_position(f32, f32, f32, f32);
|
||||
s32 npc_raycast_up_corner(s32 ignoreFlags, f32* x, f32* y, f32* z, f32* length);
|
||||
s32 npc_raycast_up(s32 ignoreFlags, f32* x, f32* y, f32* z, f32* length);
|
||||
void start_bounce_b(void);
|
||||
extern s32 D_802BEC68;
|
||||
extern s32 D_802BEC6C;
|
||||
extern s32 D_802BEC54;
|
||||
extern s32 D_802BEB40_31CB60;
|
||||
extern s32 D_802BEC64;
|
||||
extern s32 D_802BEC58;
|
||||
extern f32 D_802BEC70;
|
||||
extern f32 D_802BEC74;
|
||||
extern f32 D_802BEC78;
|
||||
extern s32 D_802BEC50;
|
||||
extern s32 D_802BEC60;
|
||||
extern s32 D_802BEC5C;
|
||||
extern s16 D_8010C97A;
|
||||
void playFX_18(s32, f32, f32, f32, f32, f32, f32, s32);
|
||||
void func_801341B0(Npc* npc);
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD100_31B120);
|
||||
s32 func_802BD100_31B120(Npc* npc) {
|
||||
if (D_8010C978 < 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!(D_8010C978 & 0x4000)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
return entity_interacts_with_current_partner(D_8010C978 & ~0x4000);
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD144_31B164);
|
||||
void func_802BD144_31B164(Npc* kooper) {
|
||||
if (D_8010C978 >= 0 && D_8010C978 & 0x4000) {
|
||||
entity_interacts_with_current_partner(D_8010C978 & ~0x4000);
|
||||
}
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD17C_31B19C);
|
||||
s32 func_802BD17C_31B19C(Npc* kooper) {
|
||||
D_802BEC68 = test_item_entity_position(kooper->pos.x, kooper->pos.y, kooper->pos.z, kooper->collisionRadius);
|
||||
|
||||
if (D_802BEC68 < 0) {
|
||||
return 0;
|
||||
} else {
|
||||
D_802BEC6C = 1;
|
||||
gOverrideFlags |= GLOBAL_OVERRIDES_40;
|
||||
set_item_entity_flags(D_802BEC68, ENTITY_FLAGS_200000);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD200_31B220);
|
||||
void func_802BD200_31B220(Npc* kooper) {
|
||||
kooper->collisionHeight = 37;
|
||||
kooper->collisionRadius = 24;
|
||||
kooper->unk_80 = 0x00010000;
|
||||
D_802BEC54 = 0;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD228_31B248);
|
||||
ApiStatus func_802BD228_31B248(Evt* script, s32 isInitialCall) {
|
||||
Npc* kooper = script->owner2.npc;
|
||||
|
||||
s32 func_802BD260_31B280(Evt* evt, s32 arg1) {
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(kooper);
|
||||
}
|
||||
|
||||
return partner_get_out(kooper) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD260_31B280(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* npc;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
Entity* entity;
|
||||
Npc* kooper = script->owner2.npc;
|
||||
f32 sp10, sp14, tempY;
|
||||
|
||||
npc = evt->owner2.npc;
|
||||
if (arg1 != 0) {
|
||||
partner_walking_enable(npc, 1);
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(kooper, 1);
|
||||
mem_clear(D_802BEB60_31CB80, sizeof(*D_802BEB60_31CB80));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[2]++;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
return 0;
|
||||
partner_walking_update_player_tracking(kooper);
|
||||
partner_walking_update_motion(kooper);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BEB60_31CB80->unk_04) {
|
||||
case 0:
|
||||
D_802BEB60_31CB80->unk_04 = 1;
|
||||
D_802BEB60_31CB80->unk_08 = npc->flags;
|
||||
D_802BEB60_31CB80->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BEB60_31CB80->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BEB60_31CB80->flags = kooper->flags;
|
||||
D_802BEB60_31CB80->unk_0C = fabsf(dist2D(kooper->pos.x, kooper->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BEB60_31CB80->unk_10 = atan2(entity->position.x, entity->position.z, kooper->pos.x, kooper->pos.z);
|
||||
D_802BEB60_31CB80->unk_14 = 6.0f;
|
||||
D_802BEB60_31CB80->unk_18 = 50.0f;
|
||||
D_802BEB60_31CB80->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BEB60_31CB80->unk_00 = 120;
|
||||
kooper->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
kooper->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BEB60_31CB80->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BEB60_31CB80->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BEB60_31CB80->unk_0C);
|
||||
kooper->pos.x = entity->position.x + (sp10 * D_802BEB60_31CB80->unk_0C);
|
||||
kooper->pos.z = entity->position.z - (sp14 * D_802BEB60_31CB80->unk_0C);
|
||||
|
||||
D_802BEB60_31CB80->unk_10 = clamp_angle(D_802BEB60_31CB80->unk_10 - D_802BEB60_31CB80->unk_14);
|
||||
if (D_802BEB60_31CB80->unk_0C > 20.0f) {
|
||||
@ -66,9 +124,9 @@ s32 func_802BD260_31B280(Evt* evt, s32 arg1) {
|
||||
if (D_802BEB60_31CB80->unk_18 > 150.0f) {
|
||||
D_802BEB60_31CB80->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
kooper->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BEB60_31CB80->unk_10);
|
||||
kooper->renderYaw = clamp_angle(360.0f - D_802BEB60_31CB80->unk_10);
|
||||
D_802BEB60_31CB80->unk_14 += 0.8;
|
||||
if (D_802BEB60_31CB80->unk_14 > 40.0f) {
|
||||
D_802BEB60_31CB80->unk_14 = 40.0f;
|
||||
@ -79,13 +137,13 @@ s32 func_802BD260_31B280(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BEB60_31CB80->unk_08;
|
||||
D_802BEB60_31CB80->unk_00 = 0x1E;
|
||||
kooper->flags = D_802BEB60_31CB80->flags;
|
||||
D_802BEB60_31CB80->unk_00 = 30;
|
||||
D_802BEB60_31CB80->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
partner_walking_update_player_tracking(kooper);
|
||||
partner_walking_update_motion(kooper);
|
||||
|
||||
if (--D_802BEB60_31CB80->unk_00 == 0) {
|
||||
D_802BEB60_31CB80->unk_04 = 0;
|
||||
@ -93,17 +151,551 @@ s32 func_802BD260_31B280(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD5F4_31B614);
|
||||
void func_802BD5F4_31B614(Npc* kooper) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
kooper->flags = D_802BEB60_31CB80->flags;
|
||||
D_802BEB60_31CB80->unk_04 = 0;
|
||||
partner_clear_player_tracking(kooper);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef NON_MATCHING
|
||||
ApiStatus func_802BD638_31B658(Evt* script, s32 isInitialCall) {
|
||||
Camera* cam;
|
||||
ItemEntity* itemGrabbed;
|
||||
EncounterStatus* currentEncounter = &gCurrentEncounter;
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
Npc* kooper = script->owner2.npc;
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
CollisionStatus* collisionStatus = &gCollisionStatus;
|
||||
f32 sp20, sp24, sp28, sp2C;
|
||||
s32 phi_v0_4 = 0;
|
||||
f32 temp_f20_2;
|
||||
f32 temp_f20_3;
|
||||
f32 temp_f20_4;
|
||||
f32 temp_f20_5;
|
||||
f32 temp_f20_6;
|
||||
f32 phi_f0;
|
||||
f32 phi_f0_3;
|
||||
s32 tempVar;
|
||||
f32 clamp;
|
||||
f32 colheight;
|
||||
f32 temp2;
|
||||
|
||||
if (currentEncounter->unk_08 == 0) {
|
||||
if (isInitialCall) {
|
||||
func_802BD5F4_31B614(kooper);
|
||||
if (playerStatus->animFlags & 0x100000) {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
if (D_802BEC54 == 0) {
|
||||
tempVar = playerStatus->actionState;
|
||||
if (tempVar == 0 || tempVar == 1 || tempVar == 2) {
|
||||
script->functionTemp[0] = 20;
|
||||
} else {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
else if (partnerActionStatus->actionState.b[0] == 0) {
|
||||
partnerActionStatus->actionState.b[0] = 1;
|
||||
partnerActionStatus->actionState.b[3] = 2;
|
||||
script->functionTemp[0] = 5;
|
||||
kooper->currentAnim.w = 0x20009;
|
||||
D_802BEC50 = 30;
|
||||
}
|
||||
}
|
||||
|
||||
switch (script->functionTemp[0]) {
|
||||
case 20:
|
||||
if (playerStatus->statusMenuCounterinputEnabledCounter == 0) {
|
||||
if (playerStatus->decorationList == 0) {
|
||||
if (kooper->flags & 0x1000) {
|
||||
disable_player_input();
|
||||
script->functionTemp[2] = playerStatus->statusMenuCounterinputEnabledCounter;
|
||||
D_802BEC64 = 1;
|
||||
D_802BEB40_31CB60 = 0;
|
||||
D_802BEC6C = 0;
|
||||
kooper->flags &= ~0xA08;
|
||||
kooper->flags |= 0x140;
|
||||
partnerActionStatus->actionState.b[3] = 2;
|
||||
partnerActionStatus->actionState.b[0] = 1;
|
||||
D_802BEC58 = func_800EF4E0();
|
||||
enable_npc_blur(kooper);
|
||||
kooper->duration = 4;
|
||||
kooper->yaw = atan2(kooper->pos.x, kooper->pos.z,
|
||||
playerStatus->position.x, playerStatus->position.z);
|
||||
script->functionTemp[0]++;
|
||||
} else {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
} else {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
} else {
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
break;
|
||||
|
||||
case 21:
|
||||
//TODO: make if statement less bad
|
||||
if ((((u8)playerStatus->actionState - 0x15) < 3U) || (playerStatus->decorationList != 0)) {
|
||||
suggest_player_anim_clearUnkFlag(0x10002);
|
||||
script->functionTemp[0] = 0;
|
||||
break;
|
||||
} else {
|
||||
suggest_player_anim_clearUnkFlag(0x10006);
|
||||
kooper->moveToPos.x = D_802BEC70 = playerStatus->position.x;
|
||||
kooper->moveToPos.y = D_802BEC74 = playerStatus->position.y;
|
||||
kooper->moveToPos.z = D_802BEC78 = playerStatus->position.z;
|
||||
kooper->currentAnim.w = 0x20005;
|
||||
add_vec2D_polar(&kooper->moveToPos.x, &kooper->moveToPos.z,
|
||||
playerStatus->colliderDiameter / 3, playerStatus->targetYaw);
|
||||
clamp = clamp_angle(playerStatus->targetYaw + ((D_802BEC58 != 0) ? 90.0f : -90.0f));
|
||||
add_vec2D_polar(&kooper->moveToPos.x, &kooper->moveToPos.z,
|
||||
playerStatus->colliderDiameter / 4, clamp);
|
||||
kooper->pos.x = (kooper->pos.x + ((kooper->moveToPos.x - kooper->pos.x) / kooper->duration));
|
||||
kooper->pos.y = (kooper->pos.y + ((kooper->moveToPos.y - kooper->pos.y) / kooper->duration));
|
||||
kooper->pos.z = (kooper->pos.z + ((kooper->moveToPos.z - kooper->pos.z) / kooper->duration));
|
||||
kooper->duration -= 1;
|
||||
|
||||
if (kooper->duration << 0x10) {
|
||||
break;
|
||||
}
|
||||
disable_npc_blur(kooper);
|
||||
if (script->functionTemp[2] < playerStatus->statusMenuCounterinputEnabledCounter) {
|
||||
if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) {
|
||||
suggest_player_anim_clearUnkFlag(0x10002);
|
||||
} else {
|
||||
suggest_player_anim_clearUnkFlag(0x10005);
|
||||
}
|
||||
script->functionTemp[0] = 0;
|
||||
break;
|
||||
} else {
|
||||
kooper->yaw = playerStatus->targetYaw;
|
||||
kooper->jumpVelocity = 18.0f;
|
||||
kooper->jumpScale = 3.0f;
|
||||
kooper->currentAnim.w = 0x2000A;
|
||||
kooper->collisionHeight = 12;
|
||||
|
||||
kooper->moveToPos.y = playerStatus->position.y;
|
||||
//npc->moveToPos.z = playerStatus->position.y + (playerStatus->colliderHeight / 3);
|
||||
//maybe better than above line, maybe not
|
||||
temp2 = playerStatus->colliderHeight / 3;
|
||||
kooper->moveToPos.z = playerStatus->position.y + temp2;
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_JUMPING;
|
||||
gCameras->moveFlags |= CAMERA_FLAGS_1;
|
||||
|
||||
suggest_player_anim_clearUnkFlag(0x10007);
|
||||
D_802BEC60 = 0;
|
||||
sfx_play_sound_at_npc(0x2081, 0, -4);
|
||||
script->functionTemp[0] = 2;
|
||||
}
|
||||
}
|
||||
|
||||
case 2:
|
||||
if ((u8)playerStatus->actionState == 0x15 ||
|
||||
(u8)playerStatus->actionState == 0x16 ||
|
||||
(u8)playerStatus->actionState == 0x17) {
|
||||
script->functionTemp[0] = 0;
|
||||
} else {
|
||||
kooper->jumpVelocity -= kooper->jumpScale;
|
||||
playerStatus->position.y += kooper->jumpVelocity;
|
||||
if (kooper->jumpVelocity < 0.0f) {
|
||||
if (D_802BEC60 == 0) {
|
||||
D_802BEC60 = 1;
|
||||
suggest_player_anim_clearUnkFlag(0x10008);
|
||||
}
|
||||
}
|
||||
|
||||
sp20 = playerStatus->position.x;
|
||||
sp2C = playerStatus->colliderHeight / 2;
|
||||
temp2 = sp2C;
|
||||
sp24 = (playerStatus->position.y + playerStatus->colliderHeight / 2) - kooper->jumpVelocity;
|
||||
sp28 = playerStatus->position.z;
|
||||
|
||||
if ((npc_raycast_up(0x10000, &sp20, &sp24, &sp28, &sp2C) != 0) && (sp2C < temp2)) {
|
||||
collisionStatus->currentCeiling = D_8010C97A;
|
||||
playerStatus->position.y = sp24 - playerStatus->colliderHeight;
|
||||
func_802BD144_31B164(kooper);
|
||||
}
|
||||
|
||||
if (!(kooper->jumpVelocity > 0.0f) && (playerStatus->position.y < kooper->moveToPos.z)) {
|
||||
D_802BEC5C = 0;
|
||||
kooper->flags &= ~PLAYER_STATUS_ANIM_FLAGS_100000;
|
||||
partnerActionStatus->actionState.b[3] = 2;
|
||||
partnerActionStatus->actionState.b[0] = 2;
|
||||
kooper->rotation.z = 0.0f;
|
||||
kooper->planarFlyDist = 0.0f;
|
||||
kooper->moveSpeed = 8.0f;
|
||||
kooper->currentAnim.w = 0x20009;
|
||||
D_802BEB40_31CB60 = 1;
|
||||
temp_f20_2 = sin_deg(playerStatus->targetYaw);
|
||||
playFX_18(3, kooper->pos.x, kooper->pos.y + kooper->collisionHeight, kooper->pos.z,
|
||||
temp_f20_2, -1.0f, -cos_deg(playerStatus->targetYaw), 3);
|
||||
start_bounce_b();
|
||||
|
||||
if (D_802BEC64 != 0) {
|
||||
enable_player_input();
|
||||
D_802BEC64 = 0;
|
||||
}
|
||||
|
||||
script->functionTemp[0] = 3;
|
||||
D_802BEC60 = 0;
|
||||
gCameras->moveFlags |= CAMERA_FLAGS_1;
|
||||
sfx_play_sound_at_npc(0x283, 0, -4);
|
||||
sfx_play_sound_at_npc(0x284, 0, -4);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case 3:
|
||||
//TODO: make if statement less bad
|
||||
if (((u8)playerStatus->actionState - 0x15) > 1U) {
|
||||
sp20 = kooper->pos.x;
|
||||
sp24 = kooper->pos.y;
|
||||
sp28 = kooper->pos.z;
|
||||
|
||||
if (npc_test_move_taller_with_slipping(0x8000, &sp20, &sp24, &sp28, kooper->moveSpeed,
|
||||
kooper->yaw - 20.0f, kooper->collisionHeight,
|
||||
(kooper->collisionRadius / 2)) != 0) {
|
||||
if (func_802BD100_31B120(kooper) == 0) {
|
||||
sfx_play_sound_at_npc(0x10C, 0, -4);
|
||||
}
|
||||
|
||||
temp_f20_3 = sin_deg(kooper->yaw);
|
||||
playFX_18(3, kooper->pos.x, kooper->pos.y + kooper->collisionHeight, kooper->pos.z,
|
||||
temp_f20_3, -1.0f, -cos_deg(kooper->yaw), 1);
|
||||
sfx_play_sound_at_npc(0, 0, -4);
|
||||
script->functionTemp[0] = 7;
|
||||
break;
|
||||
}
|
||||
|
||||
sp20 = kooper->pos.x;
|
||||
sp24 = kooper->pos.y;
|
||||
sp28 = kooper->pos.z;
|
||||
|
||||
if ((npc_test_move_taller_with_slipping(0x8000, &sp20, &sp24, &sp28, kooper->moveSpeed,
|
||||
kooper->yaw + 20.0f, kooper->collisionHeight,
|
||||
kooper->collisionRadius / 2) == 0) &&
|
||||
(sp20 = kooper->pos.x, sp24 = kooper->pos.y,
|
||||
sp28 = kooper->pos.z,
|
||||
(npc_test_move_taller_with_slipping(0x8000, &sp20, &sp24,
|
||||
&sp28, kooper->moveSpeed, kooper->yaw,
|
||||
kooper->collisionHeight,
|
||||
kooper->collisionRadius / 2)== 0))) {
|
||||
kooper->pos.x = sp20;
|
||||
kooper->pos.y = sp24;
|
||||
kooper->pos.z = sp28;
|
||||
kooper->planarFlyDist += kooper->moveSpeed;
|
||||
func_8003D660(kooper, 1);
|
||||
kooper->moveSpeed += 2.0;
|
||||
|
||||
if (kooper->moveSpeed > 14.0) {
|
||||
kooper->moveSpeed = 14.0f;
|
||||
}
|
||||
|
||||
if ((func_800397E8(kooper, 6.0f) == 0) && ((playerStatus->flags & 6) == 0)) {
|
||||
kooper->pos.y = (kooper->pos.y + ((playerStatus->position.y - kooper->pos.y) / 10.0f));
|
||||
}
|
||||
|
||||
npc_do_other_npc_collision(kooper);
|
||||
|
||||
if ((kooper->flags & 0x2000000) == 0) {
|
||||
if (func_802BD17C_31B19C(kooper) != 0) {
|
||||
sfx_play_sound_at_npc(0x286, 0, -4);
|
||||
temp_f20_4 = sin_deg(kooper->yaw);
|
||||
playFX_18(3, kooper->pos.x, kooper->pos.y + kooper->collisionHeight, kooper->pos.z,
|
||||
temp_f20_4, -1.0f, -cos_deg(kooper->yaw), 1);
|
||||
sfx_play_sound_at_npc(0, 0, -4);
|
||||
script->functionTemp[0] = 4;
|
||||
D_802BEC50 = 8;
|
||||
kooper->moveSpeed -= 4.0;
|
||||
if (kooper->moveSpeed < 0.01) {
|
||||
kooper->moveSpeed = 0.01f;
|
||||
kooper->planarFlyDist += 1.0;
|
||||
}
|
||||
}
|
||||
else if (D_802BEB40_31CB60 == 2) {
|
||||
sfx_play_sound_at_npc(0, 0, -4);
|
||||
script->functionTemp[0] = 5;
|
||||
D_802BEC50 = 30;
|
||||
kooper->moveSpeed = 0.0f;
|
||||
} else {
|
||||
if (kooper->planarFlyDist > 140.0f) {
|
||||
label2:
|
||||
script->functionTemp[0] = 7;
|
||||
kooper->moveSpeed = 0.0f;
|
||||
sfx_play_sound_at_npc(0, 0, -4);
|
||||
}
|
||||
|
||||
else if (kooper->planarFlyDist > 105.0f) {
|
||||
kooper->moveSpeed -= 4.0;
|
||||
if (kooper->moveSpeed < 0.01) {
|
||||
kooper->moveSpeed = 0.01f;
|
||||
kooper->planarFlyDist += 1.0;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
goto label2;
|
||||
}
|
||||
} else {
|
||||
if (func_802BD100_31B120(kooper) == 0) {
|
||||
sfx_play_sound_at_npc(0x10C, 0, -4);
|
||||
}
|
||||
|
||||
temp_f20_3 = sin_deg(kooper->yaw);
|
||||
playFX_18(3, kooper->pos.x, kooper->pos.y + kooper->collisionHeight, kooper->pos.z,
|
||||
temp_f20_3, -1.0f, -cos_deg(kooper->yaw), 1);
|
||||
sfx_play_sound_at_npc(0, 0, -4);
|
||||
script->functionTemp[0] = 7;
|
||||
}
|
||||
} else {
|
||||
script->functionTemp[0] = 0;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
sp20 = kooper->pos.x;
|
||||
sp24 = kooper->pos.y;
|
||||
sp28 = kooper->pos.z;
|
||||
|
||||
npc_test_move_taller_with_slipping(0x8000, &sp20, &sp24, &sp28, kooper->moveSpeed, kooper->yaw,
|
||||
kooper->collisionHeight, ( kooper->collisionRadius / 2));
|
||||
kooper->pos.x = sp20;
|
||||
kooper->pos.y = sp24;
|
||||
kooper->pos.z = sp28;
|
||||
|
||||
kooper->planarFlyDist += kooper->moveSpeed;
|
||||
func_8003D660(kooper, 1);
|
||||
kooper->moveSpeed -= 6.0;
|
||||
|
||||
if (kooper->moveSpeed < 0.01) {
|
||||
kooper->moveSpeed = 0.01f;
|
||||
kooper->planarFlyDist += 1.0;
|
||||
}
|
||||
|
||||
if (D_802BEC50 == 0) {
|
||||
script->functionTemp[0] = 7;
|
||||
}
|
||||
D_802BEC50--;
|
||||
break;
|
||||
|
||||
case 5:
|
||||
if (D_802BEC50 != 0) {
|
||||
D_802BEC50--;
|
||||
} else {
|
||||
script->functionTemp[0] = 7;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (script->functionTemp[0] == 7) {
|
||||
kooper->flags |= NPC_FLAG_100;
|
||||
//TODO: make if statement less bad
|
||||
if (((u8)playerStatus->actionState - 0x15) < 2U) {
|
||||
script->functionTemp[0] = 0;
|
||||
} else {
|
||||
temp_f20_5 = atan2(D_802BEC70, D_802BEC78, kooper->pos.x, kooper->pos.z);
|
||||
kooper->yaw = temp_f20_5 + (get_clamped_angle_diff(kooper->yaw, temp_f20_5) * 0.125f);
|
||||
npc_move_heading(kooper, -kooper->moveSpeed, kooper->yaw);
|
||||
kooper->planarFlyDist -= kooper->moveSpeed;
|
||||
func_8003D660(kooper, 1);
|
||||
kooper->moveSpeed += 1.3333333333333333;
|
||||
|
||||
if (kooper->moveSpeed > 14.0) {
|
||||
kooper->moveSpeed = 14.0f;
|
||||
}
|
||||
|
||||
if (func_800397E8(kooper, 6.0f) == 0) {
|
||||
kooper->pos.y = (kooper->pos.y + ((playerStatus->position.y - kooper->pos.y) / 10.0f));
|
||||
}
|
||||
|
||||
sp20 = kooper->pos.x;
|
||||
sp24 = kooper->pos.y;
|
||||
sp28 = kooper->pos.z;
|
||||
|
||||
if (npc_test_move_taller_with_slipping(0x8000, &sp20, &sp24, &sp28, kooper->moveSpeed,
|
||||
clamp_angle(kooper->yaw + 180.0f), kooper->collisionHeight,
|
||||
kooper->collisionRadius) != 0) {
|
||||
kooper->pos.x = sp20;
|
||||
kooper->pos.y = sp24;
|
||||
kooper->pos.z = sp28;
|
||||
sfx_play_sound_at_npc(0x10C, 0, -4);
|
||||
temp_f20_6 = sin_deg(kooper->yaw + 180.0f);
|
||||
playFX_18(3, kooper->pos.x, kooper->pos.y + kooper->collisionHeight, kooper->pos.z,
|
||||
temp_f20_6, -1.0f, -cos_deg(kooper->yaw + 180.0f), 1);
|
||||
script->functionTemp[0] = 0;
|
||||
} else {
|
||||
if (D_802BEC6C != 0) {
|
||||
itemGrabbed = get_item_entity(D_802BEC68);
|
||||
sp20 = kooper->pos.x;
|
||||
sp24 = kooper->pos.y + 8.0f;
|
||||
sp28 = kooper->pos.z;
|
||||
|
||||
clamp = clamp_angle(playerStatus->targetYaw - ((D_802BEC58) ? 90.0f : -90.0f));
|
||||
|
||||
add_vec2D_polar(&sp20, &sp28, 4.0f, clamp);
|
||||
itemGrabbed->position.x = sp20;
|
||||
itemGrabbed->position.y = sp24;
|
||||
itemGrabbed->position.z = sp28;
|
||||
}
|
||||
|
||||
if (kooper->planarFlyDist + 15.0f < kooper->moveSpeed) {
|
||||
script->functionTemp[0] = 0;
|
||||
} else if (kooper->planarFlyDist + 15.0f < 35.0f) {
|
||||
kooper->moveSpeed -= 4.0;
|
||||
if (kooper->moveSpeed < 4.0) {
|
||||
kooper->moveSpeed = 4.0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (script->functionTemp[0] == 0) {
|
||||
if (D_802BEC64 != 0) {
|
||||
enable_player_input();
|
||||
D_802BEC64 = 0;
|
||||
}
|
||||
|
||||
D_802BEB40_31CB60 = 0;
|
||||
kooper->flags |= NPC_FLAG_100;
|
||||
kooper->flags &= ~NPC_FLAG_NO_Y_MOVEMENT;
|
||||
kooper->flags &= ~NPC_FLAG_40;
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
kooper->jumpVelocity = 0.0f;
|
||||
kooper->collisionHeight = 24;
|
||||
kooper->currentAnim.w = 0x20000 | 4;
|
||||
sfx_stop_sound(0x284);
|
||||
disable_npc_blur(kooper);
|
||||
|
||||
if (D_802BEC6C != 0) {
|
||||
func_801341B0(D_802BEC68);
|
||||
D_802BEC6C = 0;
|
||||
}
|
||||
|
||||
D_802BEC54 = 0;
|
||||
partner_clear_player_tracking(kooper);
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
}
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
#else
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BD638_31B658);
|
||||
#endif
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BE7E0_31C800);
|
||||
ApiStatus func_802BE7E0_31C800(Evt* script, s32 isInitialCall) {
|
||||
Npc* kooper = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(kooper);
|
||||
}
|
||||
|
||||
return partner_put_away(kooper) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
#ifdef NON_EQUIVALENT
|
||||
s32 func_802BE818_31C838(Npc* npcKooper, Npc* npc2) {
|
||||
f32 npcKooperXTemp, npcKooperYTemp, npcKooperZTemp;
|
||||
f32 npcX, npcY, npcZ;
|
||||
f32 npcKooperX, npcKooperY, npcKooperZ;
|
||||
f32 npcCollisionHeight, kooperCollisionHeight;
|
||||
f32 npcCollisionRadius, kooperCollisionRadius;
|
||||
f32 temp_f0, temp_f20;
|
||||
f32 npcDistanceToKooperX;
|
||||
f32 new_var2;
|
||||
|
||||
if (D_802BEB40_31CB60) {
|
||||
npcX = npc2->pos.x;
|
||||
npcY = npc2->pos.y;
|
||||
npcZ = npc2->pos.z;
|
||||
|
||||
npcDistanceToKooperX = npcKooper->pos.x;
|
||||
npcKooperX = npcDistanceToKooperX;
|
||||
npcKooperY = npcKooper->pos.y;
|
||||
npcKooperZ = npcKooper->pos.z;
|
||||
|
||||
npcCollisionHeight = npc2->collisionHeight;
|
||||
npcCollisionRadius = npc2->collisionRadius * 0.8;
|
||||
kooperCollisionHeight = npcKooper->collisionHeight;
|
||||
kooperCollisionRadius = npcKooper->collisionRadius * 0.55;
|
||||
|
||||
temp_f20 = atan2(npcX, npcZ, npcKooperX, npcKooperZ);
|
||||
temp_f0 = dist2D(npcX, npcZ, npcKooperX, npcKooperZ);
|
||||
|
||||
npcKooperX = npcDistanceToKooperX;
|
||||
npcKooperXTemp = npcKooper->pos.x;
|
||||
npcKooperYTemp = npcKooper->pos.y;
|
||||
npcKooperZTemp = npcKooper->pos.z;
|
||||
|
||||
if (npc_test_move_taller_with_slipping(0, &npcKooperXTemp, &npcKooperYTemp, &npcKooperZTemp, temp_f0, temp_f20,
|
||||
kooperCollisionHeight, kooperCollisionRadius + npcCollisionRadius) == 0) {
|
||||
if (!((npcKooperY) > npcCollisionHeight + npcY)) {
|
||||
if (!((kooperCollisionHeight + npcCollisionHeight) < npcY)) {
|
||||
npcDistanceToKooperX = npcX - npcKooperX;
|
||||
new_var2 = SQ(npcDistanceToKooperX);
|
||||
npcKooperX = (SQ(kooperCollisionRadius)) + (SQ(npcCollisionRadius));
|
||||
npcKooperZ = npcZ - npcKooperZ;
|
||||
if (!(npcKooperX <= (new_var2 + (SQ(npcKooperZ))))) {
|
||||
D_802BEB40_31CB60 = 2;
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
#else
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BE818_31C838);
|
||||
#endif
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BEA24_31CA44);
|
||||
void func_802BEA24_31CA44(Npc* kooper) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* kooperActionStatus = &gPartnerActionStatus;
|
||||
D_802BEC54 = 0;
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/kooper", func_802BEB10_31CB30);
|
||||
if (kooperActionStatus->actionState.b[0] != 0) {
|
||||
if (kooperActionStatus->actionState.b[0] == 2) {
|
||||
D_802BEC54 = 1;
|
||||
}
|
||||
|
||||
if (D_802BEC64) {
|
||||
enable_player_input();
|
||||
D_802BEC64 = 0;
|
||||
}
|
||||
|
||||
D_802BEB40_31CB60 = 0;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_JUMPING;
|
||||
|
||||
kooper->jumpVelocity = 0.0f;
|
||||
kooper->flags &= ~NPC_FLAG_NO_Y_MOVEMENT;
|
||||
kooper->flags &= ~NPC_FLAG_40;
|
||||
|
||||
sfx_stop_sound(0x284);
|
||||
set_action_state(0);
|
||||
partner_clear_player_tracking(kooper);
|
||||
disable_npc_blur(kooper);
|
||||
|
||||
kooperActionStatus->actionState.b[3] = 0;
|
||||
kooperActionStatus->actionState.b[0] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
void func_802BEB10_31CB30(Npc* npc) {
|
||||
if (D_802BEC54) {
|
||||
partner_clear_player_tracking(npc);
|
||||
partner_use_ability();
|
||||
}
|
||||
}
|
||||
|
@ -20,7 +20,6 @@ extern f32 D_802BFF28;
|
||||
extern s16 D_8010C97A;
|
||||
|
||||
s32 func_802BD7DC(void);
|
||||
s32 partner_use_ability(void);
|
||||
f32 get_player_normal_pitch(void);
|
||||
void partner_kill_ability_script(void);
|
||||
f64 fabs(f64 val);
|
||||
@ -29,26 +28,26 @@ extern f64 D_802BFEF8;
|
||||
|
||||
void func_802BD100_320C50(void) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
Npc* npc = get_npc_unsafe(NPC_PARTNER);
|
||||
Npc* lakilester = get_npc_unsafe(NPC_PARTNER);
|
||||
s32 playerFlags = playerStatus->flags;
|
||||
Camera* currentCamera;
|
||||
f32 playerSpeedCopy;
|
||||
s32 temp_v0_2;
|
||||
|
||||
if (playerFlags & 0x4000) {
|
||||
if (playerFlags & PLAYER_STATUS_FLAGS_4000) {
|
||||
playerSpeedCopy = playerStatus->currentSpeed;
|
||||
if (playerFlags & 0x40000) {
|
||||
if (playerFlags & PLAYER_STATUS_FLAGS_40000) {
|
||||
playerSpeedCopy *= 0.5f;
|
||||
}
|
||||
|
||||
add_vec2D_polar(&npc->pos.x, &npc->pos.z, playerSpeedCopy, playerStatus->heading);
|
||||
npc->yaw = playerStatus->targetYaw;
|
||||
add_vec2D_polar(&lakilester->pos.x, &lakilester->pos.z, playerSpeedCopy, playerStatus->heading);
|
||||
lakilester->yaw = playerStatus->targetYaw;
|
||||
}
|
||||
|
||||
temp_v0_2 = abs(D_802BFF18);
|
||||
playerStatus->position.x = npc->pos.x;
|
||||
playerStatus->position.y = npc->pos.y + 10.0f + (temp_v0_2 * 0.34f);
|
||||
playerStatus->position.z = npc->pos.z;
|
||||
playerStatus->position.x = lakilester->pos.x;
|
||||
playerStatus->position.y = lakilester->pos.y + 10.0f + (temp_v0_2 * 0.34f);
|
||||
playerStatus->position.z = lakilester->pos.z;
|
||||
currentCamera = &gCameras[gCurrentCameraID];
|
||||
add_vec2D_polar(&playerStatus->position.x, &playerStatus->position.z, 2.0f, currentCamera->currentYaw);
|
||||
}
|
||||
@ -71,62 +70,57 @@ void func_802BD21C_320D6C(Npc* npc) {
|
||||
npc->moveToPos.z = npc->pos.z;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD29C_320DEC(Evt* evt, s32 isInitialCall) {
|
||||
Npc* npc = evt->owner2.npc;
|
||||
ApiStatus func_802BD29C_320DEC(Evt* script, s32 isInitialCall) {
|
||||
Npc* lakilester = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(npc);
|
||||
partner_init_get_out(lakilester);
|
||||
}
|
||||
|
||||
if (partner_get_out(npc) > 0U) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
return partner_get_out(lakilester) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD2D4_320E24(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* lakilester = script->owner2.npc;
|
||||
Entity* entity;
|
||||
Npc* npc = script->owner2.npc;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_flying_enable(npc, 1);
|
||||
partner_flying_enable(lakilester, 1);
|
||||
mem_clear(D_802BFE7C_3239CC, sizeof(*D_802BFE7C_3239CC));
|
||||
D_8010C954 = NULL;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[8]++;
|
||||
npc->flags |= 0x10000;
|
||||
lakilester->flags |= NPC_FLAG_DIRTY_SHADOW;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(lakilester);
|
||||
partner_flying_update_motion(lakilester);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BFE7C_3239CC->unk_04) {
|
||||
case 0:
|
||||
D_802BFE7C_3239CC->unk_04 = 1;
|
||||
D_802BFE7C_3239CC->unk_08 = npc->flags;
|
||||
D_802BFE7C_3239CC->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BFE7C_3239CC->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BFE7C_3239CC->flags = lakilester->flags;
|
||||
D_802BFE7C_3239CC->unk_0C = fabsf(dist2D(lakilester->pos.x, lakilester->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BFE7C_3239CC->unk_10 = atan2(entity->position.x, entity->position.z, lakilester->pos.x, lakilester->pos.z);
|
||||
D_802BFE7C_3239CC->unk_14 = 6.0f;
|
||||
D_802BFE7C_3239CC->unk_18 = 50.0f;
|
||||
D_802BFE7C_3239CC->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BFE7C_3239CC->unk_00 = 120;
|
||||
lakilester->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
lakilester->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BFE7C_3239CC->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BFE7C_3239CC->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BFE7C_3239CC->unk_0C);
|
||||
|
||||
lakilester->pos.x = entity->position.x + (sp10 * D_802BFE7C_3239CC->unk_0C);
|
||||
lakilester->pos.z = entity->position.z - (sp14 * D_802BFE7C_3239CC->unk_0C);
|
||||
D_802BFE7C_3239CC->unk_10 = clamp_angle(D_802BFE7C_3239CC->unk_10 - D_802BFE7C_3239CC->unk_14);
|
||||
|
||||
if (D_802BFE7C_3239CC->unk_0C > 20.0f) {
|
||||
D_802BFE7C_3239CC->unk_0C--;
|
||||
} else if (D_802BFE7C_3239CC->unk_0C < 19.0f) {
|
||||
@ -134,16 +128,16 @@ ApiStatus func_802BD2D4_320E24(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BFE7C_3239CC->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
|
||||
D_802BFE7C_3239CC->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BFE7C_3239CC->unk_18 > 150.0f) {
|
||||
D_802BFE7C_3239CC->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BFE7C_3239CC->unk_10);
|
||||
lakilester->pos.y += tempY;
|
||||
lakilester->renderYaw = clamp_angle(360.0f - D_802BFE7C_3239CC->unk_10);
|
||||
D_802BFE7C_3239CC->unk_14 += D_802BFEF0;
|
||||
|
||||
if (D_802BFE7C_3239CC->unk_14 > 40.0f) {
|
||||
D_802BFE7C_3239CC->unk_14 = 40.0f;
|
||||
}
|
||||
@ -153,13 +147,13 @@ ApiStatus func_802BD2D4_320E24(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BFE7C_3239CC->unk_08;
|
||||
D_802BFE7C_3239CC->unk_00 = 0x1E;
|
||||
lakilester->flags = D_802BFE7C_3239CC->flags;
|
||||
D_802BFE7C_3239CC->unk_00 = 30;
|
||||
D_802BFE7C_3239CC->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(lakilester);
|
||||
partner_flying_update_motion(lakilester);
|
||||
|
||||
if (--D_802BFE7C_3239CC->unk_00 == 0) {
|
||||
D_802BFE7C_3239CC->unk_04 = 0;
|
||||
@ -176,15 +170,16 @@ void func_802BD678_3211C8(Npc* npc) {
|
||||
if (D_8010C954 != NULL) {
|
||||
temp_v1 = D_802BFE7C_3239CC;
|
||||
D_8010C954 = NULL;
|
||||
npc->flags = temp_v1->unk_08;
|
||||
npc->flags = temp_v1->flags;
|
||||
temp_v1->unk_04 = 0;
|
||||
partner_clear_player_tracking(npc);
|
||||
}
|
||||
}
|
||||
|
||||
void func_802BD6BC_32120C(f32* arg0, f32* arg1) {
|
||||
f32 temp_f24 = gPartnerActionStatus.stickX;
|
||||
f32 temp_f26 = gPartnerActionStatus.stickY;
|
||||
PartnerActionStatus* lakilesterActionStatus = &gPartnerActionStatus;
|
||||
f32 temp_f24 = lakilesterActionStatus->stickX;
|
||||
f32 temp_f26 = lakilesterActionStatus->stickY;
|
||||
f32 temp_f22 = -temp_f26;
|
||||
f32 atan = atan2(0.0f, 0.0f, temp_f24, temp_f22);
|
||||
f32 temp = clamp_angle(atan + gCameras->currentYaw);
|
||||
@ -206,15 +201,14 @@ s32 func_802BD7DC(void) {
|
||||
Camera* currentCamera;
|
||||
f32 hitDirX, hitDirZ;
|
||||
f32 hitRx, hitRz;
|
||||
f32 outLength;
|
||||
f32 outX, outY, outZ;
|
||||
Npc *npc = get_npc_unsafe(NPC_PARTNER);
|
||||
f32 outX, outY, outZ, outLength;
|
||||
Npc* npc = get_npc_unsafe(NPC_PARTNER);
|
||||
s32 colliderTypeID;
|
||||
s32 raycastResult;
|
||||
s32 ret;
|
||||
|
||||
if (playerStatus->animFlags & 0x20000000) {
|
||||
playerStatus->animFlags &= ~0x20000000;
|
||||
if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_20000000) {
|
||||
playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_20000000;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@ -259,7 +253,8 @@ s32 func_802BD99C_3214EC(Npc* partner, f32 yOffset, f32 zOffset) {
|
||||
|
||||
D_802BFF24 = 0;
|
||||
|
||||
if (player_raycast_below_cam_relative(&gPlayerStatus, &outX, &outY, &outZ, &outLength, &hitRx, &hitRz, &hitDirX, &hitDirZ) >= 0) {
|
||||
if (player_raycast_below_cam_relative(&gPlayerStatus, &outX, &outY, &outZ, &outLength, &hitRx, &hitRz,
|
||||
&hitDirX, &hitDirZ) >= 0) {
|
||||
temp_f4 = outY - partner->moveToPos.y;
|
||||
if (temp_f4 != 0.0f) {
|
||||
if (fabs(temp_f4) < 10.0) {
|
||||
@ -275,72 +270,72 @@ s32 func_802BD99C_3214EC(Npc* partner, f32 yOffset, f32 zOffset) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
void func_802BDA90_3215E0(Npc* npc) {
|
||||
f32 temp_f20 = npc->collisionRadius * 0.8f;
|
||||
f32 temp_f0 = clamp_angle(npc->yaw);
|
||||
f32 x = npc->pos.x;
|
||||
f32 y = npc->moveToPos.y;
|
||||
f32 z = npc->pos.z;
|
||||
void func_802BDA90_3215E0(Npc* lakilester) {
|
||||
f32 temp_f20 = lakilester->collisionRadius * 0.8f;
|
||||
f32 temp_f0 = clamp_angle(lakilester->yaw);
|
||||
f32 x = lakilester->pos.x;
|
||||
f32 y = lakilester->moveToPos.y;
|
||||
f32 z = lakilester->pos.z;
|
||||
|
||||
if (npc_test_move_complex_with_slipping(npc->unk_80, &x, &y, &z, 0.0f, temp_f0, npc->collisionHeight, temp_f20)) {
|
||||
npc->flags |= 0x6000;
|
||||
npc->unk_86 = D_8010C97A;
|
||||
npc->pos.x = x;
|
||||
npc->pos.z = z;
|
||||
if (npc_test_move_complex_with_slipping(lakilester->unk_80, &x, &y, &z, 0.0f, temp_f0, lakilester->collisionHeight, temp_f20)) {
|
||||
lakilester->flags |= (NPC_FLAG_4000 | NPC_FLAG_NO_PROJECT_SHADOW);
|
||||
lakilester->unk_86 = D_8010C97A;
|
||||
lakilester->pos.x = x;
|
||||
lakilester->pos.z = z;
|
||||
} else {
|
||||
npc->flags &= ~0x6000;
|
||||
lakilester->flags &= ~(NPC_FLAG_4000 | NPC_FLAG_NO_PROJECT_SHADOW);
|
||||
}
|
||||
|
||||
temp_f0 = clamp_angle(npc->yaw + 45.0f);
|
||||
x = npc->pos.x;
|
||||
y = npc->moveToPos.y;
|
||||
z = npc->pos.z;
|
||||
temp_f0 = clamp_angle(lakilester->yaw + 45.0f);
|
||||
x = lakilester->pos.x;
|
||||
y = lakilester->moveToPos.y;
|
||||
z = lakilester->pos.z;
|
||||
|
||||
if (npc_test_move_taller_with_slipping(npc->unk_80, &x, &y, &z, 0.0f, temp_f0, npc->collisionHeight, temp_f20)) {
|
||||
npc->pos.x = x;
|
||||
npc->pos.z = z;
|
||||
npc->flags |= 0x2000;
|
||||
if (npc_test_move_taller_with_slipping(lakilester->unk_80, &x, &y, &z, 0.0f, temp_f0, lakilester->collisionHeight, temp_f20)) {
|
||||
lakilester->pos.x = x;
|
||||
lakilester->pos.z = z;
|
||||
lakilester->flags |= NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
} else {
|
||||
npc->flags &= ~0x2000;
|
||||
lakilester->flags &= ~NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
}
|
||||
|
||||
temp_f0 = clamp_angle(npc->yaw - 45.0f);
|
||||
x = npc->pos.x;
|
||||
y = npc->moveToPos.y;
|
||||
z = npc->pos.z;
|
||||
temp_f0 = clamp_angle(lakilester->yaw - 45.0f);
|
||||
x = lakilester->pos.x;
|
||||
y = lakilester->moveToPos.y;
|
||||
z = lakilester->pos.z;
|
||||
|
||||
if (npc_test_move_taller_with_slipping(npc->unk_80, &x, &y, &z, 0.0f, temp_f0, npc->collisionHeight, temp_f20)) {
|
||||
npc->pos.x = x;
|
||||
npc->pos.z = z;
|
||||
npc->flags |= 0x2000;
|
||||
if (npc_test_move_taller_with_slipping(lakilester->unk_80, &x, &y, &z, 0.0f, temp_f0, lakilester->collisionHeight, temp_f20)) {
|
||||
lakilester->pos.x = x;
|
||||
lakilester->pos.z = z;
|
||||
lakilester->flags |= NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
} else {
|
||||
npc->flags &= ~0x2000;
|
||||
lakilester->flags &= ~NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
}
|
||||
|
||||
temp_f0 = clamp_angle(npc->yaw + 45.0f + 180.0f);
|
||||
x = npc->pos.x;
|
||||
y = npc->moveToPos.y;
|
||||
z = npc->pos.z;
|
||||
temp_f0 = clamp_angle(lakilester->yaw + 45.0f + 180.0f);
|
||||
x = lakilester->pos.x;
|
||||
y = lakilester->moveToPos.y;
|
||||
z = lakilester->pos.z;
|
||||
|
||||
if (npc_test_move_simple_with_slipping(npc->unk_80, &x, &y, &z, 0.0f, temp_f0, npc->collisionHeight, temp_f20)) {
|
||||
npc->flags |= 0x2000;
|
||||
npc->pos.x = x;
|
||||
npc->pos.z = z;
|
||||
if (npc_test_move_simple_with_slipping(lakilester->unk_80, &x, &y, &z, 0.0f, temp_f0, lakilester->collisionHeight, temp_f20)) {
|
||||
lakilester->flags |= NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
lakilester->pos.x = x;
|
||||
lakilester->pos.z = z;
|
||||
} else {
|
||||
npc->flags &= ~0x2000;
|
||||
lakilester->flags &= ~NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
}
|
||||
|
||||
temp_f0 = clamp_angle(npc->yaw - 45.0f + 180.0f);
|
||||
x = npc->pos.x;
|
||||
y = npc->moveToPos.y;
|
||||
z = npc->pos.z;
|
||||
temp_f0 = clamp_angle(lakilester->yaw - 45.0f + 180.0f);
|
||||
x = lakilester->pos.x;
|
||||
y = lakilester->moveToPos.y;
|
||||
z = lakilester->pos.z;
|
||||
|
||||
if (npc_test_move_simple_with_slipping(npc->unk_80, &x, &y, &z, 0.0f, temp_f0, npc->collisionHeight, temp_f20)) {
|
||||
npc->flags |= 0x2000;
|
||||
npc->pos.x = x;
|
||||
npc->pos.z = z;
|
||||
if (npc_test_move_simple_with_slipping(lakilester->unk_80, &x, &y, &z, 0.0f, temp_f0, lakilester->collisionHeight, temp_f20)) {
|
||||
lakilester->flags |= NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
lakilester->pos.x = x;
|
||||
lakilester->pos.z = z;
|
||||
} else {
|
||||
npc->flags &= ~0x2000;
|
||||
lakilester->flags &= ~NPC_FLAG_NO_PROJECT_SHADOW;
|
||||
}
|
||||
}
|
||||
|
||||
@ -532,16 +527,17 @@ INCLUDE_ASM(s32, "world/partner/lakilester", func_802BDDD8_321928);
|
||||
#endif
|
||||
|
||||
s32 func_802BE6A0_3221F0(f32* arg0) {
|
||||
f32 colliderHeight = gPlayerStatus.colliderHeight;
|
||||
f32 hitDirX, hitDirZ;
|
||||
f32 hitRx, hitRz;
|
||||
f32 sp28, sp2C;
|
||||
f32 colliderHeight = gPlayerStatus.colliderHeight;
|
||||
|
||||
*arg0 = gPlayerStatus.position.y + colliderHeight;
|
||||
sp28 = gPlayerStatus.position.x;
|
||||
sp2C = gPlayerStatus.position.z;
|
||||
|
||||
player_raycast_below_cam_relative(&gPlayerStatus, &sp28, arg0, &sp2C, &colliderHeight, &hitRx, &hitRz, &hitDirX, &hitDirZ);
|
||||
player_raycast_below_cam_relative(&gPlayerStatus, &sp28, arg0, &sp2C, &colliderHeight, &hitRx, &hitRz,
|
||||
&hitDirX, &hitDirZ);
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/lakilester", func_802BE724_322274);
|
||||
@ -550,16 +546,16 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
Camera* cam = &gCameras[0];
|
||||
Npc* partner = script->owner2.npc;
|
||||
Npc* lakilester = script->owner2.npc;
|
||||
f32 sp20, sp24, sp28, sp2C;
|
||||
f32 yaw;
|
||||
|
||||
if (isInitialCall) {
|
||||
D_802BFF00 = (D_802BFF0C == 0) ? 3 : 0;
|
||||
partner_init_put_away(partner);
|
||||
partner_init_put_away(lakilester);
|
||||
func_802BD7DC();
|
||||
playerStatus->animFlags &= ~0x400000;
|
||||
playerStatus->flags |= 0x100;
|
||||
playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_400000;
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_100;
|
||||
}
|
||||
|
||||
switch (D_802BFF00) {
|
||||
@ -567,24 +563,24 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
func_802BD7DC();
|
||||
yaw = cam->currentYaw;
|
||||
if ((playerStatus->spriteFacingAngle >= 90.0f) && (playerStatus->spriteFacingAngle < 270.0f)) {
|
||||
partner->yaw = (yaw + 180.0f) - 90.0f;
|
||||
lakilester->yaw = (yaw + 180.0f) - 90.0f;
|
||||
} else {
|
||||
partner->yaw = (yaw + 0.0f) - 90.0f;
|
||||
lakilester->yaw = (yaw + 0.0f) - 90.0f;
|
||||
}
|
||||
|
||||
sp2C = dist2D(playerStatus->position.x, playerStatus->position.z,
|
||||
partner->moveToPos.x, partner->moveToPos.z);
|
||||
partner->duration = 14;
|
||||
lakilester->moveToPos.x, lakilester->moveToPos.z);
|
||||
lakilester->duration = 14;
|
||||
|
||||
if (partner->moveToPos.y > partner->pos.y ) {
|
||||
partner->jumpVelocity = (partner->moveToPos.y - partner->pos.y) / 14.0f + 6.0f;
|
||||
if (lakilester->moveToPos.y > lakilester->pos.y ) {
|
||||
lakilester->jumpVelocity = (lakilester->moveToPos.y - lakilester->pos.y) / 14.0f + 6.0f;
|
||||
} else {
|
||||
partner->jumpVelocity = 6.0f;
|
||||
lakilester->jumpVelocity = 6.0f;
|
||||
}
|
||||
partner->jumpScale = 1.2f;
|
||||
partner->moveSpeed = sp2C / partner->duration;
|
||||
partner->yaw = atan2(playerStatus->position.x, playerStatus->position.z,
|
||||
partner->moveToPos.x, partner->moveToPos.z);
|
||||
lakilester->jumpScale = 1.2f;
|
||||
lakilester->moveSpeed = sp2C / lakilester->duration;
|
||||
lakilester->yaw = atan2(playerStatus->position.x, playerStatus->position.z,
|
||||
lakilester->moveToPos.x, lakilester->moveToPos.z);
|
||||
suggest_player_anim_clearUnkFlag(0x10006);
|
||||
D_802BFF00++;
|
||||
break;
|
||||
@ -592,15 +588,15 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
suggest_player_anim_clearUnkFlag(0x10007);
|
||||
D_802BFF00++;
|
||||
case 2:
|
||||
playerStatus->position.y += partner->jumpVelocity;
|
||||
partner->jumpVelocity -= partner->jumpScale;
|
||||
playerStatus->position.y += lakilester->jumpVelocity;
|
||||
lakilester->jumpVelocity -= lakilester->jumpScale;
|
||||
add_vec2D_polar(&playerStatus->position.x, &playerStatus->position.z,
|
||||
partner->moveSpeed, partner->yaw);
|
||||
lakilester->moveSpeed, lakilester->yaw);
|
||||
func_800E4AD8(0);
|
||||
if (partner->jumpVelocity <= 0.0f) {
|
||||
playerStatus->flags |= 4;
|
||||
if (partner->jumpVelocity < -10.0) {
|
||||
partner->jumpVelocity = -10.0f;
|
||||
if (lakilester->jumpVelocity <= 0.0f) {
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_FALLING;
|
||||
if (lakilester->jumpVelocity < -10.0) {
|
||||
lakilester->jumpVelocity = -10.0f;
|
||||
}
|
||||
}
|
||||
sp20 = playerStatus->position.x;
|
||||
@ -608,7 +604,7 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
sp28 = playerStatus->position.z;
|
||||
sp2C = playerStatus->colliderHeight;
|
||||
if (npc_raycast_down_ahead(0, &sp20, &sp24, &sp28, &sp2C,
|
||||
partner->yaw, partner->collisionRadius)) {
|
||||
lakilester->yaw, lakilester->collisionRadius)) {
|
||||
|
||||
D_802BFF00 = 3;
|
||||
playerStatus->position.y = sp24;
|
||||
@ -622,48 +618,55 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
|
||||
switch (D_802BFF00) {
|
||||
case 3:
|
||||
partner->flags &= ~0x48;
|
||||
lakilester->flags &= ~(NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT);
|
||||
|
||||
if (D_802BFF08) {
|
||||
D_802BFF08 = FALSE;
|
||||
enable_player_static_collisions();
|
||||
}
|
||||
|
||||
enable_player_shadow();
|
||||
if (playerStatus->flags & 0x800) {
|
||||
|
||||
if (playerStatus->flags & PLAYER_STATUS_FLAGS_800) {
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
if (D_802BFF04) {
|
||||
D_802BFF04 = FALSE;
|
||||
enable_player_input();
|
||||
}
|
||||
|
||||
gGameStatusPtr->unk_7D = 0;
|
||||
D_802BFF0C = 0;
|
||||
partner_clear_player_tracking(partner);
|
||||
partner_clear_player_tracking(lakilester);
|
||||
set_action_state(ACTION_STATE_HIT_FIRE);
|
||||
return ApiStatus_DONE1;
|
||||
}
|
||||
|
||||
if (D_802BFF0C == 0) {
|
||||
phys_main_collision_below();
|
||||
} else {
|
||||
set_action_state(ACTION_STATE_FALLING);
|
||||
gravity_use_fall_parms();
|
||||
}
|
||||
|
||||
D_802BFF00++;
|
||||
break;
|
||||
case 4:
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
playerStatus->flags &= -0x101;
|
||||
playerStatus->flags &= ~PLAYER_STATUS_FLAGS_100;
|
||||
|
||||
if (D_802BFF04) {
|
||||
D_802BFF04 = FALSE;
|
||||
enable_player_input();
|
||||
}
|
||||
gGameStatusPtr->unk_7D = 0;
|
||||
D_802BFF0C = 0;
|
||||
partner_clear_player_tracking(partner);
|
||||
partner_clear_player_tracking(lakilester);
|
||||
D_802BFF00++;
|
||||
break;
|
||||
case 5:
|
||||
if (partner_put_away(partner) == FALSE) {
|
||||
if (partner_put_away(lakilester) == FALSE) {
|
||||
break;
|
||||
}
|
||||
return ApiStatus_DONE1;
|
||||
@ -674,7 +677,7 @@ ApiStatus func_802BF4F0_323040(Evt* script, s32 isInitialCall) {
|
||||
void func_802BFA00_323550(Npc* npc) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (D_802BFF0C != 0) {
|
||||
if (D_802BFF0C) {
|
||||
partnerActionStatus->npc = *npc;
|
||||
partnerActionStatus->actionState.b[1] = 1;
|
||||
enable_player_static_collisions();
|
||||
@ -691,7 +694,7 @@ void func_802BFAA8_3235F8(Npc* npc) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (partnerActionStatus->actionState.b[1] != 0) {
|
||||
if (D_802BFF0C != 0) {
|
||||
if (D_802BFF0C) {
|
||||
*npc = partnerActionStatus->npc;
|
||||
gGameStatusPtr->unk_7D = 1;
|
||||
set_action_state(ACTION_STATE_RIDE);
|
||||
@ -714,9 +717,7 @@ s32 func_802BFBA0_3236F0(Evt* script, s32 isInitialCall) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
Npc* npc = get_npc_unsafe(NPC_PARTNER);
|
||||
f32 temp_f0;
|
||||
f32 temp_f2;
|
||||
f32 temp_f4;
|
||||
f32 temp_f0, temp_f2, temp_f4;
|
||||
f32* temp_s0_2;
|
||||
s32 temp_v0_2;
|
||||
s32 tempVar;
|
||||
@ -763,10 +764,10 @@ s32 func_802BFBA0_3236F0(Evt* script, s32 isInitialCall) {
|
||||
sfx_play_sound_at_npc(0x295, 0, -4);
|
||||
playerStatus->anim = 0x8000E;
|
||||
playerStatus->unk_BC = 0;
|
||||
playerStatus->flags |= 0x10000000;
|
||||
playerStatus->flags |= PLAYER_STATUS_FLAGS_10000000;
|
||||
func_802BFB44_323694(2.0f);
|
||||
gGameStatusPtr->unk_7D = 1;
|
||||
npc->flags |= 0x100;
|
||||
npc->flags |= NPC_FLAG_100;
|
||||
npc->moveSpeed = *temp_s0_2;
|
||||
npc->jumpScale = 0.0f;
|
||||
D_802BFF10 = 0;
|
||||
|
@ -1,58 +1,77 @@
|
||||
#include "common.h"
|
||||
#include "../src/world/partners.h"
|
||||
|
||||
extern struct unkPartnerStruct* D_802BEAAC_31B01C;
|
||||
extern s32 D_802BEBC0_31CBE0;
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BD100_319670);
|
||||
extern s32 D_802BEBB0;
|
||||
extern s32 D_802BEBB4;
|
||||
extern s32 D_802BEBB8;
|
||||
extern s32 D_802BEBBC;
|
||||
extern s32 D_802BEBC4;
|
||||
|
||||
ApiStatus func_802BD148_3196B8(Evt* script, s32 isInitialCall) {
|
||||
Npc* unk = script->owner2.npc; // todo what is this
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(unk);
|
||||
}
|
||||
return partner_get_out(unk) != 0;
|
||||
void func_802BD100_319670(Npc* parakarry) {
|
||||
parakarry->collisionHeight = 37;
|
||||
parakarry->collisionRadius = 40;
|
||||
D_802BEBB0 = 0;
|
||||
D_802BEBC0_31CBE0 = 0;
|
||||
D_802BEBB4 = 0;
|
||||
D_802BEBB8 = 0;
|
||||
D_802BEBBC = 0;
|
||||
D_802BEBC4 = 0;
|
||||
}
|
||||
|
||||
s32 func_802BD180_3196F0(Evt* evt, s32 arg1) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Entity* temp_s2;
|
||||
Npc* npc;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
ApiStatus func_802BD148_3196B8(Evt* script, s32 isInitialCall) {
|
||||
Npc* parakarry = script->owner2.npc;
|
||||
|
||||
npc = evt->owner2.npc;
|
||||
if (arg1 != 0) {
|
||||
partner_flying_enable(npc, 1);
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(parakarry);
|
||||
}
|
||||
|
||||
return partner_get_out(parakarry) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BD180_3196F0(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Entity* entity;
|
||||
Npc* parakarry = script->owner2.npc;
|
||||
f32 sp10, sp14, tempY;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_flying_enable(parakarry, 1);
|
||||
mem_clear(D_802BEAAC_31B01C, sizeof(*D_802BEAAC_31B01C));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
|
||||
playerData->unk_2F4[4]++;
|
||||
temp_s2 = D_8010C954;
|
||||
if (temp_s2 == NULL) {
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
return 0;
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_flying_update_player_tracking(parakarry);
|
||||
partner_flying_update_motion(parakarry);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BEAAC_31B01C->unk_04) {
|
||||
case 0:
|
||||
D_802BEAAC_31B01C->unk_04 = 1;
|
||||
D_802BEAAC_31B01C->unk_08 = npc->flags;
|
||||
D_802BEAAC_31B01C->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, temp_s2->position.x, temp_s2->position.z));
|
||||
D_802BEAAC_31B01C->unk_10 = atan2(temp_s2->position.x, temp_s2->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BEAAC_31B01C->flags = parakarry->flags;
|
||||
D_802BEAAC_31B01C->unk_0C = fabsf(dist2D(parakarry->pos.x, parakarry->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BEAAC_31B01C->unk_10 = atan2(entity->position.x, entity->position.z,
|
||||
parakarry->pos.x, parakarry->pos.z);
|
||||
D_802BEAAC_31B01C->unk_14 = 6.0f;
|
||||
D_802BEAAC_31B01C->unk_18 = 50.0f;
|
||||
D_802BEAAC_31B01C->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BEAAC_31B01C->unk_00 = 120;
|
||||
parakarry->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
parakarry->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BEAAC_31B01C->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = temp_s2->position.x + (sp10 * D_802BEAAC_31B01C->unk_0C);
|
||||
npc->pos.z = temp_s2->position.z - (sp14 * D_802BEAAC_31B01C->unk_0C);
|
||||
|
||||
parakarry->pos.x = entity->position.x + (sp10 * D_802BEAAC_31B01C->unk_0C);
|
||||
parakarry->pos.z = entity->position.z - (sp14 * D_802BEAAC_31B01C->unk_0C);
|
||||
D_802BEAAC_31B01C->unk_10 = clamp_angle(D_802BEAAC_31B01C->unk_10 - D_802BEAAC_31B01C->unk_14);
|
||||
|
||||
if (D_802BEAAC_31B01C->unk_0C > 20.0f) {
|
||||
D_802BEAAC_31B01C->unk_0C--;
|
||||
} else if (D_802BEAAC_31B01C->unk_0C < 19.0f) {
|
||||
@ -60,16 +79,16 @@ s32 func_802BD180_3196F0(Evt* evt, s32 arg1) {
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BEAAC_31B01C->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
|
||||
D_802BEAAC_31B01C->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BEAAC_31B01C->unk_18 > 150.0f) {
|
||||
D_802BEAAC_31B01C->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BEAAC_31B01C->unk_10);
|
||||
parakarry->pos.y += tempY;
|
||||
parakarry->renderYaw = clamp_angle(360.0f - D_802BEAAC_31B01C->unk_10);
|
||||
D_802BEAAC_31B01C->unk_14 += 0.8;
|
||||
|
||||
if (D_802BEAAC_31B01C->unk_14 > 40.0f) {
|
||||
D_802BEAAC_31B01C->unk_14 = 40.0f;
|
||||
}
|
||||
@ -79,13 +98,13 @@ s32 func_802BD180_3196F0(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BEAAC_31B01C->unk_08;
|
||||
D_802BEAAC_31B01C->unk_00 = 0x1E;
|
||||
parakarry->flags = D_802BEAAC_31B01C->flags;
|
||||
D_802BEAAC_31B01C->unk_00 = 30;
|
||||
D_802BEAAC_31B01C->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(parakarry);
|
||||
partner_flying_update_motion(parakarry);
|
||||
|
||||
if (--D_802BEAAC_31B01C->unk_00 == 0) {
|
||||
D_802BEAAC_31B01C->unk_04 = 0;
|
||||
@ -93,24 +112,89 @@ s32 func_802BD180_3196F0(Evt* evt, s32 arg1) {
|
||||
}
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BD514_319A84);
|
||||
void func_802BD514_319A84(Npc* parakarry) {
|
||||
if (D_8010C954) {
|
||||
D_8010C954 = 0;
|
||||
parakarry->flags = D_802BEAAC_31B01C->flags;
|
||||
D_802BEAAC_31B01C->unk_04 = 0;
|
||||
partner_clear_player_tracking (parakarry);
|
||||
}
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BD558_319AC8);
|
||||
s32 func_802BD558_319AC8(void) {
|
||||
f32 sp28, sp2C, sp30, sp34, sp38, sp3C, sp40, sp44;
|
||||
f32 colliderBaseHeight = gPlayerStatus.colliderHeight;
|
||||
s32 raycastResult;
|
||||
|
||||
sp28 = gPlayerStatus.position.x;
|
||||
sp2C = gPlayerStatus.position.y + (colliderBaseHeight * 0.5);
|
||||
sp30 = gPlayerStatus.position.z;
|
||||
sp34 = colliderBaseHeight * 0.5f;
|
||||
|
||||
raycastResult = player_raycast_below_cam_relative(&gPlayerStatus, &sp28, &sp2C, &sp30, &sp34, &sp38,
|
||||
&sp3C, &sp40, &sp44);
|
||||
|
||||
if (((get_collider_type_by_id(raycastResult) & 0xFF) - 2) < 2U) {
|
||||
gPlayerStatus.unk_BF = 2;
|
||||
D_802BEBC0_31CBE0 = 0x15;
|
||||
gPlayerStatus.flags |= PLAYER_STATUS_FLAGS_800;
|
||||
}
|
||||
|
||||
return raycastResult;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BD660_319BD0);
|
||||
|
||||
ApiStatus func_802BE8D4_31AE44(Evt* script, s32 isInitialCall) {
|
||||
s32 unk = script->owner2.npc; // todo what is this
|
||||
Npc* parakarry = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(unk);
|
||||
partner_init_put_away(parakarry);
|
||||
}
|
||||
return partner_put_away(unk) != 0;
|
||||
|
||||
return partner_put_away(parakarry) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BE90C_31AE7C);
|
||||
void func_802BE90C_31AE7C(Npc* parakarry) {
|
||||
PartnerActionStatus* parakarryActionStatus = &gPartnerActionStatus;
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/parakarry", func_802BE9D0_31AF40);
|
||||
if (D_802BEBB0) {
|
||||
if (D_802BEBB8) {
|
||||
enable_player_static_collisions();
|
||||
}
|
||||
|
||||
if (D_802BEBB4) {
|
||||
enable_player_input();
|
||||
}
|
||||
|
||||
set_action_state(ACTION_STATE_IDLE);
|
||||
parakarryActionStatus->npc = *parakarry;
|
||||
parakarryActionStatus->actionState.b[1] = 1;
|
||||
partner_clear_player_tracking(parakarry);
|
||||
}
|
||||
|
||||
parakarryActionStatus->actionState.b[3] = 4;
|
||||
}
|
||||
|
||||
void func_802BE9D0_31AF40(Npc* parakarry) {
|
||||
PartnerActionStatus* parakarryActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (parakarryActionStatus->actionState.b[1] != 0) {
|
||||
if (D_802BEBB8) {
|
||||
disable_player_static_collisions();
|
||||
}
|
||||
if (D_802BEBB4) {
|
||||
disable_player_input();
|
||||
}
|
||||
|
||||
set_action_state(ACTION_STATE_RIDE);
|
||||
*parakarry = parakarryActionStatus->npc;
|
||||
parakarryActionStatus->actionState.b[3] = 0;
|
||||
parakarryActionStatus->actionState.b[0] = 0;
|
||||
partner_clear_player_tracking(parakarry);
|
||||
partner_use_ability();
|
||||
}
|
||||
}
|
||||
|
@ -7,7 +7,6 @@ extern unkPartnerStruct* D_802BFDF8_320B68;
|
||||
extern s32 D_802BFEEC;
|
||||
extern f32 D_802BFEE0;
|
||||
void func_802BD368_31E0D8(s32, f32, f32, f32, f32, f32);
|
||||
s32 partner_use_ability(void);
|
||||
void partner_kill_ability_script(void);
|
||||
extern s32 D_802BFEE4;
|
||||
extern s32 D_802BFEE8;
|
||||
@ -35,7 +34,8 @@ void func_802BD100_31DE70(void) {
|
||||
phi_v1 = 8;
|
||||
}
|
||||
|
||||
playerStatus->position.z -= cos_rad((((cam->currentYaw + playerStatus->spriteFacingAngle) - 90.0f) + phi_v1) * TAU / 360.0f) * -4.0f;
|
||||
playerStatus->position.z -= cos_rad((cam->currentYaw + playerStatus->spriteFacingAngle - 90.0f + phi_v1) *
|
||||
TAU / 360.0f) * -4.0f;
|
||||
}
|
||||
|
||||
void func_802BD20C_31DF7C(f32* arg0, f32* arg1) {
|
||||
@ -100,10 +100,10 @@ s32 func_802BE280_31EFF0(s32 arg0, f32* arg1, f32* arg2, f32* arg3, f32 arg4, f3
|
||||
|
||||
INCLUDE_ASM(s32, "world/partner/sushie", func_802BE3A4_31F114);
|
||||
|
||||
void func_802BF520_320290(Npc* npc) {
|
||||
npc->collisionHeight = 24;
|
||||
npc->collisionRadius = 36;
|
||||
npc->unk_80 = 0x10000;
|
||||
void func_802BF520_320290(Npc* sushie) {
|
||||
sushie->collisionHeight = 24;
|
||||
sushie->collisionRadius = 36;
|
||||
sushie->unk_80 = 0x10000;
|
||||
D_802BFEEC = 0;
|
||||
D_802BFEE4 = 0;
|
||||
D_802BFEE8 = 0;
|
||||
@ -112,28 +112,22 @@ void func_802BF520_320290(Npc* npc) {
|
||||
}
|
||||
|
||||
s32 func_802BF568_3202D8(Evt* script, s32 isInitialCall) {
|
||||
Npc* npc = script->owner2.npc;
|
||||
Npc* sushie = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(npc);
|
||||
partner_init_get_out(sushie);
|
||||
}
|
||||
|
||||
if (partner_get_out(npc)) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
return partner_get_out(sushie) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus func_802BF5A0_320310(Evt* evt, s32 isInitialCall) {
|
||||
Npc* npc = evt->owner2.npc;
|
||||
ApiStatus func_802BF5A0_320310(Evt* script, s32 isInitialCall) {
|
||||
Npc* sushie = script->owner2.npc;
|
||||
Entity* entity;
|
||||
f32 sp10;
|
||||
f32 sp14;
|
||||
f32 tempY;
|
||||
f32 sp10, sp14, tempY;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_walking_enable(npc, 1);
|
||||
partner_walking_enable(sushie, 1);
|
||||
mem_clear(D_802BFDF8_320B68, sizeof(*D_802BFDF8_320B68));
|
||||
D_8010C954 = 0;
|
||||
}
|
||||
@ -141,29 +135,29 @@ ApiStatus func_802BF5A0_320310(Evt* evt, s32 isInitialCall) {
|
||||
entity = D_8010C954;
|
||||
|
||||
if (entity == NULL) {
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
partner_walking_update_player_tracking(sushie);
|
||||
partner_walking_update_motion(sushie);
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
switch (D_802BFDF8_320B68->unk_04) {
|
||||
case 0:
|
||||
D_802BFDF8_320B68->unk_04 = 1;
|
||||
D_802BFDF8_320B68->unk_08 = npc->flags;
|
||||
D_802BFDF8_320B68->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BFDF8_320B68->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BFDF8_320B68->flags = sushie->flags;
|
||||
D_802BFDF8_320B68->unk_0C = fabsf(dist2D(sushie->pos.x, sushie->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BFDF8_320B68->unk_10 = atan2(entity->position.x, entity->position.z, sushie->pos.x, sushie->pos.z);
|
||||
D_802BFDF8_320B68->unk_14 = 6.0f;
|
||||
D_802BFDF8_320B68->unk_18 = 50.0f;
|
||||
D_802BFDF8_320B68->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BFDF8_320B68->unk_00 = 120;
|
||||
sushie->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
sushie->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BFDF8_320B68->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
|
||||
npc->pos.x = entity->position.x + (sp10 * D_802BFDF8_320B68->unk_0C);
|
||||
npc->pos.z = entity->position.z - (sp14 * D_802BFDF8_320B68->unk_0C);
|
||||
|
||||
sushie->pos.x = entity->position.x + (sp10 * D_802BFDF8_320B68->unk_0C);
|
||||
sushie->pos.z = entity->position.z - (sp14 * D_802BFDF8_320B68->unk_0C);
|
||||
D_802BFDF8_320B68->unk_10 = clamp_angle(D_802BFDF8_320B68->unk_10 - D_802BFDF8_320B68->unk_14);
|
||||
|
||||
if (D_802BFDF8_320B68->unk_0C > 20.0f) {
|
||||
D_802BFDF8_320B68->unk_0C--;
|
||||
} else if (D_802BFDF8_320B68->unk_0C < 19.0f) {
|
||||
@ -171,16 +165,16 @@ ApiStatus func_802BF5A0_320310(Evt* evt, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
tempY = sin_rad((D_802BFDF8_320B68->unk_18 * TAU) / 360.0f) * 3.0f;
|
||||
|
||||
D_802BFDF8_320B68->unk_18 += 3.0f;
|
||||
|
||||
if (D_802BFDF8_320B68->unk_18 > 150.0f) {
|
||||
D_802BFDF8_320B68->unk_18 = 150.0f;
|
||||
}
|
||||
npc->pos.y += tempY;
|
||||
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BFDF8_320B68->unk_10);
|
||||
sushie->pos.y += tempY;
|
||||
sushie->renderYaw = clamp_angle(360.0f - D_802BFDF8_320B68->unk_10);
|
||||
D_802BFDF8_320B68->unk_14 += 0.8;
|
||||
|
||||
if (D_802BFDF8_320B68->unk_14 > 40.0f) {
|
||||
D_802BFDF8_320B68->unk_14 = 40.0f;
|
||||
}
|
||||
@ -190,13 +184,13 @@ ApiStatus func_802BF5A0_320310(Evt* evt, s32 isInitialCall) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BFDF8_320B68->unk_08;
|
||||
D_802BFDF8_320B68->unk_00 = 0x1E;
|
||||
sushie->flags = D_802BFDF8_320B68->flags;
|
||||
D_802BFDF8_320B68->unk_00 = 30;
|
||||
D_802BFDF8_320B68->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_walking_update_player_tracking(npc);
|
||||
partner_walking_update_motion(npc);
|
||||
partner_walking_update_player_tracking(sushie);
|
||||
partner_walking_update_motion(sushie);
|
||||
|
||||
if (--D_802BFDF8_320B68->unk_00 == 0) {
|
||||
D_802BFDF8_320B68->unk_04 = 0;
|
||||
@ -208,49 +202,46 @@ ApiStatus func_802BF5A0_320310(Evt* evt, s32 isInitialCall) {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void func_802BF920_320690(Npc* npc) {
|
||||
void func_802BF920_320690(Npc* sushie) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
npc->flags = D_802BFDF8_320B68->unk_08;
|
||||
sushie->flags = D_802BFDF8_320B68->flags;
|
||||
D_802BFDF8_320B68->unk_04 = 0;
|
||||
partner_clear_player_tracking(npc);
|
||||
partner_clear_player_tracking(sushie);
|
||||
}
|
||||
}
|
||||
|
||||
s32 func_802BF964_3206D4(Evt* script, s32 isInitialCall) {
|
||||
Npc* npc = script->owner2.npc;
|
||||
Npc* sushie = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(npc);
|
||||
partner_init_put_away(sushie);
|
||||
gPlayerStatusPtr->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_400000;
|
||||
}
|
||||
|
||||
if (partner_put_away(npc)) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
return partner_put_away(sushie) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
void func_802BF9B8_320728(Npc* npc) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
void func_802BF9B8_320728(Npc* sushie) {
|
||||
PartnerActionStatus* sushieActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (D_802BFEEC != 0) {
|
||||
partnerActionStatus->npc = *npc;
|
||||
partnerActionStatus->actionState.b[1] = 1;
|
||||
if (D_802BFEEC) {
|
||||
sushieActionStatus->npc = *sushie;
|
||||
sushieActionStatus->actionState.b[1] = 1;
|
||||
enable_player_static_collisions();
|
||||
enable_player_input();
|
||||
set_action_state(0);
|
||||
partner_clear_player_tracking(npc);
|
||||
set_action_state(ACTION_STATE_IDLE);
|
||||
partner_clear_player_tracking(sushie);
|
||||
}
|
||||
|
||||
partnerActionStatus->actionState.b[3] = 7;
|
||||
sushieActionStatus->actionState.b[3] = 7;
|
||||
}
|
||||
|
||||
void func_802BFA58_3207C8(Npc* npc) {
|
||||
if (gPartnerActionStatus.actionState.b[1] != 0) {
|
||||
*npc = gPartnerActionStatus.npc;
|
||||
void func_802BFA58_3207C8(Npc* sushie) {
|
||||
PartnerActionStatus* sushieActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (sushieActionStatus->actionState.b[1] != 0) {
|
||||
*sushie = sushieActionStatus->npc;
|
||||
partner_use_ability();
|
||||
}
|
||||
}
|
||||
@ -276,7 +267,8 @@ s32 func_802BFAB8_320828(Evt* script, s32 isInitialCall) {
|
||||
partnerNPC->pos.x = playerStatus->position.x;
|
||||
partnerNPC->pos.z = playerStatus->position.z;
|
||||
partnerNPC->pos.y = playerStatus->position.y;
|
||||
func_802BD368_31E0D8(partnerNPC->unk_80, partnerNPC->pos.x, partnerNPC->pos.y, partnerNPC->pos.z, partnerNPC->yaw, partnerNPC->collisionRadius * 0.5f);
|
||||
func_802BD368_31E0D8(partnerNPC->unk_80, partnerNPC->pos.x, partnerNPC->pos.y, partnerNPC->pos.z,
|
||||
partnerNPC->yaw, partnerNPC->collisionRadius * 0.5f);
|
||||
partnerNPC->pos.y = D_802BFEE0 - (partnerNPC->collisionHeight * 0.5f);
|
||||
temp_f0 = atan2(partnerNPC->pos.x, partnerNPC->pos.z, script->varTable[1], script->varTable[3]);
|
||||
partnerNPC->currentAnim.w = 0x7000A;
|
||||
@ -291,7 +283,7 @@ s32 func_802BFAB8_320828(Evt* script, s32 isInitialCall) {
|
||||
disable_npc_shadow(partnerNPC);
|
||||
disable_player_shadow();
|
||||
|
||||
if (script->varTable[0xC] == 0) {
|
||||
if (script->varTable[12] == 0) {
|
||||
partner_kill_ability_script();
|
||||
} else {
|
||||
suggest_player_anim_setUnkFlag(0x8000F);
|
||||
@ -307,14 +299,16 @@ s32 func_802BFAB8_320828(Evt* script, s32 isInitialCall) {
|
||||
case 1:
|
||||
npc_move_heading(partnerNPC, partnerNPC->moveSpeed, partnerNPC->yaw);
|
||||
func_802BD100_31DE70();
|
||||
|
||||
if (!(script->functionTemp[1] & 3)) {
|
||||
playFX_23(0, partnerNPC->pos.x, partnerNPC->moveToPos.y + (partnerNPC->collisionHeight * 0.5f), partnerNPC->pos.z, 0);
|
||||
playFX_23(0, partnerNPC->pos.x, partnerNPC->moveToPos.y +
|
||||
(partnerNPC->collisionHeight * 0.5f), partnerNPC->pos.z, 0);
|
||||
}
|
||||
|
||||
script->functionTemp[1]--;
|
||||
if (script->functionTemp[1] == 0) {
|
||||
if (script->varTable[0xC] == funcTemp0) {
|
||||
set_action_state(0x21);
|
||||
if (script->varTable[12] == funcTemp0) {
|
||||
set_action_state(ACTION_STATE_RIDE);
|
||||
partner_use_ability();
|
||||
return ApiStatus_DONE2;
|
||||
}
|
||||
|
@ -2,30 +2,31 @@
|
||||
#include "../partners.h"
|
||||
#include "twink.h"
|
||||
|
||||
void world_twink_init(Npc* partner) {
|
||||
partner->collisionHeight = 20;
|
||||
partner->collisionRadius = 20;
|
||||
void world_twink_init(Npc* twink) {
|
||||
twink->collisionHeight = 20;
|
||||
twink->collisionRadius = 20;
|
||||
}
|
||||
|
||||
ApiStatus TwinkTakeOut(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* twink = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(owner);
|
||||
partner_init_get_out(twink);
|
||||
}
|
||||
return partner_get_out(owner) != 0;
|
||||
|
||||
return partner_get_out(twink) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
ApiStatus TwinkUpdate(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* twink = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_flying_enable(owner, TRUE);
|
||||
partner_flying_enable(twink, TRUE);
|
||||
}
|
||||
|
||||
partner_flying_update_player_tracking(owner);
|
||||
partner_flying_update_motion(owner);
|
||||
partner_flying_update_player_tracking(twink);
|
||||
partner_flying_update_motion(twink);
|
||||
playerData->unk_2F4[PARTNER_TWINK]++;
|
||||
|
||||
return ApiStatus_BLOCK;
|
||||
@ -36,12 +37,13 @@ ApiStatus TwinkUseAbility(Evt* script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
ApiStatus TwinkPutAway(Evt* script, s32 isInitialCall) {
|
||||
Npc* owner = script->owner2.npc;
|
||||
Npc* twink = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_put_away(owner);
|
||||
partner_init_put_away(twink);
|
||||
}
|
||||
return partner_put_away(owner) != 0;
|
||||
|
||||
return partner_put_away(twink) ? ApiStatus_DONE1 : ApiStatus_BLOCK;
|
||||
}
|
||||
|
||||
EvtSource world_twink_take_out = SCRIPT({
|
||||
|
@ -6,7 +6,6 @@
|
||||
void force_player_anim(s32 arg0);
|
||||
void func_802BE070_31DBE0(void);
|
||||
void partner_kill_ability_script(void);
|
||||
s32 partner_use_ability(void);
|
||||
void func_802BD1AC_31CD1C(s32 arg0);
|
||||
extern s32 D_802BE278_31DDE8;
|
||||
extern f64 D_802BE2F0_31DE60;
|
||||
@ -31,25 +30,15 @@ typedef struct unk_802BE310 {
|
||||
/* 0x0C */ unk_802BE310_C* unk_0C;
|
||||
} unk_802BE310; //size = 0x10
|
||||
|
||||
typedef struct unk_802BE274_31DDE4 {
|
||||
/* 0x00 */ s32 unk_00;
|
||||
/* 0x04 */ s32 unk_04;
|
||||
/* 0x08 */ s32 unk_08;
|
||||
/* 0x0C */ f32 unk_0C;
|
||||
/* 0x10 */ f32 unk_10;
|
||||
/* 0x14 */ f32 unk_14;
|
||||
/* 0x18 */ f32 unk_18;
|
||||
} unk_802BE274_31DDE4; //size = 0x1C
|
||||
|
||||
extern s32 D_802BE300;
|
||||
extern s32 D_802BE304;
|
||||
extern s32 D_802BE308;
|
||||
extern s32 D_802BE30C;
|
||||
extern unk_802BE310* D_802BE310;
|
||||
extern unk_802BE274_31DDE4* D_802BE274_31DDE4;
|
||||
extern unkPartnerStruct* D_802BE274_31DDE4;
|
||||
|
||||
void func_802BD100_31CC70(Npc* npc) {
|
||||
if (!(npc->flags & 2)) {
|
||||
if (!(npc->flags & NPC_FLAG_2)) {
|
||||
if (D_802BE310 == NULL) {
|
||||
D_802BE310 = (unk_802BE310*)playFX_73(0, npc->pos.x, npc->pos.y + 13.0f, npc->pos.z, 0.9f, 5, 0);
|
||||
}
|
||||
@ -77,31 +66,32 @@ void func_802BD23C_31CDAC(Npc* npc) {
|
||||
}
|
||||
|
||||
ApiStatus func_802BD27C_31CDEC(Evt* script, s32 isInitialCall) {
|
||||
Npc* npc = script->owner2.npc;
|
||||
Npc* watt = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
partner_init_get_out(npc);
|
||||
partner_init_get_out(watt);
|
||||
}
|
||||
|
||||
if (partner_get_out(npc) != 0) {
|
||||
if (partner_get_out(watt)) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
}
|
||||
|
||||
ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
ApiStatus func_802BD2B4_31CE24(Evt* script, s32 isInitialCall) {
|
||||
PlayerData* playerData = &gPlayerData;
|
||||
Entity* entity;
|
||||
Npc* watt = script->owner2.npc;
|
||||
f32 sp10, sp14;
|
||||
f32 new_var;
|
||||
f32 temp_f0;
|
||||
Npc* npc = script->owner2.npc;
|
||||
|
||||
|
||||
if (gPartnerActionStatus.actionState.b[1] == 0) {
|
||||
if (isInitialCall) {
|
||||
partner_flying_enable(npc, 1);
|
||||
mem_clear(D_802BE274_31DDE4, sizeof(unk_802BE274_31DDE4));
|
||||
partner_flying_enable(watt, 1);
|
||||
mem_clear(D_802BE274_31DDE4, sizeof(*D_802BE274_31DDE4));
|
||||
D_8010C954 = NULL;
|
||||
}
|
||||
|
||||
@ -109,25 +99,25 @@ ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
playerData->unk_2F4[6]++;
|
||||
|
||||
if (entity == NULL) {
|
||||
func_802BD100_31CC70(npc);
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
if (npc->moveSpeed != 0.0f) {
|
||||
func_802BD100_31CC70(watt);
|
||||
partner_flying_update_player_tracking(watt);
|
||||
partner_flying_update_motion(watt);
|
||||
if (watt->moveSpeed != 0.0f) {
|
||||
if (D_802BE278_31DDE8 == 0) {
|
||||
D_802BE278_31DDE8 = 1;
|
||||
func_802BD1AC_31CD1C(1);
|
||||
npc->currentAnim.w = 0x60003;
|
||||
watt->currentAnim.w = 0x60003;
|
||||
}
|
||||
} else if (D_802BE278_31DDE8 != 0) {
|
||||
D_802BE278_31DDE8 = 0;
|
||||
func_802BD1AC_31CD1C(0);
|
||||
npc->currentAnim.w = 0x60001;
|
||||
watt->currentAnim.w = 0x60001;
|
||||
}
|
||||
|
||||
if (D_802BE310 != NULL) {
|
||||
D_802BE310->unk_0C->unk_04 = npc->pos.x;
|
||||
D_802BE310->unk_0C->unk_08 = npc->pos.y + 13.0f;
|
||||
D_802BE310->unk_0C->unk_0C = npc->pos.z;
|
||||
D_802BE310->unk_0C->unk_04 = watt->pos.x;
|
||||
D_802BE310->unk_0C->unk_08 = watt->pos.y + 13.0f;
|
||||
D_802BE310->unk_0C->unk_0C = watt->pos.z;
|
||||
}
|
||||
|
||||
return 0;
|
||||
@ -136,18 +126,19 @@ ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
switch (D_802BE274_31DDE4->unk_04) {
|
||||
case 0:
|
||||
D_802BE274_31DDE4->unk_04 = 1;
|
||||
D_802BE274_31DDE4->unk_08 = npc->flags;
|
||||
D_802BE274_31DDE4->unk_0C = fabsf(dist2D(npc->pos.x, npc->pos.z, entity->position.x, entity->position.z));
|
||||
D_802BE274_31DDE4->unk_10 = atan2(entity->position.x, entity->position.z, npc->pos.x, npc->pos.z);
|
||||
D_802BE274_31DDE4->flags = watt->flags;
|
||||
D_802BE274_31DDE4->unk_0C = fabsf(dist2D(watt->pos.x, watt->pos.z,
|
||||
entity->position.x, entity->position.z));
|
||||
D_802BE274_31DDE4->unk_10 = atan2(entity->position.x, entity->position.z, watt->pos.x, watt->pos.z);
|
||||
D_802BE274_31DDE4->unk_14 = 6.0f;
|
||||
D_802BE274_31DDE4->unk_18 = 50.0f;
|
||||
D_802BE274_31DDE4->unk_00 = 0x78;
|
||||
npc->flags |= 0x40148;
|
||||
npc->flags &= ~0x200;
|
||||
D_802BE274_31DDE4->unk_00 = 120;
|
||||
watt->flags |= NPC_FLAG_40000 | NPC_FLAG_100 | NPC_FLAG_40 | NPC_FLAG_ENABLE_HIT_SCRIPT;
|
||||
watt->flags &= ~NPC_FLAG_GRAVITY;
|
||||
case 1:
|
||||
sin_cos_rad((D_802BE274_31DDE4->unk_10 * TAU) / 360.0f, &sp10, &sp14);
|
||||
npc->pos.x = (entity->position.x + (sp10 * D_802BE274_31DDE4->unk_0C));
|
||||
npc->pos.z = (entity->position.z - (sp14 * D_802BE274_31DDE4->unk_0C));
|
||||
watt->pos.x = (entity->position.x + (sp10 * D_802BE274_31DDE4->unk_0C));
|
||||
watt->pos.z = (entity->position.z - (sp14 * D_802BE274_31DDE4->unk_0C));
|
||||
D_802BE274_31DDE4->unk_10 = clamp_angle(D_802BE274_31DDE4->unk_10 - D_802BE274_31DDE4->unk_14);
|
||||
|
||||
if (D_802BE274_31DDE4->unk_0C > 20.0f) {
|
||||
@ -158,15 +149,14 @@ ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
|
||||
temp_f0 = sin_rad(D_802BE274_31DDE4->unk_18 * TAU / 360.0f);
|
||||
D_802BE274_31DDE4->unk_18 += 3.0f;
|
||||
|
||||
new_var = temp_f0 * 3.0f;
|
||||
|
||||
if (D_802BE274_31DDE4->unk_18 > 150.0f) {
|
||||
D_802BE274_31DDE4->unk_18 = 150.0f;
|
||||
}
|
||||
|
||||
npc->pos.y += new_var;
|
||||
npc->renderYaw = clamp_angle(360.0f - D_802BE274_31DDE4->unk_10);
|
||||
watt->pos.y += new_var;
|
||||
watt->renderYaw = clamp_angle(360.0f - D_802BE274_31DDE4->unk_10);
|
||||
D_802BE274_31DDE4->unk_14 += D_802BE2F0_31DE60;
|
||||
|
||||
if (D_802BE274_31DDE4->unk_14 > 40.0f) {
|
||||
@ -178,13 +168,13 @@ ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
npc->flags = D_802BE274_31DDE4->unk_08;
|
||||
D_802BE274_31DDE4->unk_00 = 0x1E;
|
||||
watt->flags = D_802BE274_31DDE4->flags;
|
||||
D_802BE274_31DDE4->unk_00 = 30;
|
||||
D_802BE274_31DDE4->unk_04++;
|
||||
break;
|
||||
case 3:
|
||||
partner_flying_update_player_tracking(npc);
|
||||
partner_flying_update_motion(npc);
|
||||
partner_flying_update_player_tracking(watt);
|
||||
partner_flying_update_motion(watt);
|
||||
if (--D_802BE274_31DDE4->unk_00 == 0) {
|
||||
D_802BE274_31DDE4->unk_04 = 0;
|
||||
D_8010C954 = NULL;
|
||||
@ -193,20 +183,20 @@ ApiStatus func_802BD2B4_31CE24(Evt *script, s32 isInitialCall) {
|
||||
}
|
||||
|
||||
if (D_802BE310 != 0) {
|
||||
D_802BE310->unk_0C->unk_04 = npc->pos.x;
|
||||
D_802BE310->unk_0C->unk_08 = npc->pos.y + 13.0f;
|
||||
D_802BE310->unk_0C->unk_0C = npc->pos.z;
|
||||
D_802BE310->unk_0C->unk_04 = watt->pos.x;
|
||||
D_802BE310->unk_0C->unk_08 = watt->pos.y + 13.0f;
|
||||
D_802BE310->unk_0C->unk_0C = watt->pos.z;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void func_802BD710_31D280(Npc* npc) {
|
||||
void func_802BD710_31D280(Npc* watt) {
|
||||
if (D_8010C954 != NULL) {
|
||||
D_8010C954 = NULL;
|
||||
npc->flags = D_802BE274_31DDE4->unk_08;
|
||||
watt->flags = D_802BE274_31DDE4->flags;
|
||||
D_802BE274_31DDE4->unk_04 = 0;
|
||||
partner_clear_player_tracking(npc);
|
||||
partner_clear_player_tracking(watt);
|
||||
}
|
||||
}
|
||||
|
||||
@ -214,50 +204,52 @@ INCLUDE_ASM(s32, "world/partner/watt", func_802BD754_31D2C4);
|
||||
|
||||
s32 func_802BDD0C_31D87C(Evt* script, s32 isInitialCall) {
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
Npc* npc = script->owner2.npc;
|
||||
PartnerActionStatus* wattActionStatus = &gPartnerActionStatus;
|
||||
Npc* watt = script->owner2.npc;
|
||||
|
||||
if (isInitialCall) {
|
||||
func_802BD180_31CCF0();
|
||||
partner_init_put_away(npc);
|
||||
partner_init_put_away(watt);
|
||||
force_player_anim(0x10002);
|
||||
partnerActionStatus->actionState.b[3] = 0;
|
||||
partnerActionStatus->actionState.b[0] = 0;
|
||||
playerStatus->animFlags = playerStatus->animFlags & ~3;
|
||||
wattActionStatus->actionState.b[3] = 0;
|
||||
wattActionStatus->actionState.b[0] = 0;
|
||||
playerStatus->animFlags &= ~(PLAYER_STATUS_ANIM_FLAGS_2 | PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT);
|
||||
gGameStatusPtr->unk_7D = 0;
|
||||
}
|
||||
|
||||
if (partner_put_away(npc) != 0) {
|
||||
if (partner_put_away(watt)) {
|
||||
return ApiStatus_DONE1;
|
||||
} else {
|
||||
return ApiStatus_BLOCK;
|
||||
}
|
||||
}
|
||||
|
||||
void func_802BDD9C_31D90C(Npc* npc) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
void func_802BDD9C_31D90C(Npc* watt) {
|
||||
PartnerActionStatus* wattActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (D_802BE30C != 0) {
|
||||
partnerActionStatus->npc = *npc;
|
||||
partnerActionStatus->actionState.b[1] = 1;
|
||||
partner_clear_player_tracking(npc);
|
||||
wattActionStatus->npc = *watt;
|
||||
wattActionStatus->actionState.b[1] = 1;
|
||||
partner_clear_player_tracking(watt);
|
||||
}
|
||||
|
||||
func_802BD180_31CCF0();
|
||||
}
|
||||
|
||||
void func_802BDE10_31D980(Npc* npc) {
|
||||
if (gPartnerActionStatus.actionState.b[1]) {
|
||||
*npc = gPartnerActionStatus.npc;
|
||||
void func_802BDE10_31D980(Npc* watt) {
|
||||
PartnerActionStatus* wattActionStatus = &gPartnerActionStatus;
|
||||
|
||||
if (wattActionStatus->actionState.b[1]) {
|
||||
*watt = wattActionStatus->npc;
|
||||
partner_use_ability();
|
||||
func_802BD100_31CC70(npc);
|
||||
func_802BD100_31CC70(watt);
|
||||
}
|
||||
}
|
||||
|
||||
ApiStatus func_802BDE88_31D9F8(Evt* script, s32 isInitialCall) {
|
||||
PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus;
|
||||
PartnerActionStatus* wattActionStatus = &gPartnerActionStatus;
|
||||
PlayerStatus* playerStatus = &gPlayerStatus;
|
||||
Npc* npc = get_npc_unsafe(NPC_PARTNER);
|
||||
Npc* watt = get_npc_unsafe(NPC_PARTNER);
|
||||
|
||||
if (isInitialCall) {
|
||||
script->functionTemp[0] = 0;
|
||||
@ -269,20 +261,21 @@ ApiStatus func_802BDE88_31D9F8(Evt* script, s32 isInitialCall) {
|
||||
partner_kill_ability_script();
|
||||
func_802BD180_31CCF0();
|
||||
} else {
|
||||
func_802BD100_31CC70(npc);
|
||||
func_802BD100_31CC70(watt);
|
||||
}
|
||||
|
||||
script->functionTemp[1] = script->varTable[4];
|
||||
playerStatus->targetYaw = atan2(playerStatus->position.x, playerStatus->position.z, script->varTable[1], script->varTable[3]);
|
||||
playerStatus->targetYaw = atan2(playerStatus->position.x, playerStatus->position.z,
|
||||
script->varTable[1], script->varTable[3]);
|
||||
playerStatus->heading = playerStatus->targetYaw;
|
||||
move_player(script->functionTemp[1], playerStatus->heading, *((f32*) &script->varTable[5]));
|
||||
func_802BE070_31DBE0();
|
||||
npc->flags &= ~0x200;
|
||||
npc->flags |= 0x100;
|
||||
playerStatus->animFlags |= 3;
|
||||
watt->flags &= ~NPC_FLAG_GRAVITY;
|
||||
watt->flags |= NPC_FLAG_100;
|
||||
playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_2 | PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT;
|
||||
gGameStatusPtr->unk_7D = 1;
|
||||
partnerActionStatus->actionState.b[0] = 1;
|
||||
partnerActionStatus->actionState.b[3] = 6;
|
||||
wattActionStatus->actionState.b[0] = 1;
|
||||
wattActionStatus->actionState.b[3] = 6;
|
||||
D_802BE308 = 0;
|
||||
script->functionTemp[0] += 1;
|
||||
break;
|
||||
@ -321,8 +314,7 @@ void func_802BE070_31DBE0(void) {
|
||||
Npc* new_var2;
|
||||
Camera* camera = gCameras;
|
||||
PlayerStatus* playerStatus;
|
||||
f32 temp;
|
||||
f32 temp_f20;
|
||||
f32 temp, temp_f20;
|
||||
f32 spriteFacingAngle;
|
||||
s32 phi_v1;
|
||||
|
||||
|
@ -43,6 +43,7 @@ s32 partner_init_get_out(Npc*);
|
||||
s32 partner_get_out(Npc*);
|
||||
s32 partner_init_put_away(Npc* partner);
|
||||
s32 partner_put_away(Npc* partner);
|
||||
s32 partner_use_ability(void);
|
||||
void partner_do_player_collision(Npc* partner);
|
||||
void partner_walking_follow_player(Npc* partner);
|
||||
s32 func_800EA52C(s32);
|
||||
|
@ -1,18 +0,0 @@
|
||||
.include "macro.inc"
|
||||
|
||||
.section .data
|
||||
|
||||
dlabel D_802BE880_3195D0
|
||||
.word 0x00000043, 0x00000001, func_802BD300_318050, 0x00000002, 0x00000000, 0x00000001, 0x00000000
|
||||
|
||||
dlabel D_802BE89C_3195EC
|
||||
.word 0x802BE940, 0x00000043, 0x00000001, func_802BD338_318088, 0x00000002, 0x00000000, 0x00000001, 0x00000000, 0x00000043, 0x00000001, func_802BD758_3184A8, 0x00000002, 0x00000000, 0x00000001, 0x00000000, 0x00000043, 0x00000001, func_802BE4E8_319238, 0x00000002, 0x00000000, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000
|
||||
|
||||
dlabel D_802BE900_319650
|
||||
.double 0.8
|
||||
|
||||
dlabel D_802BE908_319658
|
||||
.double 500.0
|
||||
|
||||
dlabel D_802BE910_319660
|
||||
.double 0.55, 0.0
|
@ -1,128 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD100_317E50
|
||||
/* 317E50 802BD100 27BDFFA8 */ addiu $sp, $sp, -0x58
|
||||
/* 317E54 802BD104 F7B40038 */ sdc1 $f20, 0x38($sp)
|
||||
/* 317E58 802BD108 4480A000 */ mtc1 $zero, $f20
|
||||
/* 317E5C 802BD10C F7BA0050 */ sdc1 $f26, 0x50($sp)
|
||||
/* 317E60 802BD110 3C0141F0 */ lui $at, 0x41f0
|
||||
/* 317E64 802BD114 4481D000 */ mtc1 $at, $f26
|
||||
/* 317E68 802BD118 F7B80048 */ sdc1 $f24, 0x48($sp)
|
||||
/* 317E6C 802BD11C 3C014234 */ lui $at, 0x4234
|
||||
/* 317E70 802BD120 4481C000 */ mtc1 $at, $f24
|
||||
/* 317E74 802BD124 F7B60040 */ sdc1 $f22, 0x40($sp)
|
||||
/* 317E78 802BD128 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 317E7C 802BD12C 4481B000 */ mtc1 $at, $f22
|
||||
/* 317E80 802BD130 AFB00030 */ sw $s0, 0x30($sp)
|
||||
/* 317E84 802BD134 0080802D */ daddu $s0, $a0, $zero
|
||||
/* 317E88 802BD138 AFBF0034 */ sw $ra, 0x34($sp)
|
||||
.L802BD13C:
|
||||
/* 317E8C 802BD13C C6020038 */ lwc1 $f2, 0x38($s0)
|
||||
/* 317E90 802BD140 C604003C */ lwc1 $f4, 0x3c($s0)
|
||||
/* 317E94 802BD144 C60C000C */ lwc1 $f12, 0xc($s0)
|
||||
/* 317E98 802BD148 C6000040 */ lwc1 $f0, 0x40($s0)
|
||||
/* 317E9C 802BD14C 46146300 */ add.s $f12, $f12, $f20
|
||||
/* 317EA0 802BD150 E7A20020 */ swc1 $f2, 0x20($sp)
|
||||
/* 317EA4 802BD154 E7A40024 */ swc1 $f4, 0x24($sp)
|
||||
/* 317EA8 802BD158 0C00A6C9 */ jal clamp_angle
|
||||
/* 317EAC 802BD15C E7A00028 */ swc1 $f0, 0x28($sp)
|
||||
/* 317EB0 802BD160 3C040010 */ lui $a0, 0x10
|
||||
/* 317EB4 802BD164 27A50020 */ addiu $a1, $sp, 0x20
|
||||
/* 317EB8 802BD168 E7BA0010 */ swc1 $f26, 0x10($sp)
|
||||
/* 317EBC 802BD16C E7A00014 */ swc1 $f0, 0x14($sp)
|
||||
/* 317EC0 802BD170 860200A8 */ lh $v0, 0xa8($s0)
|
||||
/* 317EC4 802BD174 27A60024 */ addiu $a2, $sp, 0x24
|
||||
/* 317EC8 802BD178 44820000 */ mtc1 $v0, $f0
|
||||
/* 317ECC 802BD17C 00000000 */ nop
|
||||
/* 317ED0 802BD180 46800020 */ cvt.s.w $f0, $f0
|
||||
/* 317ED4 802BD184 E7A00018 */ swc1 $f0, 0x18($sp)
|
||||
/* 317ED8 802BD188 860200A6 */ lh $v0, 0xa6($s0)
|
||||
/* 317EDC 802BD18C 27A70028 */ addiu $a3, $sp, 0x28
|
||||
/* 317EE0 802BD190 44820000 */ mtc1 $v0, $f0
|
||||
/* 317EE4 802BD194 00000000 */ nop
|
||||
/* 317EE8 802BD198 46800020 */ cvt.s.w $f0, $f0
|
||||
/* 317EEC 802BD19C 0C0376B9 */ jal npc_test_move_taller_with_slipping
|
||||
/* 317EF0 802BD1A0 E7A0001C */ swc1 $f0, 0x1c($sp)
|
||||
/* 317EF4 802BD1A4 14400006 */ bnez $v0, .L802BD1C0
|
||||
/* 317EF8 802BD1A8 00000000 */ nop
|
||||
/* 317EFC 802BD1AC 4618A500 */ add.s $f20, $f20, $f24
|
||||
/* 317F00 802BD1B0 4616A03C */ c.lt.s $f20, $f22
|
||||
/* 317F04 802BD1B4 00000000 */ nop
|
||||
/* 317F08 802BD1B8 4501FFE0 */ bc1t .L802BD13C
|
||||
/* 317F0C 802BD1BC 00000000 */ nop
|
||||
.L802BD1C0:
|
||||
/* 317F10 802BD1C0 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 317F14 802BD1C4 44810000 */ mtc1 $at, $f0
|
||||
/* 317F18 802BD1C8 00000000 */ nop
|
||||
/* 317F1C 802BD1CC 4614003E */ c.le.s $f0, $f20
|
||||
/* 317F20 802BD1D0 00000000 */ nop
|
||||
/* 317F24 802BD1D4 4500002F */ bc1f .L802BD294
|
||||
/* 317F28 802BD1D8 00000000 */ nop
|
||||
/* 317F2C 802BD1DC 46000686 */ mov.s $f26, $f0
|
||||
/* 317F30 802BD1E0 4480A000 */ mtc1 $zero, $f20
|
||||
/* 317F34 802BD1E4 3C0141F0 */ lui $at, 0x41f0
|
||||
/* 317F38 802BD1E8 4481C000 */ mtc1 $at, $f24
|
||||
/* 317F3C 802BD1EC 3C014234 */ lui $at, 0x4234
|
||||
/* 317F40 802BD1F0 4481B000 */ mtc1 $at, $f22
|
||||
.L802BD1F4:
|
||||
/* 317F44 802BD1F4 C6020038 */ lwc1 $f2, 0x38($s0)
|
||||
/* 317F48 802BD1F8 C604003C */ lwc1 $f4, 0x3c($s0)
|
||||
/* 317F4C 802BD1FC C60C000C */ lwc1 $f12, 0xc($s0)
|
||||
/* 317F50 802BD200 C6000040 */ lwc1 $f0, 0x40($s0)
|
||||
/* 317F54 802BD204 46146300 */ add.s $f12, $f12, $f20
|
||||
/* 317F58 802BD208 E7A20020 */ swc1 $f2, 0x20($sp)
|
||||
/* 317F5C 802BD20C E7A40024 */ swc1 $f4, 0x24($sp)
|
||||
/* 317F60 802BD210 0C00A6C9 */ jal clamp_angle
|
||||
/* 317F64 802BD214 E7A00028 */ swc1 $f0, 0x28($sp)
|
||||
/* 317F68 802BD218 3C040004 */ lui $a0, 4
|
||||
/* 317F6C 802BD21C 27A50020 */ addiu $a1, $sp, 0x20
|
||||
/* 317F70 802BD220 E7B80010 */ swc1 $f24, 0x10($sp)
|
||||
/* 317F74 802BD224 E7A00014 */ swc1 $f0, 0x14($sp)
|
||||
/* 317F78 802BD228 860200A8 */ lh $v0, 0xa8($s0)
|
||||
/* 317F7C 802BD22C 27A60024 */ addiu $a2, $sp, 0x24
|
||||
/* 317F80 802BD230 44820000 */ mtc1 $v0, $f0
|
||||
/* 317F84 802BD234 00000000 */ nop
|
||||
/* 317F88 802BD238 46800020 */ cvt.s.w $f0, $f0
|
||||
/* 317F8C 802BD23C E7A00018 */ swc1 $f0, 0x18($sp)
|
||||
/* 317F90 802BD240 860200A6 */ lh $v0, 0xa6($s0)
|
||||
/* 317F94 802BD244 27A70028 */ addiu $a3, $sp, 0x28
|
||||
/* 317F98 802BD248 44820000 */ mtc1 $v0, $f0
|
||||
/* 317F9C 802BD24C 00000000 */ nop
|
||||
/* 317FA0 802BD250 46800020 */ cvt.s.w $f0, $f0
|
||||
/* 317FA4 802BD254 0C0376B9 */ jal npc_test_move_taller_with_slipping
|
||||
/* 317FA8 802BD258 E7A0001C */ swc1 $f0, 0x1c($sp)
|
||||
/* 317FAC 802BD25C 14400006 */ bnez $v0, .L802BD278
|
||||
/* 317FB0 802BD260 00000000 */ nop
|
||||
/* 317FB4 802BD264 4616A500 */ add.s $f20, $f20, $f22
|
||||
/* 317FB8 802BD268 461AA03C */ c.lt.s $f20, $f26
|
||||
/* 317FBC 802BD26C 00000000 */ nop
|
||||
/* 317FC0 802BD270 4501FFE0 */ bc1t .L802BD1F4
|
||||
/* 317FC4 802BD274 00000000 */ nop
|
||||
.L802BD278:
|
||||
/* 317FC8 802BD278 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 317FCC 802BD27C 44810000 */ mtc1 $at, $f0
|
||||
/* 317FD0 802BD280 00000000 */ nop
|
||||
/* 317FD4 802BD284 4614003E */ c.le.s $f0, $f20
|
||||
/* 317FD8 802BD288 00000000 */ nop
|
||||
/* 317FDC 802BD28C 4501000A */ bc1t .L802BD2B8
|
||||
/* 317FE0 802BD290 00000000 */ nop
|
||||
.L802BD294:
|
||||
/* 317FE4 802BD294 3C038011 */ lui $v1, %hi(D_8010C978)
|
||||
/* 317FE8 802BD298 8C63C978 */ lw $v1, %lo(D_8010C978)($v1)
|
||||
/* 317FEC 802BD29C 04600006 */ bltz $v1, .L802BD2B8
|
||||
/* 317FF0 802BD2A0 30624000 */ andi $v0, $v1, 0x4000
|
||||
/* 317FF4 802BD2A4 10400004 */ beqz $v0, .L802BD2B8
|
||||
/* 317FF8 802BD2A8 00000000 */ nop
|
||||
/* 317FFC 802BD2AC 2404BFFF */ addiu $a0, $zero, -0x4001
|
||||
/* 318000 802BD2B0 0C044277 */ jal entity_interacts_with_current_partner
|
||||
/* 318004 802BD2B4 00642024 */ and $a0, $v1, $a0
|
||||
.L802BD2B8:
|
||||
/* 318008 802BD2B8 8FBF0034 */ lw $ra, 0x34($sp)
|
||||
/* 31800C 802BD2BC 8FB00030 */ lw $s0, 0x30($sp)
|
||||
/* 318010 802BD2C0 D7BA0050 */ ldc1 $f26, 0x50($sp)
|
||||
/* 318014 802BD2C4 D7B80048 */ ldc1 $f24, 0x48($sp)
|
||||
/* 318018 802BD2C8 D7B60040 */ ldc1 $f22, 0x40($sp)
|
||||
/* 31801C 802BD2CC D7B40038 */ ldc1 $f20, 0x38($sp)
|
||||
/* 318020 802BD2D0 03E00008 */ jr $ra
|
||||
/* 318024 802BD2D4 27BD0058 */ addiu $sp, $sp, 0x58
|
@ -1,14 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD2D8_318028
|
||||
/* 318028 802BD2D8 2402001C */ addiu $v0, $zero, 0x1c
|
||||
/* 31802C 802BD2DC A48200A8 */ sh $v0, 0xa8($a0)
|
||||
/* 318030 802BD2E0 24020018 */ addiu $v0, $zero, 0x18
|
||||
/* 318034 802BD2E4 A48200A6 */ sh $v0, 0xa6($a0)
|
||||
/* 318038 802BD2E8 3C01802C */ lui $at, %hi(D_802BE928)
|
||||
/* 31803C 802BD2EC AC20E928 */ sw $zero, %lo(D_802BE928)($at)
|
||||
/* 318040 802BD2F0 3C01802C */ lui $at, %hi(D_802BE924)
|
||||
/* 318044 802BD2F4 AC20E924 */ sw $zero, %lo(D_802BE924)($at)
|
||||
/* 318048 802BD2F8 03E00008 */ jr $ra
|
||||
/* 31804C 802BD2FC 00000000 */ nop
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD6DC_31842C
|
||||
/* 31842C 802BD6DC 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 318430 802BD6E0 3C058011 */ lui $a1, %hi(D_8010C954)
|
||||
/* 318434 802BD6E4 24A5C954 */ addiu $a1, $a1, %lo(D_8010C954)
|
||||
/* 318438 802BD6E8 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31843C 802BD6EC 8CA20000 */ lw $v0, ($a1)
|
||||
/* 318440 802BD6F0 10400008 */ beqz $v0, .L802BD714
|
||||
/* 318444 802BD6F4 00000000 */ nop
|
||||
/* 318448 802BD6F8 3C03802C */ lui $v1, %hi(D_802BE89C_3195EC)
|
||||
/* 31844C 802BD6FC 8C63E89C */ lw $v1, %lo(D_802BE89C_3195EC)($v1)
|
||||
/* 318450 802BD700 8C620008 */ lw $v0, 8($v1)
|
||||
/* 318454 802BD704 ACA00000 */ sw $zero, ($a1)
|
||||
/* 318458 802BD708 AC820000 */ sw $v0, ($a0)
|
||||
/* 31845C 802BD70C 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 318460 802BD710 AC600004 */ sw $zero, 4($v1)
|
||||
.L802BD714:
|
||||
/* 318464 802BD714 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 318468 802BD718 03E00008 */ jr $ra
|
||||
/* 31846C 802BD71C 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,6 +1,12 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
.section .rodata
|
||||
dlabel D_802BE908_319658
|
||||
.double 500.0
|
||||
|
||||
|
||||
.section .text
|
||||
glabel func_802BD758_3184A8
|
||||
/* 3184A8 802BD758 3C02800B */ lui $v0, %hi(gCurrentEncounter+0x8)
|
||||
/* 3184AC 802BD75C 80420F18 */ lb $v0, %lo(gCurrentEncounter+0x8)($v0)
|
||||
|
@ -1,122 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BE520_319270
|
||||
/* 319270 802BE520 3C02802C */ lui $v0, %hi(D_802BE928)
|
||||
/* 319274 802BE524 8C42E928 */ lw $v0, %lo(D_802BE928)($v0)
|
||||
/* 319278 802BE528 27BDFF90 */ addiu $sp, $sp, -0x70
|
||||
/* 31927C 802BE52C AFB00030 */ sw $s0, 0x30($sp)
|
||||
/* 319280 802BE530 AFBF0038 */ sw $ra, 0x38($sp)
|
||||
/* 319284 802BE534 AFB10034 */ sw $s1, 0x34($sp)
|
||||
/* 319288 802BE538 F7BE0068 */ sdc1 $f30, 0x68($sp)
|
||||
/* 31928C 802BE53C F7BC0060 */ sdc1 $f28, 0x60($sp)
|
||||
/* 319290 802BE540 F7BA0058 */ sdc1 $f26, 0x58($sp)
|
||||
/* 319294 802BE544 F7B80050 */ sdc1 $f24, 0x50($sp)
|
||||
/* 319298 802BE548 F7B60048 */ sdc1 $f22, 0x48($sp)
|
||||
/* 31929C 802BE54C F7B40040 */ sdc1 $f20, 0x40($sp)
|
||||
/* 3192A0 802BE550 14400003 */ bnez $v0, .L802BE560
|
||||
/* 3192A4 802BE554 0080802D */ daddu $s0, $a0, $zero
|
||||
/* 3192A8 802BE558 080AF9AF */ j .L802BE6BC
|
||||
/* 3192AC 802BE55C 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BE560:
|
||||
/* 3192B0 802BE560 84A200A8 */ lh $v0, 0xa8($a1)
|
||||
/* 3192B4 802BE564 3C013FE0 */ lui $at, 0x3fe0
|
||||
/* 3192B8 802BE568 44810800 */ mtc1 $at, $f1
|
||||
/* 3192BC 802BE56C 44800000 */ mtc1 $zero, $f0
|
||||
/* 3192C0 802BE570 44821000 */ mtc1 $v0, $f2
|
||||
/* 3192C4 802BE574 00000000 */ nop
|
||||
/* 3192C8 802BE578 468010A1 */ cvt.d.w $f2, $f2
|
||||
/* 3192CC 802BE57C 46201082 */ mul.d $f2, $f2, $f0
|
||||
/* 3192D0 802BE580 00000000 */ nop
|
||||
/* 3192D4 802BE584 84A200A6 */ lh $v0, 0xa6($a1)
|
||||
/* 3192D8 802BE588 3C01802C */ lui $at, %hi(D_802BE910_319660)
|
||||
/* 3192DC 802BE58C D420E910 */ ldc1 $f0, %lo(D_802BE910_319660)($at)
|
||||
/* 3192E0 802BE590 44823000 */ mtc1 $v0, $f6
|
||||
/* 3192E4 802BE594 00000000 */ nop
|
||||
/* 3192E8 802BE598 468031A1 */ cvt.d.w $f6, $f6
|
||||
/* 3192EC 802BE59C 46203182 */ mul.d $f6, $f6, $f0
|
||||
/* 3192F0 802BE5A0 00000000 */ nop
|
||||
/* 3192F4 802BE5A4 C4BA0038 */ lwc1 $f26, 0x38($a1)
|
||||
/* 3192F8 802BE5A8 C61C0038 */ lwc1 $f28, 0x38($s0)
|
||||
/* 3192FC 802BE5AC 461CD201 */ sub.s $f8, $f26, $f28
|
||||
/* 319300 802BE5B0 46084282 */ mul.s $f10, $f8, $f8
|
||||
/* 319304 802BE5B4 00000000 */ nop
|
||||
/* 319308 802BE5B8 C4A4003C */ lwc1 $f4, 0x3c($a1)
|
||||
/* 31930C 802BE5BC 462010A0 */ cvt.s.d $f2, $f2
|
||||
/* 319310 802BE5C0 46022100 */ add.s $f4, $f4, $f2
|
||||
/* 319314 802BE5C4 C600003C */ lwc1 $f0, 0x3c($s0)
|
||||
/* 319318 802BE5C8 46002101 */ sub.s $f4, $f4, $f0
|
||||
/* 31931C 802BE5CC 46042302 */ mul.s $f12, $f4, $f4
|
||||
/* 319320 802BE5D0 00000000 */ nop
|
||||
/* 319324 802BE5D4 C4B60040 */ lwc1 $f22, 0x40($a1)
|
||||
/* 319328 802BE5D8 C6180040 */ lwc1 $f24, 0x40($s0)
|
||||
/* 31932C 802BE5DC 4618B001 */ sub.s $f0, $f22, $f24
|
||||
/* 319330 802BE5E0 46000082 */ mul.s $f2, $f0, $f0
|
||||
/* 319334 802BE5E4 00000000 */ nop
|
||||
/* 319338 802BE5E8 3C01420C */ lui $at, 0x420c
|
||||
/* 31933C 802BE5EC 4481F000 */ mtc1 $at, $f30
|
||||
/* 319340 802BE5F0 460C5280 */ add.s $f10, $f10, $f12
|
||||
/* 319344 802BE5F4 E7A80020 */ swc1 $f8, 0x20($sp)
|
||||
/* 319348 802BE5F8 46203520 */ cvt.s.d $f20, $f6
|
||||
/* 31934C 802BE5FC 46025300 */ add.s $f12, $f10, $f2
|
||||
/* 319350 802BE600 E7A00028 */ swc1 $f0, 0x28($sp)
|
||||
/* 319354 802BE604 46006084 */ sqrt.s $f2, $f12
|
||||
/* 319358 802BE608 46021032 */ c.eq.s $f2, $f2
|
||||
/* 31935C 802BE60C 00000000 */ nop
|
||||
/* 319360 802BE610 45010004 */ bc1t .L802BE624
|
||||
/* 319364 802BE614 E7A40024 */ swc1 $f4, 0x24($sp)
|
||||
/* 319368 802BE618 0C0187BC */ jal sqrtf
|
||||
/* 31936C 802BE61C 00000000 */ nop
|
||||
/* 319370 802BE620 46000086 */ mov.s $f2, $f0
|
||||
.L802BE624:
|
||||
/* 319374 802BE624 461EA000 */ add.s $f0, $f20, $f30
|
||||
/* 319378 802BE628 4600103C */ c.lt.s $f2, $f0
|
||||
/* 31937C 802BE62C 00000000 */ nop
|
||||
/* 319380 802BE630 45000002 */ bc1f .L802BE63C
|
||||
/* 319384 802BE634 0000882D */ daddu $s1, $zero, $zero
|
||||
/* 319388 802BE638 24110001 */ addiu $s1, $zero, 1
|
||||
.L802BE63C:
|
||||
/* 31938C 802BE63C 4600D306 */ mov.s $f12, $f26
|
||||
/* 319390 802BE640 4406E000 */ mfc1 $a2, $f28
|
||||
/* 319394 802BE644 4407C000 */ mfc1 $a3, $f24
|
||||
/* 319398 802BE648 0C00A720 */ jal atan2
|
||||
/* 31939C 802BE64C 4600B386 */ mov.s $f14, $f22
|
||||
/* 3193A0 802BE650 4600D306 */ mov.s $f12, $f26
|
||||
/* 3193A4 802BE654 4600B386 */ mov.s $f14, $f22
|
||||
/* 3193A8 802BE658 4406E000 */ mfc1 $a2, $f28
|
||||
/* 3193AC 802BE65C 4407C000 */ mfc1 $a3, $f24
|
||||
/* 3193B0 802BE660 0C00A7B5 */ jal dist2D
|
||||
/* 3193B4 802BE664 46000506 */ mov.s $f20, $f0
|
||||
/* 3193B8 802BE668 27A60024 */ addiu $a2, $sp, 0x24
|
||||
/* 3193BC 802BE66C 27A70028 */ addiu $a3, $sp, 0x28
|
||||
/* 3193C0 802BE670 0000202D */ daddu $a0, $zero, $zero
|
||||
/* 3193C4 802BE674 C6020038 */ lwc1 $f2, 0x38($s0)
|
||||
/* 3193C8 802BE678 C604003C */ lwc1 $f4, 0x3c($s0)
|
||||
/* 3193CC 802BE67C C6060040 */ lwc1 $f6, 0x40($s0)
|
||||
/* 3193D0 802BE680 3C014000 */ lui $at, 0x4000
|
||||
/* 3193D4 802BE684 44814000 */ mtc1 $at, $f8
|
||||
/* 3193D8 802BE688 27A50020 */ addiu $a1, $sp, 0x20
|
||||
/* 3193DC 802BE68C E7A20020 */ swc1 $f2, 0x20($sp)
|
||||
/* 3193E0 802BE690 E7A40024 */ swc1 $f4, 0x24($sp)
|
||||
/* 3193E4 802BE694 E7A60028 */ swc1 $f6, 0x28($sp)
|
||||
/* 3193E8 802BE698 E7A00010 */ swc1 $f0, 0x10($sp)
|
||||
/* 3193EC 802BE69C E7B40014 */ swc1 $f20, 0x14($sp)
|
||||
/* 3193F0 802BE6A0 E7BE0018 */ swc1 $f30, 0x18($sp)
|
||||
/* 3193F4 802BE6A4 0C0376B9 */ jal npc_test_move_taller_with_slipping
|
||||
/* 3193F8 802BE6A8 E7A8001C */ swc1 $f8, 0x1c($sp)
|
||||
/* 3193FC 802BE6AC 0040182D */ daddu $v1, $v0, $zero
|
||||
/* 319400 802BE6B0 14600002 */ bnez $v1, .L802BE6BC
|
||||
/* 319404 802BE6B4 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 319408 802BE6B8 0220102D */ daddu $v0, $s1, $zero
|
||||
.L802BE6BC:
|
||||
/* 31940C 802BE6BC 8FBF0038 */ lw $ra, 0x38($sp)
|
||||
/* 319410 802BE6C0 8FB10034 */ lw $s1, 0x34($sp)
|
||||
/* 319414 802BE6C4 8FB00030 */ lw $s0, 0x30($sp)
|
||||
/* 319418 802BE6C8 D7BE0068 */ ldc1 $f30, 0x68($sp)
|
||||
/* 31941C 802BE6CC D7BC0060 */ ldc1 $f28, 0x60($sp)
|
||||
/* 319420 802BE6D0 D7BA0058 */ ldc1 $f26, 0x58($sp)
|
||||
/* 319424 802BE6D4 D7B80050 */ ldc1 $f24, 0x50($sp)
|
||||
/* 319428 802BE6D8 D7B60048 */ ldc1 $f22, 0x48($sp)
|
||||
/* 31942C 802BE6DC D7B40040 */ ldc1 $f20, 0x40($sp)
|
||||
/* 319430 802BE6E0 03E00008 */ jr $ra
|
||||
/* 319434 802BE6E4 27BD0070 */ addiu $sp, $sp, 0x70
|
@ -1,111 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BE6E8_319438
|
||||
/* 319438 802BE6E8 27BDFFD8 */ addiu $sp, $sp, -0x28
|
||||
/* 31943C 802BE6EC AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 319440 802BE6F0 0080802D */ daddu $s0, $a0, $zero
|
||||
/* 319444 802BE6F4 AFB10014 */ sw $s1, 0x14($sp)
|
||||
/* 319448 802BE6F8 3C118011 */ lui $s1, %hi(gPlayerStatus)
|
||||
/* 31944C 802BE6FC 2631EFC8 */ addiu $s1, $s1, %lo(gPlayerStatus)
|
||||
/* 319450 802BE700 3C028011 */ lui $v0, %hi(gPartnerActionStatus)
|
||||
/* 319454 802BE704 2442EBB0 */ addiu $v0, $v0, %lo(gPartnerActionStatus)
|
||||
/* 319458 802BE708 AFBF0020 */ sw $ra, 0x20($sp)
|
||||
/* 31945C 802BE70C AFB3001C */ sw $s3, 0x1c($sp)
|
||||
/* 319460 802BE710 AFB20018 */ sw $s2, 0x18($sp)
|
||||
/* 319464 802BE714 80430000 */ lb $v1, ($v0)
|
||||
/* 319468 802BE718 1060004F */ beqz $v1, .L802BE858
|
||||
/* 31946C 802BE71C 0040902D */ daddu $s2, $v0, $zero
|
||||
/* 319470 802BE720 3C02802C */ lui $v0, %hi(D_802BE92C)
|
||||
/* 319474 802BE724 8C42E92C */ lw $v0, %lo(D_802BE92C)($v0)
|
||||
/* 319478 802BE728 50400004 */ beql $v0, $zero, .L802BE73C
|
||||
/* 31947C 802BE72C 0000202D */ daddu $a0, $zero, $zero
|
||||
/* 319480 802BE730 0C038069 */ jal enable_player_input
|
||||
/* 319484 802BE734 00000000 */ nop
|
||||
/* 319488 802BE738 0000202D */ daddu $a0, $zero, $zero
|
||||
.L802BE73C:
|
||||
/* 31948C 802BE73C 8E220000 */ lw $v0, ($s1)
|
||||
/* 319490 802BE740 2403FFFD */ addiu $v1, $zero, -3
|
||||
/* 319494 802BE744 3C01802C */ lui $at, %hi(D_802BE928)
|
||||
/* 319498 802BE748 AC20E928 */ sw $zero, %lo(D_802BE928)($at)
|
||||
/* 31949C 802BE74C 00431024 */ and $v0, $v0, $v1
|
||||
/* 3194A0 802BE750 AE220000 */ sw $v0, ($s1)
|
||||
/* 3194A4 802BE754 8E020000 */ lw $v0, ($s0)
|
||||
/* 3194A8 802BE758 2403F7FF */ addiu $v1, $zero, -0x801
|
||||
/* 3194AC 802BE75C AE00001C */ sw $zero, 0x1c($s0)
|
||||
/* 3194B0 802BE760 00431024 */ and $v0, $v0, $v1
|
||||
/* 3194B4 802BE764 0C039769 */ jal set_action_state
|
||||
/* 3194B8 802BE768 AE020000 */ sw $v0, ($s0)
|
||||
/* 3194BC 802BE76C 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 3194C0 802BE770 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 3194C4 802BE774 C6200028 */ lwc1 $f0, 0x28($s1)
|
||||
/* 3194C8 802BE778 A2400000 */ sb $zero, ($s2)
|
||||
/* 3194CC 802BE77C A2400003 */ sb $zero, 3($s2)
|
||||
/* 3194D0 802BE780 3C02802C */ lui $v0, %hi(D_802BE920)
|
||||
/* 3194D4 802BE784 8C42E920 */ lw $v0, %lo(D_802BE920)($v0)
|
||||
/* 3194D8 802BE788 E6000038 */ swc1 $f0, 0x38($s0)
|
||||
/* 3194DC 802BE78C C620002C */ lwc1 $f0, 0x2c($s1)
|
||||
/* 3194E0 802BE790 26120038 */ addiu $s2, $s0, 0x38
|
||||
/* 3194E4 802BE794 E600003C */ swc1 $f0, 0x3c($s0)
|
||||
/* 3194E8 802BE798 C6200030 */ lwc1 $f0, 0x30($s1)
|
||||
/* 3194EC 802BE79C 26130040 */ addiu $s3, $s0, 0x40
|
||||
/* 3194F0 802BE7A0 14400006 */ bnez $v0, .L802BE7BC
|
||||
/* 3194F4 802BE7A4 E6000040 */ swc1 $f0, 0x40($s0)
|
||||
/* 3194F8 802BE7A8 C6200080 */ lwc1 $f0, 0x80($s1)
|
||||
/* 3194FC 802BE7AC 3C0142B4 */ lui $at, 0x42b4
|
||||
/* 319500 802BE7B0 44816000 */ mtc1 $at, $f12
|
||||
/* 319504 802BE7B4 080AF9F4 */ j .L802BE7D0
|
||||
/* 319508 802BE7B8 460C0300 */ add.s $f12, $f0, $f12
|
||||
.L802BE7BC:
|
||||
/* 31950C 802BE7BC C6200080 */ lwc1 $f0, 0x80($s1)
|
||||
/* 319510 802BE7C0 3C0142B4 */ lui $at, 0x42b4
|
||||
/* 319514 802BE7C4 44816000 */ mtc1 $at, $f12
|
||||
/* 319518 802BE7C8 00000000 */ nop
|
||||
/* 31951C 802BE7CC 460C0301 */ sub.s $f12, $f0, $f12
|
||||
.L802BE7D0:
|
||||
/* 319520 802BE7D0 0C00A6C9 */ jal clamp_angle
|
||||
/* 319524 802BE7D4 00000000 */ nop
|
||||
/* 319528 802BE7D8 862200B2 */ lh $v0, 0xb2($s1)
|
||||
/* 31952C 802BE7DC 04420001 */ bltzl $v0, .L802BE7E4
|
||||
/* 319530 802BE7E0 24420003 */ addiu $v0, $v0, 3
|
||||
.L802BE7E4:
|
||||
/* 319534 802BE7E4 0240202D */ daddu $a0, $s2, $zero
|
||||
/* 319538 802BE7E8 00021083 */ sra $v0, $v0, 2
|
||||
/* 31953C 802BE7EC 44821000 */ mtc1 $v0, $f2
|
||||
/* 319540 802BE7F0 00000000 */ nop
|
||||
/* 319544 802BE7F4 468010A0 */ cvt.s.w $f2, $f2
|
||||
/* 319548 802BE7F8 44070000 */ mfc1 $a3, $f0
|
||||
/* 31954C 802BE7FC 44061000 */ mfc1 $a2, $f2
|
||||
/* 319550 802BE800 0C00A7E7 */ jal add_vec2D_polar
|
||||
/* 319554 802BE804 0260282D */ daddu $a1, $s3, $zero
|
||||
/* 319558 802BE808 3C020003 */ lui $v0, 3
|
||||
/* 31955C 802BE80C 34420003 */ ori $v0, $v0, 3
|
||||
/* 319560 802BE810 AE00001C */ sw $zero, 0x1c($s0)
|
||||
/* 319564 802BE814 C620002C */ lwc1 $f0, 0x2c($s1)
|
||||
/* 319568 802BE818 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 31956C 802BE81C AE000044 */ sw $zero, 0x44($s0)
|
||||
/* 319570 802BE820 AE00004C */ sw $zero, 0x4c($s0)
|
||||
/* 319574 802BE824 AE020028 */ sw $v0, 0x28($s0)
|
||||
/* 319578 802BE828 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31957C 802BE82C E600003C */ swc1 $f0, 0x3c($s0)
|
||||
/* 319580 802BE830 0C00EB6B */ jal disable_npc_blur
|
||||
/* 319584 802BE834 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 319588 802BE838 3C03802C */ lui $v1, %hi(D_802BE924)
|
||||
/* 31958C 802BE83C 2463E924 */ addiu $v1, $v1, %lo(D_802BE924)
|
||||
/* 319590 802BE840 8C620000 */ lw $v0, ($v1)
|
||||
/* 319594 802BE844 10400004 */ beqz $v0, .L802BE858
|
||||
/* 319598 802BE848 00000000 */ nop
|
||||
/* 31959C 802BE84C AC600000 */ sw $zero, ($v1)
|
||||
/* 3195A0 802BE850 0C05271B */ jal sfx_stop_sound
|
||||
/* 3195A4 802BE854 3C048000 */ lui $a0, 0x8000
|
||||
.L802BE858:
|
||||
/* 3195A8 802BE858 8FBF0020 */ lw $ra, 0x20($sp)
|
||||
/* 3195AC 802BE85C 8FB3001C */ lw $s3, 0x1c($sp)
|
||||
/* 3195B0 802BE860 8FB20018 */ lw $s2, 0x18($sp)
|
||||
/* 3195B4 802BE864 8FB10014 */ lw $s1, 0x14($sp)
|
||||
/* 3195B8 802BE868 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 3195BC 802BE86C 03E00008 */ jr $ra
|
||||
/* 3195C0 802BE870 27BD0028 */ addiu $sp, $sp, 0x28
|
||||
/* 3195C4 802BE874 00000000 */ nop
|
||||
/* 3195C8 802BE878 00000000 */ nop
|
||||
/* 3195CC 802BE87C 00000000 */ nop
|
@ -1,23 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD188_3170A8
|
||||
/* 3170A8 802BD188 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 3170AC 802BD18C AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 3170B0 802BD190 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 3170B4 802BD194 8C90014C */ lw $s0, 0x14c($a0)
|
||||
/* 3170B8 802BD198 2402FFFF */ addiu $v0, $zero, -1
|
||||
/* 3170BC 802BD19C 3C01802C */ lui $at, %hi(D_802BDF60)
|
||||
/* 3170C0 802BD1A0 AC22DF60 */ sw $v0, %lo(D_802BDF60)($at)
|
||||
/* 3170C4 802BD1A4 10A00003 */ beqz $a1, .L802BD1B4
|
||||
/* 3170C8 802BD1A8 00000000 */ nop
|
||||
/* 3170CC 802BD1AC 0C03BB31 */ jal partner_init_get_out
|
||||
/* 3170D0 802BD1B0 0200202D */ daddu $a0, $s0, $zero
|
||||
.L802BD1B4:
|
||||
/* 3170D4 802BD1B4 0C03BB3A */ jal partner_get_out
|
||||
/* 3170D8 802BD1B8 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 3170DC 802BD1BC 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 3170E0 802BD1C0 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 3170E4 802BD1C4 0002102B */ sltu $v0, $zero, $v0
|
||||
/* 3170E8 802BD1C8 03E00008 */ jr $ra
|
||||
/* 3170EC 802BD1CC 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,254 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
.section .rodata
|
||||
|
||||
dlabel D_802BDE80_317DA0
|
||||
.double 0.8
|
||||
|
||||
.section .text
|
||||
|
||||
glabel func_802BD1D0_3170F0
|
||||
/* 3170F0 802BD1D0 27BDFFC8 */ addiu $sp, $sp, -0x38
|
||||
/* 3170F4 802BD1D4 AFB00018 */ sw $s0, 0x18($sp)
|
||||
/* 3170F8 802BD1D8 3C108011 */ lui $s0, %hi(gPlayerData)
|
||||
/* 3170FC 802BD1DC 2610F290 */ addiu $s0, $s0, %lo(gPlayerData)
|
||||
/* 317100 802BD1E0 AFBF0028 */ sw $ra, 0x28($sp)
|
||||
/* 317104 802BD1E4 AFB30024 */ sw $s3, 0x24($sp)
|
||||
/* 317108 802BD1E8 AFB20020 */ sw $s2, 0x20($sp)
|
||||
/* 31710C 802BD1EC AFB1001C */ sw $s1, 0x1c($sp)
|
||||
/* 317110 802BD1F0 F7B40030 */ sdc1 $f20, 0x30($sp)
|
||||
/* 317114 802BD1F4 8C91014C */ lw $s1, 0x14c($a0)
|
||||
/* 317118 802BD1F8 10A00009 */ beqz $a1, .L802BD220
|
||||
/* 31711C 802BD1FC 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 317120 802BD200 0C03AE2A */ jal partner_walking_enable
|
||||
/* 317124 802BD204 24050001 */ addiu $a1, $zero, 1
|
||||
/* 317128 802BD208 3C04802C */ lui $a0, %hi(D_802BDD88_317CA8)
|
||||
/* 31712C 802BD20C 8C84DD88 */ lw $a0, %lo(D_802BDD88_317CA8)($a0)
|
||||
/* 317130 802BD210 0C00A580 */ jal mem_clear
|
||||
/* 317134 802BD214 2405001C */ addiu $a1, $zero, 0x1c
|
||||
/* 317138 802BD218 3C018011 */ lui $at, %hi(D_8010C954)
|
||||
/* 31713C 802BD21C AC20C954 */ sw $zero, %lo(D_8010C954)($at)
|
||||
.L802BD220:
|
||||
/* 317140 802BD220 3C138011 */ lui $s3, %hi(D_8010C954)
|
||||
/* 317144 802BD224 2673C954 */ addiu $s3, $s3, %lo(D_8010C954)
|
||||
/* 317148 802BD228 8E0202F8 */ lw $v0, 0x2f8($s0)
|
||||
/* 31714C 802BD22C 8E720000 */ lw $s2, ($s3)
|
||||
/* 317150 802BD230 24420001 */ addiu $v0, $v0, 1
|
||||
/* 317154 802BD234 16400007 */ bnez $s2, .L802BD254
|
||||
/* 317158 802BD238 AE0202F8 */ sw $v0, 0x2f8($s0)
|
||||
/* 31715C 802BD23C 0C03AE8F */ jal partner_walking_update_player_tracking
|
||||
/* 317160 802BD240 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 317164 802BD244 0C03AED0 */ jal partner_walking_update_motion
|
||||
/* 317168 802BD248 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 31716C 802BD24C 080AF551 */ j .L802BD544
|
||||
/* 317170 802BD250 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD254:
|
||||
/* 317174 802BD254 3C10802C */ lui $s0, %hi(D_802BDD88_317CA8)
|
||||
/* 317178 802BD258 2610DD88 */ addiu $s0, $s0, %lo(D_802BDD88_317CA8)
|
||||
/* 31717C 802BD25C 8E040000 */ lw $a0, ($s0)
|
||||
/* 317180 802BD260 8C830004 */ lw $v1, 4($a0)
|
||||
/* 317184 802BD264 24050001 */ addiu $a1, $zero, 1
|
||||
/* 317188 802BD268 10650030 */ beq $v1, $a1, .L802BD32C
|
||||
/* 31718C 802BD26C 28620002 */ slti $v0, $v1, 2
|
||||
/* 317190 802BD270 10400005 */ beqz $v0, .L802BD288
|
||||
/* 317194 802BD274 24020002 */ addiu $v0, $zero, 2
|
||||
/* 317198 802BD278 10600009 */ beqz $v1, .L802BD2A0
|
||||
/* 31719C 802BD27C 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 3171A0 802BD280 080AF551 */ j .L802BD544
|
||||
/* 3171A4 802BD284 00000000 */ nop
|
||||
.L802BD288:
|
||||
/* 3171A8 802BD288 1062009A */ beq $v1, $v0, .L802BD4F4
|
||||
/* 3171AC 802BD28C 24020003 */ addiu $v0, $zero, 3
|
||||
/* 3171B0 802BD290 106200A0 */ beq $v1, $v0, .L802BD514
|
||||
/* 3171B4 802BD294 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 3171B8 802BD298 080AF551 */ j .L802BD544
|
||||
/* 3171BC 802BD29C 00000000 */ nop
|
||||
.L802BD2A0:
|
||||
/* 3171C0 802BD2A0 AC850004 */ sw $a1, 4($a0)
|
||||
/* 3171C4 802BD2A4 8E220000 */ lw $v0, ($s1)
|
||||
/* 3171C8 802BD2A8 AC820008 */ sw $v0, 8($a0)
|
||||
/* 3171CC 802BD2AC C62C0038 */ lwc1 $f12, 0x38($s1)
|
||||
/* 3171D0 802BD2B0 C62E0040 */ lwc1 $f14, 0x40($s1)
|
||||
/* 3171D4 802BD2B4 8E460048 */ lw $a2, 0x48($s2)
|
||||
/* 3171D8 802BD2B8 0C00A7B5 */ jal dist2D
|
||||
/* 3171DC 802BD2BC 8E470050 */ lw $a3, 0x50($s2)
|
||||
/* 3171E0 802BD2C0 8E020000 */ lw $v0, ($s0)
|
||||
/* 3171E4 802BD2C4 46000005 */ abs.s $f0, $f0
|
||||
/* 3171E8 802BD2C8 E440000C */ swc1 $f0, 0xc($v0)
|
||||
/* 3171EC 802BD2CC C64C0048 */ lwc1 $f12, 0x48($s2)
|
||||
/* 3171F0 802BD2D0 C64E0050 */ lwc1 $f14, 0x50($s2)
|
||||
/* 3171F4 802BD2D4 8E260038 */ lw $a2, 0x38($s1)
|
||||
/* 3171F8 802BD2D8 0C00A720 */ jal atan2
|
||||
/* 3171FC 802BD2DC 8E270040 */ lw $a3, 0x40($s1)
|
||||
/* 317200 802BD2E0 3C040004 */ lui $a0, 4
|
||||
/* 317204 802BD2E4 24020078 */ addiu $v0, $zero, 0x78
|
||||
/* 317208 802BD2E8 8E030000 */ lw $v1, ($s0)
|
||||
/* 31720C 802BD2EC 3C0140C0 */ lui $at, 0x40c0
|
||||
/* 317210 802BD2F0 44811000 */ mtc1 $at, $f2
|
||||
/* 317214 802BD2F4 3C014248 */ lui $at, 0x4248
|
||||
/* 317218 802BD2F8 44812000 */ mtc1 $at, $f4
|
||||
/* 31721C 802BD2FC 34840148 */ ori $a0, $a0, 0x148
|
||||
/* 317220 802BD300 E4600010 */ swc1 $f0, 0x10($v1)
|
||||
/* 317224 802BD304 E4620014 */ swc1 $f2, 0x14($v1)
|
||||
/* 317228 802BD308 E4640018 */ swc1 $f4, 0x18($v1)
|
||||
/* 31722C 802BD30C AC620000 */ sw $v0, ($v1)
|
||||
/* 317230 802BD310 8E220000 */ lw $v0, ($s1)
|
||||
/* 317234 802BD314 2403FDFF */ addiu $v1, $zero, -0x201
|
||||
/* 317238 802BD318 00441025 */ or $v0, $v0, $a0
|
||||
/* 31723C 802BD31C 00431024 */ and $v0, $v0, $v1
|
||||
/* 317240 802BD320 AE220000 */ sw $v0, ($s1)
|
||||
/* 317244 802BD324 3C10802C */ lui $s0, %hi(D_802BDD88_317CA8)
|
||||
/* 317248 802BD328 2610DD88 */ addiu $s0, $s0, %lo(D_802BDD88_317CA8)
|
||||
.L802BD32C:
|
||||
/* 31724C 802BD32C 8E020000 */ lw $v0, ($s0)
|
||||
/* 317250 802BD330 3C0140C9 */ lui $at, 0x40c9
|
||||
/* 317254 802BD334 34210FD0 */ ori $at, $at, 0xfd0
|
||||
/* 317258 802BD338 44810000 */ mtc1 $at, $f0
|
||||
/* 31725C 802BD33C C44C0010 */ lwc1 $f12, 0x10($v0)
|
||||
/* 317260 802BD340 46006302 */ mul.s $f12, $f12, $f0
|
||||
/* 317264 802BD344 00000000 */ nop
|
||||
/* 317268 802BD348 27A50010 */ addiu $a1, $sp, 0x10
|
||||
/* 31726C 802BD34C 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 317270 802BD350 44810000 */ mtc1 $at, $f0
|
||||
/* 317274 802BD354 27A60014 */ addiu $a2, $sp, 0x14
|
||||
/* 317278 802BD358 0C00A82D */ jal sin_cos_rad
|
||||
/* 31727C 802BD35C 46006303 */ div.s $f12, $f12, $f0
|
||||
/* 317280 802BD360 8E020000 */ lw $v0, ($s0)
|
||||
/* 317284 802BD364 C7A20010 */ lwc1 $f2, 0x10($sp)
|
||||
/* 317288 802BD368 C440000C */ lwc1 $f0, 0xc($v0)
|
||||
/* 31728C 802BD36C 46001082 */ mul.s $f2, $f2, $f0
|
||||
/* 317290 802BD370 00000000 */ nop
|
||||
/* 317294 802BD374 C6400048 */ lwc1 $f0, 0x48($s2)
|
||||
/* 317298 802BD378 46020000 */ add.s $f0, $f0, $f2
|
||||
/* 31729C 802BD37C E6200038 */ swc1 $f0, 0x38($s1)
|
||||
/* 3172A0 802BD380 C7A20014 */ lwc1 $f2, 0x14($sp)
|
||||
/* 3172A4 802BD384 C440000C */ lwc1 $f0, 0xc($v0)
|
||||
/* 3172A8 802BD388 46001082 */ mul.s $f2, $f2, $f0
|
||||
/* 3172AC 802BD38C 00000000 */ nop
|
||||
/* 3172B0 802BD390 C6400050 */ lwc1 $f0, 0x50($s2)
|
||||
/* 3172B4 802BD394 46020001 */ sub.s $f0, $f0, $f2
|
||||
/* 3172B8 802BD398 E6200040 */ swc1 $f0, 0x40($s1)
|
||||
/* 3172BC 802BD39C C4400010 */ lwc1 $f0, 0x10($v0)
|
||||
/* 3172C0 802BD3A0 C44C0014 */ lwc1 $f12, 0x14($v0)
|
||||
/* 3172C4 802BD3A4 0C00A6C9 */ jal clamp_angle
|
||||
/* 3172C8 802BD3A8 460C0301 */ sub.s $f12, $f0, $f12
|
||||
/* 3172CC 802BD3AC 8E100000 */ lw $s0, ($s0)
|
||||
/* 3172D0 802BD3B0 3C0141A0 */ lui $at, 0x41a0
|
||||
/* 3172D4 802BD3B4 44811000 */ mtc1 $at, $f2
|
||||
/* 3172D8 802BD3B8 C604000C */ lwc1 $f4, 0xc($s0)
|
||||
/* 3172DC 802BD3BC 4604103C */ c.lt.s $f2, $f4
|
||||
/* 3172E0 802BD3C0 00000000 */ nop
|
||||
/* 3172E4 802BD3C4 45000005 */ bc1f .L802BD3DC
|
||||
/* 3172E8 802BD3C8 E6000010 */ swc1 $f0, 0x10($s0)
|
||||
/* 3172EC 802BD3CC 3C013F80 */ lui $at, 0x3f80
|
||||
/* 3172F0 802BD3D0 44810000 */ mtc1 $at, $f0
|
||||
/* 3172F4 802BD3D4 080AF502 */ j .L802BD408
|
||||
/* 3172F8 802BD3D8 46002001 */ sub.s $f0, $f4, $f0
|
||||
.L802BD3DC:
|
||||
/* 3172FC 802BD3DC 3C014198 */ lui $at, 0x4198
|
||||
/* 317300 802BD3E0 44810000 */ mtc1 $at, $f0
|
||||
/* 317304 802BD3E4 00000000 */ nop
|
||||
/* 317308 802BD3E8 4600203C */ c.lt.s $f4, $f0
|
||||
/* 31730C 802BD3EC 00000000 */ nop
|
||||
/* 317310 802BD3F0 45000006 */ bc1f .L802BD40C
|
||||
/* 317314 802BD3F4 00000000 */ nop
|
||||
/* 317318 802BD3F8 3C013F80 */ lui $at, 0x3f80
|
||||
/* 31731C 802BD3FC 44810000 */ mtc1 $at, $f0
|
||||
/* 317320 802BD400 00000000 */ nop
|
||||
/* 317324 802BD404 46002000 */ add.s $f0, $f4, $f0
|
||||
.L802BD408:
|
||||
/* 317328 802BD408 E600000C */ swc1 $f0, 0xc($s0)
|
||||
.L802BD40C:
|
||||
/* 31732C 802BD40C 3C10802C */ lui $s0, %hi(D_802BDD88_317CA8)
|
||||
/* 317330 802BD410 2610DD88 */ addiu $s0, $s0, %lo(D_802BDD88_317CA8)
|
||||
/* 317334 802BD414 8E020000 */ lw $v0, ($s0)
|
||||
/* 317338 802BD418 3C0140C9 */ lui $at, 0x40c9
|
||||
/* 31733C 802BD41C 34210FD0 */ ori $at, $at, 0xfd0
|
||||
/* 317340 802BD420 44810000 */ mtc1 $at, $f0
|
||||
/* 317344 802BD424 C44C0018 */ lwc1 $f12, 0x18($v0)
|
||||
/* 317348 802BD428 46006302 */ mul.s $f12, $f12, $f0
|
||||
/* 31734C 802BD42C 00000000 */ nop
|
||||
/* 317350 802BD430 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 317354 802BD434 4481A000 */ mtc1 $at, $f20
|
||||
/* 317358 802BD438 0C00A85B */ jal sin_rad
|
||||
/* 31735C 802BD43C 46146303 */ div.s $f12, $f12, $f20
|
||||
/* 317360 802BD440 8E020000 */ lw $v0, ($s0)
|
||||
/* 317364 802BD444 3C014040 */ lui $at, 0x4040
|
||||
/* 317368 802BD448 44812000 */ mtc1 $at, $f4
|
||||
/* 31736C 802BD44C C4420018 */ lwc1 $f2, 0x18($v0)
|
||||
/* 317370 802BD450 46041080 */ add.s $f2, $f2, $f4
|
||||
/* 317374 802BD454 3C014316 */ lui $at, 0x4316
|
||||
/* 317378 802BD458 44813000 */ mtc1 $at, $f6
|
||||
/* 31737C 802BD45C 00000000 */ nop
|
||||
/* 317380 802BD460 4602303C */ c.lt.s $f6, $f2
|
||||
/* 317384 802BD464 E4420018 */ swc1 $f2, 0x18($v0)
|
||||
/* 317388 802BD468 46040082 */ mul.s $f2, $f0, $f4
|
||||
/* 31738C 802BD46C 00000000 */ nop
|
||||
/* 317390 802BD470 45030001 */ bc1tl .L802BD478
|
||||
/* 317394 802BD474 E4460018 */ swc1 $f6, 0x18($v0)
|
||||
.L802BD478:
|
||||
/* 317398 802BD478 C620003C */ lwc1 $f0, 0x3c($s1)
|
||||
/* 31739C 802BD47C 46020000 */ add.s $f0, $f0, $f2
|
||||
/* 3173A0 802BD480 8E020000 */ lw $v0, ($s0)
|
||||
/* 3173A4 802BD484 E620003C */ swc1 $f0, 0x3c($s1)
|
||||
/* 3173A8 802BD488 C44C0010 */ lwc1 $f12, 0x10($v0)
|
||||
/* 3173AC 802BD48C 0C00A6C9 */ jal clamp_angle
|
||||
/* 3173B0 802BD490 460CA301 */ sub.s $f12, $f20, $f12
|
||||
/* 3173B4 802BD494 8E020000 */ lw $v0, ($s0)
|
||||
/* 3173B8 802BD498 E6200034 */ swc1 $f0, 0x34($s1)
|
||||
/* 3173BC 802BD49C C4400014 */ lwc1 $f0, 0x14($v0)
|
||||
/* 3173C0 802BD4A0 3C01802C */ lui $at, %hi(D_802BDE80_317DA0)
|
||||
/* 3173C4 802BD4A4 D422DE80 */ ldc1 $f2, %lo(D_802BDE80_317DA0)($at)
|
||||
/* 3173C8 802BD4A8 46000021 */ cvt.d.s $f0, $f0
|
||||
/* 3173CC 802BD4AC 46220000 */ add.d $f0, $f0, $f2
|
||||
/* 3173D0 802BD4B0 3C014220 */ lui $at, 0x4220
|
||||
/* 3173D4 802BD4B4 44811000 */ mtc1 $at, $f2
|
||||
/* 3173D8 802BD4B8 46200020 */ cvt.s.d $f0, $f0
|
||||
/* 3173DC 802BD4BC 4600103C */ c.lt.s $f2, $f0
|
||||
/* 3173E0 802BD4C0 00000000 */ nop
|
||||
/* 3173E4 802BD4C4 45000002 */ bc1f .L802BD4D0
|
||||
/* 3173E8 802BD4C8 E4400014 */ swc1 $f0, 0x14($v0)
|
||||
/* 3173EC 802BD4CC E4420014 */ swc1 $f2, 0x14($v0)
|
||||
.L802BD4D0:
|
||||
/* 3173F0 802BD4D0 8E030000 */ lw $v1, ($s0)
|
||||
/* 3173F4 802BD4D4 8C620000 */ lw $v0, ($v1)
|
||||
/* 3173F8 802BD4D8 2442FFFF */ addiu $v0, $v0, -1
|
||||
/* 3173FC 802BD4DC 14400018 */ bnez $v0, .L802BD540
|
||||
/* 317400 802BD4E0 AC620000 */ sw $v0, ($v1)
|
||||
/* 317404 802BD4E4 8C620004 */ lw $v0, 4($v1)
|
||||
/* 317408 802BD4E8 24420001 */ addiu $v0, $v0, 1
|
||||
/* 31740C 802BD4EC 080AF550 */ j .L802BD540
|
||||
/* 317410 802BD4F0 AC620004 */ sw $v0, 4($v1)
|
||||
.L802BD4F4:
|
||||
/* 317414 802BD4F4 8C820008 */ lw $v0, 8($a0)
|
||||
/* 317418 802BD4F8 AE220000 */ sw $v0, ($s1)
|
||||
/* 31741C 802BD4FC 8C820004 */ lw $v0, 4($a0)
|
||||
/* 317420 802BD500 2403001E */ addiu $v1, $zero, 0x1e
|
||||
/* 317424 802BD504 AC830000 */ sw $v1, ($a0)
|
||||
/* 317428 802BD508 24420001 */ addiu $v0, $v0, 1
|
||||
/* 31742C 802BD50C 080AF550 */ j .L802BD540
|
||||
/* 317430 802BD510 AC820004 */ sw $v0, 4($a0)
|
||||
.L802BD514:
|
||||
/* 317434 802BD514 0C03AE8F */ jal partner_walking_update_player_tracking
|
||||
/* 317438 802BD518 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 31743C 802BD51C 0C03AED0 */ jal partner_walking_update_motion
|
||||
/* 317440 802BD520 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 317444 802BD524 8E030000 */ lw $v1, ($s0)
|
||||
/* 317448 802BD528 8C620000 */ lw $v0, ($v1)
|
||||
/* 31744C 802BD52C 2442FFFF */ addiu $v0, $v0, -1
|
||||
/* 317450 802BD530 14400003 */ bnez $v0, .L802BD540
|
||||
/* 317454 802BD534 AC620000 */ sw $v0, ($v1)
|
||||
/* 317458 802BD538 AC600004 */ sw $zero, 4($v1)
|
||||
/* 31745C 802BD53C AE600000 */ sw $zero, ($s3)
|
||||
.L802BD540:
|
||||
/* 317460 802BD540 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD544:
|
||||
/* 317464 802BD544 8FBF0028 */ lw $ra, 0x28($sp)
|
||||
/* 317468 802BD548 8FB30024 */ lw $s3, 0x24($sp)
|
||||
/* 31746C 802BD54C 8FB20020 */ lw $s2, 0x20($sp)
|
||||
/* 317470 802BD550 8FB1001C */ lw $s1, 0x1c($sp)
|
||||
/* 317474 802BD554 8FB00018 */ lw $s0, 0x18($sp)
|
||||
/* 317478 802BD558 D7B40030 */ ldc1 $f20, 0x30($sp)
|
||||
/* 31747C 802BD55C 03E00008 */ jr $ra
|
||||
/* 317480 802BD560 27BD0038 */ addiu $sp, $sp, 0x38
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD564_317484
|
||||
/* 317484 802BD564 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 317488 802BD568 3C058011 */ lui $a1, %hi(D_8010C954)
|
||||
/* 31748C 802BD56C 24A5C954 */ addiu $a1, $a1, %lo(D_8010C954)
|
||||
/* 317490 802BD570 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 317494 802BD574 8CA20000 */ lw $v0, ($a1)
|
||||
/* 317498 802BD578 10400008 */ beqz $v0, .L802BD59C
|
||||
/* 31749C 802BD57C 00000000 */ nop
|
||||
/* 3174A0 802BD580 3C03802C */ lui $v1, %hi(D_802BDD88_317CA8)
|
||||
/* 3174A4 802BD584 8C63DD88 */ lw $v1, %lo(D_802BDD88_317CA8)($v1)
|
||||
/* 3174A8 802BD588 8C620008 */ lw $v0, 8($v1)
|
||||
/* 3174AC 802BD58C ACA00000 */ sw $zero, ($a1)
|
||||
/* 3174B0 802BD590 AC820000 */ sw $v0, ($a0)
|
||||
/* 3174B4 802BD594 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 3174B8 802BD598 AC600004 */ sw $zero, 4($v1)
|
||||
.L802BD59C:
|
||||
/* 3174BC 802BD59C 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 3174C0 802BD5A0 03E00008 */ jr $ra
|
||||
/* 3174C4 802BD5A4 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,254 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
.section .rodata
|
||||
|
||||
dlabel D_802BD5F0_324F00
|
||||
.double 0.8, 0.0
|
||||
|
||||
.section .text
|
||||
|
||||
glabel func_802BD14C_324A5C
|
||||
/* 324A5C 802BD14C 27BDFFC8 */ addiu $sp, $sp, -0x38
|
||||
/* 324A60 802BD150 AFB00018 */ sw $s0, 0x18($sp)
|
||||
/* 324A64 802BD154 3C108011 */ lui $s0, %hi(gPlayerData)
|
||||
/* 324A68 802BD158 2610F290 */ addiu $s0, $s0, %lo(gPlayerData)
|
||||
/* 324A6C 802BD15C AFBF0028 */ sw $ra, 0x28($sp)
|
||||
/* 324A70 802BD160 AFB30024 */ sw $s3, 0x24($sp)
|
||||
/* 324A74 802BD164 AFB20020 */ sw $s2, 0x20($sp)
|
||||
/* 324A78 802BD168 AFB1001C */ sw $s1, 0x1c($sp)
|
||||
/* 324A7C 802BD16C F7B40030 */ sdc1 $f20, 0x30($sp)
|
||||
/* 324A80 802BD170 8C91014C */ lw $s1, 0x14c($a0)
|
||||
/* 324A84 802BD174 10A00009 */ beqz $a1, .L802BD19C
|
||||
/* 324A88 802BD178 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 324A8C 802BD17C 0C03AE2A */ jal partner_walking_enable
|
||||
/* 324A90 802BD180 24050001 */ addiu $a1, $zero, 1
|
||||
/* 324A94 802BD184 3C04802C */ lui $a0, %hi(D_802BD58C_324E9C)
|
||||
/* 324A98 802BD188 8C84D58C */ lw $a0, %lo(D_802BD58C_324E9C)($a0)
|
||||
/* 324A9C 802BD18C 0C00A580 */ jal mem_clear
|
||||
/* 324AA0 802BD190 2405001C */ addiu $a1, $zero, 0x1c
|
||||
/* 324AA4 802BD194 3C018011 */ lui $at, %hi(D_8010C954)
|
||||
/* 324AA8 802BD198 AC20C954 */ sw $zero, %lo(D_8010C954)($at)
|
||||
.L802BD19C:
|
||||
/* 324AAC 802BD19C 3C138011 */ lui $s3, %hi(D_8010C954)
|
||||
/* 324AB0 802BD1A0 2673C954 */ addiu $s3, $s3, %lo(D_8010C954)
|
||||
/* 324AB4 802BD1A4 8E020308 */ lw $v0, 0x308($s0)
|
||||
/* 324AB8 802BD1A8 8E720000 */ lw $s2, ($s3)
|
||||
/* 324ABC 802BD1AC 24420001 */ addiu $v0, $v0, 1
|
||||
/* 324AC0 802BD1B0 16400007 */ bnez $s2, .L802BD1D0
|
||||
/* 324AC4 802BD1B4 AE020308 */ sw $v0, 0x308($s0)
|
||||
/* 324AC8 802BD1B8 0C03AE8F */ jal partner_walking_update_player_tracking
|
||||
/* 324ACC 802BD1BC 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 324AD0 802BD1C0 0C03AED0 */ jal partner_walking_update_motion
|
||||
/* 324AD4 802BD1C4 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 324AD8 802BD1C8 080AF530 */ j .L802BD4C0
|
||||
/* 324ADC 802BD1CC 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD1D0:
|
||||
/* 324AE0 802BD1D0 3C10802C */ lui $s0, %hi(D_802BD58C_324E9C)
|
||||
/* 324AE4 802BD1D4 2610D58C */ addiu $s0, $s0, %lo(D_802BD58C_324E9C)
|
||||
/* 324AE8 802BD1D8 8E040000 */ lw $a0, ($s0)
|
||||
/* 324AEC 802BD1DC 8C830004 */ lw $v1, 4($a0)
|
||||
/* 324AF0 802BD1E0 24050001 */ addiu $a1, $zero, 1
|
||||
/* 324AF4 802BD1E4 10650030 */ beq $v1, $a1, .L802BD2A8
|
||||
/* 324AF8 802BD1E8 28620002 */ slti $v0, $v1, 2
|
||||
/* 324AFC 802BD1EC 10400005 */ beqz $v0, .L802BD204
|
||||
/* 324B00 802BD1F0 24020002 */ addiu $v0, $zero, 2
|
||||
/* 324B04 802BD1F4 10600009 */ beqz $v1, .L802BD21C
|
||||
/* 324B08 802BD1F8 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 324B0C 802BD1FC 080AF530 */ j .L802BD4C0
|
||||
/* 324B10 802BD200 00000000 */ nop
|
||||
.L802BD204:
|
||||
/* 324B14 802BD204 1062009A */ beq $v1, $v0, .L802BD470
|
||||
/* 324B18 802BD208 24020003 */ addiu $v0, $zero, 3
|
||||
/* 324B1C 802BD20C 106200A0 */ beq $v1, $v0, .L802BD490
|
||||
/* 324B20 802BD210 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 324B24 802BD214 080AF530 */ j .L802BD4C0
|
||||
/* 324B28 802BD218 00000000 */ nop
|
||||
.L802BD21C:
|
||||
/* 324B2C 802BD21C AC850004 */ sw $a1, 4($a0)
|
||||
/* 324B30 802BD220 8E220000 */ lw $v0, ($s1)
|
||||
/* 324B34 802BD224 AC820008 */ sw $v0, 8($a0)
|
||||
/* 324B38 802BD228 C62C0038 */ lwc1 $f12, 0x38($s1)
|
||||
/* 324B3C 802BD22C C62E0040 */ lwc1 $f14, 0x40($s1)
|
||||
/* 324B40 802BD230 8E460048 */ lw $a2, 0x48($s2)
|
||||
/* 324B44 802BD234 0C00A7B5 */ jal dist2D
|
||||
/* 324B48 802BD238 8E470050 */ lw $a3, 0x50($s2)
|
||||
/* 324B4C 802BD23C 8E020000 */ lw $v0, ($s0)
|
||||
/* 324B50 802BD240 46000005 */ abs.s $f0, $f0
|
||||
/* 324B54 802BD244 E440000C */ swc1 $f0, 0xc($v0)
|
||||
/* 324B58 802BD248 C64C0048 */ lwc1 $f12, 0x48($s2)
|
||||
/* 324B5C 802BD24C C64E0050 */ lwc1 $f14, 0x50($s2)
|
||||
/* 324B60 802BD250 8E260038 */ lw $a2, 0x38($s1)
|
||||
/* 324B64 802BD254 0C00A720 */ jal atan2
|
||||
/* 324B68 802BD258 8E270040 */ lw $a3, 0x40($s1)
|
||||
/* 324B6C 802BD25C 3C040004 */ lui $a0, 4
|
||||
/* 324B70 802BD260 24020078 */ addiu $v0, $zero, 0x78
|
||||
/* 324B74 802BD264 8E030000 */ lw $v1, ($s0)
|
||||
/* 324B78 802BD268 3C0140C0 */ lui $at, 0x40c0
|
||||
/* 324B7C 802BD26C 44811000 */ mtc1 $at, $f2
|
||||
/* 324B80 802BD270 3C014248 */ lui $at, 0x4248
|
||||
/* 324B84 802BD274 44812000 */ mtc1 $at, $f4
|
||||
/* 324B88 802BD278 34840148 */ ori $a0, $a0, 0x148
|
||||
/* 324B8C 802BD27C E4600010 */ swc1 $f0, 0x10($v1)
|
||||
/* 324B90 802BD280 E4620014 */ swc1 $f2, 0x14($v1)
|
||||
/* 324B94 802BD284 E4640018 */ swc1 $f4, 0x18($v1)
|
||||
/* 324B98 802BD288 AC620000 */ sw $v0, ($v1)
|
||||
/* 324B9C 802BD28C 8E220000 */ lw $v0, ($s1)
|
||||
/* 324BA0 802BD290 2403FDFF */ addiu $v1, $zero, -0x201
|
||||
/* 324BA4 802BD294 00441025 */ or $v0, $v0, $a0
|
||||
/* 324BA8 802BD298 00431024 */ and $v0, $v0, $v1
|
||||
/* 324BAC 802BD29C AE220000 */ sw $v0, ($s1)
|
||||
/* 324BB0 802BD2A0 3C10802C */ lui $s0, %hi(D_802BD58C_324E9C)
|
||||
/* 324BB4 802BD2A4 2610D58C */ addiu $s0, $s0, %lo(D_802BD58C_324E9C)
|
||||
.L802BD2A8:
|
||||
/* 324BB8 802BD2A8 8E020000 */ lw $v0, ($s0)
|
||||
/* 324BBC 802BD2AC 3C0140C9 */ lui $at, 0x40c9
|
||||
/* 324BC0 802BD2B0 34210FD0 */ ori $at, $at, 0xfd0
|
||||
/* 324BC4 802BD2B4 44810000 */ mtc1 $at, $f0
|
||||
/* 324BC8 802BD2B8 C44C0010 */ lwc1 $f12, 0x10($v0)
|
||||
/* 324BCC 802BD2BC 46006302 */ mul.s $f12, $f12, $f0
|
||||
/* 324BD0 802BD2C0 00000000 */ nop
|
||||
/* 324BD4 802BD2C4 27A50010 */ addiu $a1, $sp, 0x10
|
||||
/* 324BD8 802BD2C8 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 324BDC 802BD2CC 44810000 */ mtc1 $at, $f0
|
||||
/* 324BE0 802BD2D0 27A60014 */ addiu $a2, $sp, 0x14
|
||||
/* 324BE4 802BD2D4 0C00A82D */ jal sin_cos_rad
|
||||
/* 324BE8 802BD2D8 46006303 */ div.s $f12, $f12, $f0
|
||||
/* 324BEC 802BD2DC 8E020000 */ lw $v0, ($s0)
|
||||
/* 324BF0 802BD2E0 C7A20010 */ lwc1 $f2, 0x10($sp)
|
||||
/* 324BF4 802BD2E4 C440000C */ lwc1 $f0, 0xc($v0)
|
||||
/* 324BF8 802BD2E8 46001082 */ mul.s $f2, $f2, $f0
|
||||
/* 324BFC 802BD2EC 00000000 */ nop
|
||||
/* 324C00 802BD2F0 C6400048 */ lwc1 $f0, 0x48($s2)
|
||||
/* 324C04 802BD2F4 46020000 */ add.s $f0, $f0, $f2
|
||||
/* 324C08 802BD2F8 E6200038 */ swc1 $f0, 0x38($s1)
|
||||
/* 324C0C 802BD2FC C7A20014 */ lwc1 $f2, 0x14($sp)
|
||||
/* 324C10 802BD300 C440000C */ lwc1 $f0, 0xc($v0)
|
||||
/* 324C14 802BD304 46001082 */ mul.s $f2, $f2, $f0
|
||||
/* 324C18 802BD308 00000000 */ nop
|
||||
/* 324C1C 802BD30C C6400050 */ lwc1 $f0, 0x50($s2)
|
||||
/* 324C20 802BD310 46020001 */ sub.s $f0, $f0, $f2
|
||||
/* 324C24 802BD314 E6200040 */ swc1 $f0, 0x40($s1)
|
||||
/* 324C28 802BD318 C4400010 */ lwc1 $f0, 0x10($v0)
|
||||
/* 324C2C 802BD31C C44C0014 */ lwc1 $f12, 0x14($v0)
|
||||
/* 324C30 802BD320 0C00A6C9 */ jal clamp_angle
|
||||
/* 324C34 802BD324 460C0301 */ sub.s $f12, $f0, $f12
|
||||
/* 324C38 802BD328 8E100000 */ lw $s0, ($s0)
|
||||
/* 324C3C 802BD32C 3C0141A0 */ lui $at, 0x41a0
|
||||
/* 324C40 802BD330 44811000 */ mtc1 $at, $f2
|
||||
/* 324C44 802BD334 C604000C */ lwc1 $f4, 0xc($s0)
|
||||
/* 324C48 802BD338 4604103C */ c.lt.s $f2, $f4
|
||||
/* 324C4C 802BD33C 00000000 */ nop
|
||||
/* 324C50 802BD340 45000005 */ bc1f .L802BD358
|
||||
/* 324C54 802BD344 E6000010 */ swc1 $f0, 0x10($s0)
|
||||
/* 324C58 802BD348 3C013F80 */ lui $at, 0x3f80
|
||||
/* 324C5C 802BD34C 44810000 */ mtc1 $at, $f0
|
||||
/* 324C60 802BD350 080AF4E1 */ j .L802BD384
|
||||
/* 324C64 802BD354 46002001 */ sub.s $f0, $f4, $f0
|
||||
.L802BD358:
|
||||
/* 324C68 802BD358 3C014198 */ lui $at, 0x4198
|
||||
/* 324C6C 802BD35C 44810000 */ mtc1 $at, $f0
|
||||
/* 324C70 802BD360 00000000 */ nop
|
||||
/* 324C74 802BD364 4600203C */ c.lt.s $f4, $f0
|
||||
/* 324C78 802BD368 00000000 */ nop
|
||||
/* 324C7C 802BD36C 45000006 */ bc1f .L802BD388
|
||||
/* 324C80 802BD370 00000000 */ nop
|
||||
/* 324C84 802BD374 3C013F80 */ lui $at, 0x3f80
|
||||
/* 324C88 802BD378 44810000 */ mtc1 $at, $f0
|
||||
/* 324C8C 802BD37C 00000000 */ nop
|
||||
/* 324C90 802BD380 46002000 */ add.s $f0, $f4, $f0
|
||||
.L802BD384:
|
||||
/* 324C94 802BD384 E600000C */ swc1 $f0, 0xc($s0)
|
||||
.L802BD388:
|
||||
/* 324C98 802BD388 3C10802C */ lui $s0, %hi(D_802BD58C_324E9C)
|
||||
/* 324C9C 802BD38C 2610D58C */ addiu $s0, $s0, %lo(D_802BD58C_324E9C)
|
||||
/* 324CA0 802BD390 8E020000 */ lw $v0, ($s0)
|
||||
/* 324CA4 802BD394 3C0140C9 */ lui $at, 0x40c9
|
||||
/* 324CA8 802BD398 34210FD0 */ ori $at, $at, 0xfd0
|
||||
/* 324CAC 802BD39C 44810000 */ mtc1 $at, $f0
|
||||
/* 324CB0 802BD3A0 C44C0018 */ lwc1 $f12, 0x18($v0)
|
||||
/* 324CB4 802BD3A4 46006302 */ mul.s $f12, $f12, $f0
|
||||
/* 324CB8 802BD3A8 00000000 */ nop
|
||||
/* 324CBC 802BD3AC 3C0143B4 */ lui $at, 0x43b4
|
||||
/* 324CC0 802BD3B0 4481A000 */ mtc1 $at, $f20
|
||||
/* 324CC4 802BD3B4 0C00A85B */ jal sin_rad
|
||||
/* 324CC8 802BD3B8 46146303 */ div.s $f12, $f12, $f20
|
||||
/* 324CCC 802BD3BC 8E020000 */ lw $v0, ($s0)
|
||||
/* 324CD0 802BD3C0 3C014040 */ lui $at, 0x4040
|
||||
/* 324CD4 802BD3C4 44812000 */ mtc1 $at, $f4
|
||||
/* 324CD8 802BD3C8 C4420018 */ lwc1 $f2, 0x18($v0)
|
||||
/* 324CDC 802BD3CC 46041080 */ add.s $f2, $f2, $f4
|
||||
/* 324CE0 802BD3D0 3C014316 */ lui $at, 0x4316
|
||||
/* 324CE4 802BD3D4 44813000 */ mtc1 $at, $f6
|
||||
/* 324CE8 802BD3D8 00000000 */ nop
|
||||
/* 324CEC 802BD3DC 4602303C */ c.lt.s $f6, $f2
|
||||
/* 324CF0 802BD3E0 E4420018 */ swc1 $f2, 0x18($v0)
|
||||
/* 324CF4 802BD3E4 46040082 */ mul.s $f2, $f0, $f4
|
||||
/* 324CF8 802BD3E8 00000000 */ nop
|
||||
/* 324CFC 802BD3EC 45030001 */ bc1tl .L802BD3F4
|
||||
/* 324D00 802BD3F0 E4460018 */ swc1 $f6, 0x18($v0)
|
||||
.L802BD3F4:
|
||||
/* 324D04 802BD3F4 C620003C */ lwc1 $f0, 0x3c($s1)
|
||||
/* 324D08 802BD3F8 46020000 */ add.s $f0, $f0, $f2
|
||||
/* 324D0C 802BD3FC 8E020000 */ lw $v0, ($s0)
|
||||
/* 324D10 802BD400 E620003C */ swc1 $f0, 0x3c($s1)
|
||||
/* 324D14 802BD404 C44C0010 */ lwc1 $f12, 0x10($v0)
|
||||
/* 324D18 802BD408 0C00A6C9 */ jal clamp_angle
|
||||
/* 324D1C 802BD40C 460CA301 */ sub.s $f12, $f20, $f12
|
||||
/* 324D20 802BD410 8E020000 */ lw $v0, ($s0)
|
||||
/* 324D24 802BD414 E6200034 */ swc1 $f0, 0x34($s1)
|
||||
/* 324D28 802BD418 C4400014 */ lwc1 $f0, 0x14($v0)
|
||||
/* 324D2C 802BD41C 3C01802C */ lui $at, %hi(D_802BD5F0_324F00)
|
||||
/* 324D30 802BD420 D422D5F0 */ ldc1 $f2, %lo(D_802BD5F0_324F00)($at)
|
||||
/* 324D34 802BD424 46000021 */ cvt.d.s $f0, $f0
|
||||
/* 324D38 802BD428 46220000 */ add.d $f0, $f0, $f2
|
||||
/* 324D3C 802BD42C 3C014220 */ lui $at, 0x4220
|
||||
/* 324D40 802BD430 44811000 */ mtc1 $at, $f2
|
||||
/* 324D44 802BD434 46200020 */ cvt.s.d $f0, $f0
|
||||
/* 324D48 802BD438 4600103C */ c.lt.s $f2, $f0
|
||||
/* 324D4C 802BD43C 00000000 */ nop
|
||||
/* 324D50 802BD440 45000002 */ bc1f .L802BD44C
|
||||
/* 324D54 802BD444 E4400014 */ swc1 $f0, 0x14($v0)
|
||||
/* 324D58 802BD448 E4420014 */ swc1 $f2, 0x14($v0)
|
||||
.L802BD44C:
|
||||
/* 324D5C 802BD44C 8E030000 */ lw $v1, ($s0)
|
||||
/* 324D60 802BD450 8C620000 */ lw $v0, ($v1)
|
||||
/* 324D64 802BD454 2442FFFF */ addiu $v0, $v0, -1
|
||||
/* 324D68 802BD458 14400018 */ bnez $v0, .L802BD4BC
|
||||
/* 324D6C 802BD45C AC620000 */ sw $v0, ($v1)
|
||||
/* 324D70 802BD460 8C620004 */ lw $v0, 4($v1)
|
||||
/* 324D74 802BD464 24420001 */ addiu $v0, $v0, 1
|
||||
/* 324D78 802BD468 080AF52F */ j .L802BD4BC
|
||||
/* 324D7C 802BD46C AC620004 */ sw $v0, 4($v1)
|
||||
.L802BD470:
|
||||
/* 324D80 802BD470 8C820008 */ lw $v0, 8($a0)
|
||||
/* 324D84 802BD474 AE220000 */ sw $v0, ($s1)
|
||||
/* 324D88 802BD478 8C820004 */ lw $v0, 4($a0)
|
||||
/* 324D8C 802BD47C 2403001E */ addiu $v1, $zero, 0x1e
|
||||
/* 324D90 802BD480 AC830000 */ sw $v1, ($a0)
|
||||
/* 324D94 802BD484 24420001 */ addiu $v0, $v0, 1
|
||||
/* 324D98 802BD488 080AF52F */ j .L802BD4BC
|
||||
/* 324D9C 802BD48C AC820004 */ sw $v0, 4($a0)
|
||||
.L802BD490:
|
||||
/* 324DA0 802BD490 0C03AE8F */ jal partner_walking_update_player_tracking
|
||||
/* 324DA4 802BD494 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 324DA8 802BD498 0C03AED0 */ jal partner_walking_update_motion
|
||||
/* 324DAC 802BD49C 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 324DB0 802BD4A0 8E030000 */ lw $v1, ($s0)
|
||||
/* 324DB4 802BD4A4 8C620000 */ lw $v0, ($v1)
|
||||
/* 324DB8 802BD4A8 2442FFFF */ addiu $v0, $v0, -1
|
||||
/* 324DBC 802BD4AC 14400003 */ bnez $v0, .L802BD4BC
|
||||
/* 324DC0 802BD4B0 AC620000 */ sw $v0, ($v1)
|
||||
/* 324DC4 802BD4B4 AC600004 */ sw $zero, 4($v1)
|
||||
/* 324DC8 802BD4B8 AE600000 */ sw $zero, ($s3)
|
||||
.L802BD4BC:
|
||||
/* 324DCC 802BD4BC 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD4C0:
|
||||
/* 324DD0 802BD4C0 8FBF0028 */ lw $ra, 0x28($sp)
|
||||
/* 324DD4 802BD4C4 8FB30024 */ lw $s3, 0x24($sp)
|
||||
/* 324DD8 802BD4C8 8FB20020 */ lw $s2, 0x20($sp)
|
||||
/* 324DDC 802BD4CC 8FB1001C */ lw $s1, 0x1c($sp)
|
||||
/* 324DE0 802BD4D0 8FB00018 */ lw $s0, 0x18($sp)
|
||||
/* 324DE4 802BD4D4 D7B40030 */ ldc1 $f20, 0x30($sp)
|
||||
/* 324DE8 802BD4D8 03E00008 */ jr $ra
|
||||
/* 324DEC 802BD4DC 27BD0038 */ addiu $sp, $sp, 0x38
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD4E0_324DF0
|
||||
/* 324DF0 802BD4E0 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 324DF4 802BD4E4 3C058011 */ lui $a1, %hi(D_8010C954)
|
||||
/* 324DF8 802BD4E8 24A5C954 */ addiu $a1, $a1, %lo(D_8010C954)
|
||||
/* 324DFC 802BD4EC AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 324E00 802BD4F0 8CA20000 */ lw $v0, ($a1)
|
||||
/* 324E04 802BD4F4 10400008 */ beqz $v0, .L802BD518
|
||||
/* 324E08 802BD4F8 00000000 */ nop
|
||||
/* 324E0C 802BD4FC 3C03802C */ lui $v1, %hi(D_802BD58C_324E9C)
|
||||
/* 324E10 802BD500 8C63D58C */ lw $v1, %lo(D_802BD58C_324E9C)($v1)
|
||||
/* 324E14 802BD504 8C620008 */ lw $v0, 8($v1)
|
||||
/* 324E18 802BD508 ACA00000 */ sw $zero, ($a1)
|
||||
/* 324E1C 802BD50C AC820000 */ sw $v0, ($a0)
|
||||
/* 324E20 802BD510 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 324E24 802BD514 AC600004 */ sw $zero, 4($v1)
|
||||
.L802BD518:
|
||||
/* 324E28 802BD518 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 324E2C 802BD51C 03E00008 */ jr $ra
|
||||
/* 324E30 802BD520 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,23 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD100_31B120
|
||||
/* 31B120 802BD100 3C038011 */ lui $v1, %hi(D_8010C978)
|
||||
/* 31B124 802BD104 8C63C978 */ lw $v1, %lo(D_8010C978)($v1)
|
||||
/* 31B128 802BD108 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31B12C 802BD10C AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31B130 802BD110 04600009 */ bltz $v1, .L802BD138
|
||||
/* 31B134 802BD114 0000102D */ daddu $v0, $zero, $zero
|
||||
/* 31B138 802BD118 30624000 */ andi $v0, $v1, 0x4000
|
||||
/* 31B13C 802BD11C 10400005 */ beqz $v0, .L802BD134
|
||||
/* 31B140 802BD120 2404BFFF */ addiu $a0, $zero, -0x4001
|
||||
/* 31B144 802BD124 0C044277 */ jal entity_interacts_with_current_partner
|
||||
/* 31B148 802BD128 00642024 */ and $a0, $v1, $a0
|
||||
/* 31B14C 802BD12C 080AF44E */ j .L802BD138
|
||||
/* 31B150 802BD130 00000000 */ nop
|
||||
.L802BD134:
|
||||
/* 31B154 802BD134 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD138:
|
||||
/* 31B158 802BD138 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 31B15C 802BD13C 03E00008 */ jr $ra
|
||||
/* 31B160 802BD140 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,19 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD144_31B164
|
||||
/* 31B164 802BD144 3C038011 */ lui $v1, %hi(D_8010C978)
|
||||
/* 31B168 802BD148 8C63C978 */ lw $v1, %lo(D_8010C978)($v1)
|
||||
/* 31B16C 802BD14C 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31B170 802BD150 04600007 */ bltz $v1, .L802BD170
|
||||
/* 31B174 802BD154 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31B178 802BD158 30624000 */ andi $v0, $v1, 0x4000
|
||||
/* 31B17C 802BD15C 10400004 */ beqz $v0, .L802BD170
|
||||
/* 31B180 802BD160 00000000 */ nop
|
||||
/* 31B184 802BD164 2404BFFF */ addiu $a0, $zero, -0x4001
|
||||
/* 31B188 802BD168 0C044277 */ jal entity_interacts_with_current_partner
|
||||
/* 31B18C 802BD16C 00642024 */ and $a0, $v1, $a0
|
||||
.L802BD170:
|
||||
/* 31B190 802BD170 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 31B194 802BD174 03E00008 */ jr $ra
|
||||
/* 31B198 802BD178 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,39 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD17C_31B19C
|
||||
/* 31B19C 802BD17C 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31B1A0 802BD180 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31B1A4 802BD184 848200A6 */ lh $v0, 0xa6($a0)
|
||||
/* 31B1A8 802BD188 C48C0038 */ lwc1 $f12, 0x38($a0)
|
||||
/* 31B1AC 802BD18C C48E003C */ lwc1 $f14, 0x3c($a0)
|
||||
/* 31B1B0 802BD190 8C860040 */ lw $a2, 0x40($a0)
|
||||
/* 31B1B4 802BD194 44820000 */ mtc1 $v0, $f0
|
||||
/* 31B1B8 802BD198 00000000 */ nop
|
||||
/* 31B1BC 802BD19C 46800020 */ cvt.s.w $f0, $f0
|
||||
/* 31B1C0 802BD1A0 44070000 */ mfc1 $a3, $f0
|
||||
/* 31B1C4 802BD1A4 0C04CFF2 */ jal test_item_entity_position
|
||||
/* 31B1C8 802BD1A8 00000000 */ nop
|
||||
/* 31B1CC 802BD1AC 0040282D */ daddu $a1, $v0, $zero
|
||||
/* 31B1D0 802BD1B0 3C01802C */ lui $at, %hi(D_802BEC68)
|
||||
/* 31B1D4 802BD1B4 AC25EC68 */ sw $a1, %lo(D_802BEC68)($at)
|
||||
/* 31B1D8 802BD1B8 04A0000D */ bltz $a1, .L802BD1F0
|
||||
/* 31B1DC 802BD1BC 24040001 */ addiu $a0, $zero, 1
|
||||
/* 31B1E0 802BD1C0 3C02800A */ lui $v0, %hi(gOverrideFlags)
|
||||
/* 31B1E4 802BD1C4 2442A650 */ addiu $v0, $v0, %lo(gOverrideFlags)
|
||||
/* 31B1E8 802BD1C8 8C430000 */ lw $v1, ($v0)
|
||||
/* 31B1EC 802BD1CC 3C01802C */ lui $at, %hi(D_802BEC6C)
|
||||
/* 31B1F0 802BD1D0 AC24EC6C */ sw $a0, %lo(D_802BEC6C)($at)
|
||||
/* 31B1F4 802BD1D4 00A0202D */ daddu $a0, $a1, $zero
|
||||
/* 31B1F8 802BD1D8 3C050020 */ lui $a1, 0x20
|
||||
/* 31B1FC 802BD1DC 34630040 */ ori $v1, $v1, 0x40
|
||||
/* 31B200 802BD1E0 0C04D052 */ jal set_item_entity_flags
|
||||
/* 31B204 802BD1E4 AC430000 */ sw $v1, ($v0)
|
||||
/* 31B208 802BD1E8 080AF47D */ j .L802BD1F4
|
||||
/* 31B20C 802BD1EC 24020001 */ addiu $v0, $zero, 1
|
||||
.L802BD1F0:
|
||||
/* 31B210 802BD1F0 0000102D */ daddu $v0, $zero, $zero
|
||||
.L802BD1F4:
|
||||
/* 31B214 802BD1F4 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 31B218 802BD1F8 03E00008 */ jr $ra
|
||||
/* 31B21C 802BD1FC 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,14 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD200_31B220
|
||||
/* 31B220 802BD200 24020025 */ addiu $v0, $zero, 0x25
|
||||
/* 31B224 802BD204 A48200A8 */ sh $v0, 0xa8($a0)
|
||||
/* 31B228 802BD208 24020018 */ addiu $v0, $zero, 0x18
|
||||
/* 31B22C 802BD20C A48200A6 */ sh $v0, 0xa6($a0)
|
||||
/* 31B230 802BD210 3C020001 */ lui $v0, 1
|
||||
/* 31B234 802BD214 AC820080 */ sw $v0, 0x80($a0)
|
||||
/* 31B238 802BD218 3C01802C */ lui $at, %hi(D_802BEC54)
|
||||
/* 31B23C 802BD21C AC20EC54 */ sw $zero, %lo(D_802BEC54)($at)
|
||||
/* 31B240 802BD220 03E00008 */ jr $ra
|
||||
/* 31B244 802BD224 00000000 */ nop
|
@ -1,19 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD228_31B248
|
||||
/* 31B248 802BD228 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31B24C 802BD22C AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 31B250 802BD230 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 31B254 802BD234 10A00003 */ beqz $a1, .L802BD244
|
||||
/* 31B258 802BD238 8C90014C */ lw $s0, 0x14c($a0)
|
||||
/* 31B25C 802BD23C 0C03BB31 */ jal partner_init_get_out
|
||||
/* 31B260 802BD240 0200202D */ daddu $a0, $s0, $zero
|
||||
.L802BD244:
|
||||
/* 31B264 802BD244 0C03BB3A */ jal partner_get_out
|
||||
/* 31B268 802BD248 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 31B26C 802BD24C 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 31B270 802BD250 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 31B274 802BD254 0002102B */ sltu $v0, $zero, $v0
|
||||
/* 31B278 802BD258 03E00008 */ jr $ra
|
||||
/* 31B27C 802BD25C 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD5F4_31B614
|
||||
/* 31B614 802BD5F4 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31B618 802BD5F8 3C058011 */ lui $a1, %hi(D_8010C954)
|
||||
/* 31B61C 802BD5FC 24A5C954 */ addiu $a1, $a1, %lo(D_8010C954)
|
||||
/* 31B620 802BD600 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31B624 802BD604 8CA20000 */ lw $v0, ($a1)
|
||||
/* 31B628 802BD608 10400008 */ beqz $v0, .L802BD62C
|
||||
/* 31B62C 802BD60C 00000000 */ nop
|
||||
/* 31B630 802BD610 3C03802C */ lui $v1, %hi(D_802BEB60_31CB80)
|
||||
/* 31B634 802BD614 8C63EB60 */ lw $v1, %lo(D_802BEB60_31CB80)($v1)
|
||||
/* 31B638 802BD618 8C620008 */ lw $v0, 8($v1)
|
||||
/* 31B63C 802BD61C ACA00000 */ sw $zero, ($a1)
|
||||
/* 31B640 802BD620 AC820000 */ sw $v0, ($a0)
|
||||
/* 31B644 802BD624 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31B648 802BD628 AC600004 */ sw $zero, 4($v1)
|
||||
.L802BD62C:
|
||||
/* 31B64C 802BD62C 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 31B650 802BD630 03E00008 */ jr $ra
|
||||
/* 31B654 802BD634 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,19 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BE7E0_31C800
|
||||
/* 31C800 802BE7E0 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31C804 802BE7E4 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 31C808 802BE7E8 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 31C80C 802BE7EC 10A00003 */ beqz $a1, .L802BE7FC
|
||||
/* 31C810 802BE7F0 8C90014C */ lw $s0, 0x14c($a0)
|
||||
/* 31C814 802BE7F4 0C03BA65 */ jal partner_init_put_away
|
||||
/* 31C818 802BE7F8 0200202D */ daddu $a0, $s0, $zero
|
||||
.L802BE7FC:
|
||||
/* 31C81C 802BE7FC 0C03BA6E */ jal partner_put_away
|
||||
/* 31C820 802BE800 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 31C824 802BE804 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 31C828 802BE808 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 31C82C 802BE80C 0002102B */ sltu $v0, $zero, $v0
|
||||
/* 31C830 802BE810 03E00008 */ jr $ra
|
||||
/* 31C834 802BE814 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,66 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BEA24_31CA44
|
||||
/* 31CA44 802BEA24 27BDFFD8 */ addiu $sp, $sp, -0x28
|
||||
/* 31CA48 802BEA28 AFB10014 */ sw $s1, 0x14($sp)
|
||||
/* 31CA4C 802BEA2C 0080882D */ daddu $s1, $a0, $zero
|
||||
/* 31CA50 802BEA30 3C04802C */ lui $a0, %hi(D_802BEC54)
|
||||
/* 31CA54 802BEA34 2484EC54 */ addiu $a0, $a0, %lo(D_802BEC54)
|
||||
/* 31CA58 802BEA38 AFB20018 */ sw $s2, 0x18($sp)
|
||||
/* 31CA5C 802BEA3C 3C128011 */ lui $s2, %hi(gPlayerStatus)
|
||||
/* 31CA60 802BEA40 2652EFC8 */ addiu $s2, $s2, %lo(gPlayerStatus)
|
||||
/* 31CA64 802BEA44 3C028011 */ lui $v0, %hi(gPartnerActionStatus)
|
||||
/* 31CA68 802BEA48 2442EBB0 */ addiu $v0, $v0, %lo(gPartnerActionStatus)
|
||||
/* 31CA6C 802BEA4C AFBF0020 */ sw $ra, 0x20($sp)
|
||||
/* 31CA70 802BEA50 AFB3001C */ sw $s3, 0x1c($sp)
|
||||
/* 31CA74 802BEA54 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 31CA78 802BEA58 AC800000 */ sw $zero, ($a0)
|
||||
/* 31CA7C 802BEA5C 80430000 */ lb $v1, ($v0)
|
||||
/* 31CA80 802BEA60 10600024 */ beqz $v1, .L802BEAF4
|
||||
/* 31CA84 802BEA64 0040982D */ daddu $s3, $v0, $zero
|
||||
/* 31CA88 802BEA68 24020002 */ addiu $v0, $zero, 2
|
||||
/* 31CA8C 802BEA6C 14620002 */ bne $v1, $v0, .L802BEA78
|
||||
/* 31CA90 802BEA70 24020001 */ addiu $v0, $zero, 1
|
||||
/* 31CA94 802BEA74 AC820000 */ sw $v0, ($a0)
|
||||
.L802BEA78:
|
||||
/* 31CA98 802BEA78 3C10802C */ lui $s0, %hi(D_802BEC64)
|
||||
/* 31CA9C 802BEA7C 2610EC64 */ addiu $s0, $s0, %lo(D_802BEC64)
|
||||
/* 31CAA0 802BEA80 8E020000 */ lw $v0, ($s0)
|
||||
/* 31CAA4 802BEA84 50400005 */ beql $v0, $zero, .L802BEA9C
|
||||
/* 31CAA8 802BEA88 24040284 */ addiu $a0, $zero, 0x284
|
||||
/* 31CAAC 802BEA8C 0C038069 */ jal enable_player_input
|
||||
/* 31CAB0 802BEA90 00000000 */ nop
|
||||
/* 31CAB4 802BEA94 AE000000 */ sw $zero, ($s0)
|
||||
/* 31CAB8 802BEA98 24040284 */ addiu $a0, $zero, 0x284
|
||||
.L802BEA9C:
|
||||
/* 31CABC 802BEA9C 8E420000 */ lw $v0, ($s2)
|
||||
/* 31CAC0 802BEAA0 2403FFFD */ addiu $v1, $zero, -3
|
||||
/* 31CAC4 802BEAA4 3C01802C */ lui $at, %hi(D_802BEB40_31CB60)
|
||||
/* 31CAC8 802BEAA8 AC20EB40 */ sw $zero, %lo(D_802BEB40_31CB60)($at)
|
||||
/* 31CACC 802BEAAC 00431024 */ and $v0, $v0, $v1
|
||||
/* 31CAD0 802BEAB0 AE420000 */ sw $v0, ($s2)
|
||||
/* 31CAD4 802BEAB4 8E220000 */ lw $v0, ($s1)
|
||||
/* 31CAD8 802BEAB8 2403F7FF */ addiu $v1, $zero, -0x801
|
||||
/* 31CADC 802BEABC AE20001C */ sw $zero, 0x1c($s1)
|
||||
/* 31CAE0 802BEAC0 00431024 */ and $v0, $v0, $v1
|
||||
/* 31CAE4 802BEAC4 2403FFBF */ addiu $v1, $zero, -0x41
|
||||
/* 31CAE8 802BEAC8 00431024 */ and $v0, $v0, $v1
|
||||
/* 31CAEC 802BEACC 0C05271B */ jal sfx_stop_sound
|
||||
/* 31CAF0 802BEAD0 AE220000 */ sw $v0, ($s1)
|
||||
/* 31CAF4 802BEAD4 0C039769 */ jal set_action_state
|
||||
/* 31CAF8 802BEAD8 0000202D */ daddu $a0, $zero, $zero
|
||||
/* 31CAFC 802BEADC 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31CB00 802BEAE0 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 31CB04 802BEAE4 0C00EB6B */ jal disable_npc_blur
|
||||
/* 31CB08 802BEAE8 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 31CB0C 802BEAEC A2600003 */ sb $zero, 3($s3)
|
||||
/* 31CB10 802BEAF0 A2600000 */ sb $zero, ($s3)
|
||||
.L802BEAF4:
|
||||
/* 31CB14 802BEAF4 8FBF0020 */ lw $ra, 0x20($sp)
|
||||
/* 31CB18 802BEAF8 8FB3001C */ lw $s3, 0x1c($sp)
|
||||
/* 31CB1C 802BEAFC 8FB20018 */ lw $s2, 0x18($sp)
|
||||
/* 31CB20 802BEB00 8FB10014 */ lw $s1, 0x14($sp)
|
||||
/* 31CB24 802BEB04 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 31CB28 802BEB08 03E00008 */ jr $ra
|
||||
/* 31CB2C 802BEB0C 27BD0028 */ addiu $sp, $sp, 0x28
|
@ -1,17 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BEB10_31CB30
|
||||
/* 31CB30 802BEB10 3C02802C */ lui $v0, %hi(D_802BEC54)
|
||||
/* 31CB34 802BEB14 8C42EC54 */ lw $v0, %lo(D_802BEC54)($v0)
|
||||
/* 31CB38 802BEB18 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 31CB3C 802BEB1C 10400005 */ beqz $v0, .L802BEB34
|
||||
/* 31CB40 802BEB20 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 31CB44 802BEB24 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31CB48 802BEB28 00000000 */ nop
|
||||
/* 31CB4C 802BEB2C 0C03ACC5 */ jal partner_use_ability
|
||||
/* 31CB50 802BEB30 00000000 */ nop
|
||||
.L802BEB34:
|
||||
/* 31CB54 802BEB34 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 31CB58 802BEB38 03E00008 */ jr $ra
|
||||
/* 31CB5C 802BEB3C 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD100_319670
|
||||
/* 319670 802BD100 24020025 */ addiu $v0, $zero, 0x25
|
||||
/* 319674 802BD104 A48200A8 */ sh $v0, 0xa8($a0)
|
||||
/* 319678 802BD108 24020028 */ addiu $v0, $zero, 0x28
|
||||
/* 31967C 802BD10C A48200A6 */ sh $v0, 0xa6($a0)
|
||||
/* 319680 802BD110 3C01802C */ lui $at, %hi(D_802BEBB0)
|
||||
/* 319684 802BD114 AC20EBB0 */ sw $zero, %lo(D_802BEBB0)($at)
|
||||
/* 319688 802BD118 3C01802C */ lui $at, %hi(D_802BEBC0_31CBE0)
|
||||
/* 31968C 802BD11C AC20EBC0 */ sw $zero, %lo(D_802BEBC0_31CBE0)($at)
|
||||
/* 319690 802BD120 3C01802C */ lui $at, %hi(D_802BEBB4)
|
||||
/* 319694 802BD124 AC20EBB4 */ sw $zero, %lo(D_802BEBB4)($at)
|
||||
/* 319698 802BD128 3C01802C */ lui $at, %hi(D_802BEBB8)
|
||||
/* 31969C 802BD12C AC20EBB8 */ sw $zero, %lo(D_802BEBB8)($at)
|
||||
/* 3196A0 802BD130 3C01802C */ lui $at, %hi(D_802BEBBC)
|
||||
/* 3196A4 802BD134 AC20EBBC */ sw $zero, %lo(D_802BEBBC)($at)
|
||||
/* 3196A8 802BD138 3C01802C */ lui $at, %hi(D_802BEBC4)
|
||||
/* 3196AC 802BD13C AC20EBC4 */ sw $zero, %lo(D_802BEBC4)($at)
|
||||
/* 3196B0 802BD140 03E00008 */ jr $ra
|
||||
/* 3196B4 802BD144 00000000 */ nop
|
@ -1,22 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD514_319A84
|
||||
/* 319A84 802BD514 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 319A88 802BD518 3C058011 */ lui $a1, %hi(D_8010C954)
|
||||
/* 319A8C 802BD51C 24A5C954 */ addiu $a1, $a1, %lo(D_8010C954)
|
||||
/* 319A90 802BD520 AFBF0010 */ sw $ra, 0x10($sp)
|
||||
/* 319A94 802BD524 8CA20000 */ lw $v0, ($a1)
|
||||
/* 319A98 802BD528 10400008 */ beqz $v0, .L802BD54C
|
||||
/* 319A9C 802BD52C 00000000 */ nop
|
||||
/* 319AA0 802BD530 3C03802C */ lui $v1, %hi(D_802BEAAC_31B01C)
|
||||
/* 319AA4 802BD534 8C63EAAC */ lw $v1, %lo(D_802BEAAC_31B01C)($v1)
|
||||
/* 319AA8 802BD538 8C620008 */ lw $v0, 8($v1)
|
||||
/* 319AAC 802BD53C ACA00000 */ sw $zero, ($a1)
|
||||
/* 319AB0 802BD540 AC820000 */ sw $v0, ($a0)
|
||||
/* 319AB4 802BD544 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 319AB8 802BD548 AC600004 */ sw $zero, 4($v1)
|
||||
.L802BD54C:
|
||||
/* 319ABC 802BD54C 8FBF0010 */ lw $ra, 0x10($sp)
|
||||
/* 319AC0 802BD550 03E00008 */ jr $ra
|
||||
/* 319AC4 802BD554 27BD0018 */ addiu $sp, $sp, 0x18
|
@ -1,71 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BD558_319AC8
|
||||
/* 319AC8 802BD558 27BDFFA8 */ addiu $sp, $sp, -0x58
|
||||
/* 319ACC 802BD55C AFB00048 */ sw $s0, 0x48($sp)
|
||||
/* 319AD0 802BD560 3C108011 */ lui $s0, %hi(gPlayerStatus)
|
||||
/* 319AD4 802BD564 2610EFC8 */ addiu $s0, $s0, %lo(gPlayerStatus)
|
||||
/* 319AD8 802BD568 AFBF0050 */ sw $ra, 0x50($sp)
|
||||
/* 319ADC 802BD56C AFB1004C */ sw $s1, 0x4c($sp)
|
||||
/* 319AE0 802BD570 860200B0 */ lh $v0, 0xb0($s0)
|
||||
/* 319AE4 802BD574 3C013FE0 */ lui $at, 0x3fe0
|
||||
/* 319AE8 802BD578 44810800 */ mtc1 $at, $f1
|
||||
/* 319AEC 802BD57C 44800000 */ mtc1 $zero, $f0
|
||||
/* 319AF0 802BD580 44823000 */ mtc1 $v0, $f6
|
||||
/* 319AF4 802BD584 00000000 */ nop
|
||||
/* 319AF8 802BD588 468031A0 */ cvt.s.w $f6, $f6
|
||||
/* 319AFC 802BD58C 460030A1 */ cvt.d.s $f2, $f6
|
||||
/* 319B00 802BD590 46201082 */ mul.d $f2, $f2, $f0
|
||||
/* 319B04 802BD594 00000000 */ nop
|
||||
/* 319B08 802BD598 0200202D */ daddu $a0, $s0, $zero
|
||||
/* 319B0C 802BD59C 27A50028 */ addiu $a1, $sp, 0x28
|
||||
/* 319B10 802BD5A0 27A6002C */ addiu $a2, $sp, 0x2c
|
||||
/* 319B14 802BD5A4 27A70030 */ addiu $a3, $sp, 0x30
|
||||
/* 319B18 802BD5A8 3C013F00 */ lui $at, 0x3f00
|
||||
/* 319B1C 802BD5AC 44810000 */ mtc1 $at, $f0
|
||||
/* 319B20 802BD5B0 C6040028 */ lwc1 $f4, 0x28($s0)
|
||||
/* 319B24 802BD5B4 46003182 */ mul.s $f6, $f6, $f0
|
||||
/* 319B28 802BD5B8 00000000 */ nop
|
||||
/* 319B2C 802BD5BC C600002C */ lwc1 $f0, 0x2c($s0)
|
||||
/* 319B30 802BD5C0 27A20034 */ addiu $v0, $sp, 0x34
|
||||
/* 319B34 802BD5C4 E7A40028 */ swc1 $f4, 0x28($sp)
|
||||
/* 319B38 802BD5C8 C6040030 */ lwc1 $f4, 0x30($s0)
|
||||
/* 319B3C 802BD5CC 46000021 */ cvt.d.s $f0, $f0
|
||||
/* 319B40 802BD5D0 46220000 */ add.d $f0, $f0, $f2
|
||||
/* 319B44 802BD5D4 E7A40030 */ swc1 $f4, 0x30($sp)
|
||||
/* 319B48 802BD5D8 E7A60034 */ swc1 $f6, 0x34($sp)
|
||||
/* 319B4C 802BD5DC 46200020 */ cvt.s.d $f0, $f0
|
||||
/* 319B50 802BD5E0 E7A0002C */ swc1 $f0, 0x2c($sp)
|
||||
/* 319B54 802BD5E4 AFA20010 */ sw $v0, 0x10($sp)
|
||||
/* 319B58 802BD5E8 27A20038 */ addiu $v0, $sp, 0x38
|
||||
/* 319B5C 802BD5EC AFA20014 */ sw $v0, 0x14($sp)
|
||||
/* 319B60 802BD5F0 27A2003C */ addiu $v0, $sp, 0x3c
|
||||
/* 319B64 802BD5F4 AFA20018 */ sw $v0, 0x18($sp)
|
||||
/* 319B68 802BD5F8 27A20040 */ addiu $v0, $sp, 0x40
|
||||
/* 319B6C 802BD5FC AFA2001C */ sw $v0, 0x1c($sp)
|
||||
/* 319B70 802BD600 27A20044 */ addiu $v0, $sp, 0x44
|
||||
/* 319B74 802BD604 0C03791B */ jal player_raycast_below_cam_relative
|
||||
/* 319B78 802BD608 AFA20020 */ sw $v0, 0x20($sp)
|
||||
/* 319B7C 802BD60C 0040882D */ daddu $s1, $v0, $zero
|
||||
/* 319B80 802BD610 0C016F6A */ jal get_collider_type_by_id
|
||||
/* 319B84 802BD614 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 319B88 802BD618 304200FF */ andi $v0, $v0, 0xff
|
||||
/* 319B8C 802BD61C 2442FFFE */ addiu $v0, $v0, -2
|
||||
/* 319B90 802BD620 2C420002 */ sltiu $v0, $v0, 2
|
||||
/* 319B94 802BD624 10400008 */ beqz $v0, .L802BD648
|
||||
/* 319B98 802BD628 24020002 */ addiu $v0, $zero, 2
|
||||
/* 319B9C 802BD62C A20200BF */ sb $v0, 0xbf($s0)
|
||||
/* 319BA0 802BD630 8E020000 */ lw $v0, ($s0)
|
||||
/* 319BA4 802BD634 24030015 */ addiu $v1, $zero, 0x15
|
||||
/* 319BA8 802BD638 3C01802C */ lui $at, %hi(D_802BEBC0_31CBE0)
|
||||
/* 319BAC 802BD63C AC23EBC0 */ sw $v1, %lo(D_802BEBC0_31CBE0)($at)
|
||||
/* 319BB0 802BD640 34420800 */ ori $v0, $v0, 0x800
|
||||
/* 319BB4 802BD644 AE020000 */ sw $v0, ($s0)
|
||||
.L802BD648:
|
||||
/* 319BB8 802BD648 0220102D */ daddu $v0, $s1, $zero
|
||||
/* 319BBC 802BD64C 8FBF0050 */ lw $ra, 0x50($sp)
|
||||
/* 319BC0 802BD650 8FB1004C */ lw $s1, 0x4c($sp)
|
||||
/* 319BC4 802BD654 8FB00048 */ lw $s0, 0x48($sp)
|
||||
/* 319BC8 802BD658 03E00008 */ jr $ra
|
||||
/* 319BCC 802BD65C 27BD0058 */ addiu $sp, $sp, 0x58
|
@ -1,57 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BE90C_31AE7C
|
||||
/* 31AE7C 802BE90C 3C02802C */ lui $v0, %hi(D_802BEBB0)
|
||||
/* 31AE80 802BE910 8C42EBB0 */ lw $v0, %lo(D_802BEBB0)($v0)
|
||||
/* 31AE84 802BE914 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 31AE88 802BE918 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 31AE8C 802BE91C 0080802D */ daddu $s0, $a0, $zero
|
||||
/* 31AE90 802BE920 AFB10014 */ sw $s1, 0x14($sp)
|
||||
/* 31AE94 802BE924 3C118011 */ lui $s1, %hi(gPartnerActionStatus)
|
||||
/* 31AE98 802BE928 2631EBB0 */ addiu $s1, $s1, %lo(gPartnerActionStatus)
|
||||
/* 31AE9C 802BE92C 10400021 */ beqz $v0, .L802BE9B4
|
||||
/* 31AEA0 802BE930 AFBF0018 */ sw $ra, 0x18($sp)
|
||||
/* 31AEA4 802BE934 3C02802C */ lui $v0, %hi(D_802BEBB8)
|
||||
/* 31AEA8 802BE938 8C42EBB8 */ lw $v0, %lo(D_802BEBB8)($v0)
|
||||
/* 31AEAC 802BE93C 10400003 */ beqz $v0, .L802BE94C
|
||||
/* 31AEB0 802BE940 00000000 */ nop
|
||||
/* 31AEB4 802BE944 0C038050 */ jal enable_player_static_collisions
|
||||
/* 31AEB8 802BE948 00000000 */ nop
|
||||
.L802BE94C:
|
||||
/* 31AEBC 802BE94C 3C02802C */ lui $v0, %hi(D_802BEBB4)
|
||||
/* 31AEC0 802BE950 8C42EBB4 */ lw $v0, %lo(D_802BEBB4)($v0)
|
||||
/* 31AEC4 802BE954 10400003 */ beqz $v0, .L802BE964
|
||||
/* 31AEC8 802BE958 00000000 */ nop
|
||||
/* 31AECC 802BE95C 0C038069 */ jal enable_player_input
|
||||
/* 31AED0 802BE960 00000000 */ nop
|
||||
.L802BE964:
|
||||
/* 31AED4 802BE964 0C039769 */ jal set_action_state
|
||||
/* 31AED8 802BE968 0000202D */ daddu $a0, $zero, $zero
|
||||
/* 31AEDC 802BE96C 26230018 */ addiu $v1, $s1, 0x18
|
||||
/* 31AEE0 802BE970 0200102D */ daddu $v0, $s0, $zero
|
||||
/* 31AEE4 802BE974 26040340 */ addiu $a0, $s0, 0x340
|
||||
.L802BE978:
|
||||
/* 31AEE8 802BE978 8C450000 */ lw $a1, ($v0)
|
||||
/* 31AEEC 802BE97C 8C460004 */ lw $a2, 4($v0)
|
||||
/* 31AEF0 802BE980 8C470008 */ lw $a3, 8($v0)
|
||||
/* 31AEF4 802BE984 8C48000C */ lw $t0, 0xc($v0)
|
||||
/* 31AEF8 802BE988 AC650000 */ sw $a1, ($v1)
|
||||
/* 31AEFC 802BE98C AC660004 */ sw $a2, 4($v1)
|
||||
/* 31AF00 802BE990 AC670008 */ sw $a3, 8($v1)
|
||||
/* 31AF04 802BE994 AC68000C */ sw $t0, 0xc($v1)
|
||||
/* 31AF08 802BE998 24420010 */ addiu $v0, $v0, 0x10
|
||||
/* 31AF0C 802BE99C 1444FFF6 */ bne $v0, $a0, .L802BE978
|
||||
/* 31AF10 802BE9A0 24630010 */ addiu $v1, $v1, 0x10
|
||||
/* 31AF14 802BE9A4 24020001 */ addiu $v0, $zero, 1
|
||||
/* 31AF18 802BE9A8 A2220001 */ sb $v0, 1($s1)
|
||||
/* 31AF1C 802BE9AC 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31AF20 802BE9B0 0200202D */ daddu $a0, $s0, $zero
|
||||
.L802BE9B4:
|
||||
/* 31AF24 802BE9B4 24020004 */ addiu $v0, $zero, 4
|
||||
/* 31AF28 802BE9B8 A2220003 */ sb $v0, 3($s1)
|
||||
/* 31AF2C 802BE9BC 8FBF0018 */ lw $ra, 0x18($sp)
|
||||
/* 31AF30 802BE9C0 8FB10014 */ lw $s1, 0x14($sp)
|
||||
/* 31AF34 802BE9C4 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 31AF38 802BE9C8 03E00008 */ jr $ra
|
||||
/* 31AF3C 802BE9CC 27BD0020 */ addiu $sp, $sp, 0x20
|
@ -1,56 +0,0 @@
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
|
||||
glabel func_802BE9D0_31AF40
|
||||
/* 31AF40 802BE9D0 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 31AF44 802BE9D4 AFB00010 */ sw $s0, 0x10($sp)
|
||||
/* 31AF48 802BE9D8 3C108011 */ lui $s0, %hi(gPartnerActionStatus)
|
||||
/* 31AF4C 802BE9DC 2610EBB0 */ addiu $s0, $s0, %lo(gPartnerActionStatus)
|
||||
/* 31AF50 802BE9E0 AFBF0018 */ sw $ra, 0x18($sp)
|
||||
/* 31AF54 802BE9E4 AFB10014 */ sw $s1, 0x14($sp)
|
||||
/* 31AF58 802BE9E8 82020001 */ lb $v0, 1($s0)
|
||||
/* 31AF5C 802BE9EC 10400023 */ beqz $v0, .L802BEA7C
|
||||
/* 31AF60 802BE9F0 0080882D */ daddu $s1, $a0, $zero
|
||||
/* 31AF64 802BE9F4 3C02802C */ lui $v0, %hi(D_802BEBB8)
|
||||
/* 31AF68 802BE9F8 8C42EBB8 */ lw $v0, %lo(D_802BEBB8)($v0)
|
||||
/* 31AF6C 802BE9FC 10400003 */ beqz $v0, .L802BEA0C
|
||||
/* 31AF70 802BEA00 00000000 */ nop
|
||||
/* 31AF74 802BEA04 0C038045 */ jal disable_player_static_collisions
|
||||
/* 31AF78 802BEA08 00000000 */ nop
|
||||
.L802BEA0C:
|
||||
/* 31AF7C 802BEA0C 3C02802C */ lui $v0, %hi(D_802BEBB4)
|
||||
/* 31AF80 802BEA10 8C42EBB4 */ lw $v0, %lo(D_802BEBB4)($v0)
|
||||
/* 31AF84 802BEA14 10400003 */ beqz $v0, .L802BEA24
|
||||
/* 31AF88 802BEA18 00000000 */ nop
|
||||
/* 31AF8C 802BEA1C 0C03805E */ jal disable_player_input
|
||||
/* 31AF90 802BEA20 00000000 */ nop
|
||||
.L802BEA24:
|
||||
/* 31AF94 802BEA24 0C039769 */ jal set_action_state
|
||||
/* 31AF98 802BEA28 24040021 */ addiu $a0, $zero, 0x21
|
||||
/* 31AF9C 802BEA2C 0220182D */ daddu $v1, $s1, $zero
|
||||
/* 31AFA0 802BEA30 26020018 */ addiu $v0, $s0, 0x18
|
||||
/* 31AFA4 802BEA34 26040358 */ addiu $a0, $s0, 0x358
|
||||
.L802BEA38:
|
||||
/* 31AFA8 802BEA38 8C450000 */ lw $a1, ($v0)
|
||||
/* 31AFAC 802BEA3C 8C460004 */ lw $a2, 4($v0)
|
||||
/* 31AFB0 802BEA40 8C470008 */ lw $a3, 8($v0)
|
||||
/* 31AFB4 802BEA44 8C48000C */ lw $t0, 0xc($v0)
|
||||
/* 31AFB8 802BEA48 AC650000 */ sw $a1, ($v1)
|
||||
/* 31AFBC 802BEA4C AC660004 */ sw $a2, 4($v1)
|
||||
/* 31AFC0 802BEA50 AC670008 */ sw $a3, 8($v1)
|
||||
/* 31AFC4 802BEA54 AC68000C */ sw $t0, 0xc($v1)
|
||||
/* 31AFC8 802BEA58 24420010 */ addiu $v0, $v0, 0x10
|
||||
/* 31AFCC 802BEA5C 1444FFF6 */ bne $v0, $a0, .L802BEA38
|
||||
/* 31AFD0 802BEA60 24630010 */ addiu $v1, $v1, 0x10
|
||||
/* 31AFD4 802BEA64 0220202D */ daddu $a0, $s1, $zero
|
||||
/* 31AFD8 802BEA68 A2000003 */ sb $zero, 3($s0)
|
||||
/* 31AFDC 802BEA6C 0C03BD17 */ jal partner_clear_player_tracking
|
||||
/* 31AFE0 802BEA70 A2000000 */ sb $zero, ($s0)
|
||||
/* 31AFE4 802BEA74 0C03ACC5 */ jal partner_use_ability
|
||||
/* 31AFE8 802BEA78 00000000 */ nop
|
||||
.L802BEA7C:
|
||||
/* 31AFEC 802BEA7C 8FBF0018 */ lw $ra, 0x18($sp)
|
||||
/* 31AFF0 802BEA80 8FB10014 */ lw $s1, 0x14($sp)
|
||||
/* 31AFF4 802BEA84 8FB00010 */ lw $s0, 0x10($sp)
|
||||
/* 31AFF8 802BEA88 03E00008 */ jr $ra
|
||||
/* 31AFFC 802BEA8C 27BD0020 */ addiu $sp, $sp, 0x20
|
@ -2099,7 +2099,7 @@ segments:
|
||||
overlay: True
|
||||
subsegments:
|
||||
- [0x317e50, c, bombette]
|
||||
- [0x3195d0, data]
|
||||
- [0x3195d0]
|
||||
- type: code
|
||||
dir: world/partner
|
||||
name: world_partner_parakarry
|
||||
|
@ -1121,9 +1121,11 @@ D_802B6EEC = 0x802B6EEC;
|
||||
D_802B6EF0 = 0x802B6EF0;
|
||||
D_802B6EF4 = 0x802B6EF4;
|
||||
mdl_clearRenderTasks = 0x802B7E00;
|
||||
D_802BD600 = 0x802BD600;
|
||||
D_802BDF30 = 0x802BDF30;
|
||||
D_802BDF34 = 0x802BDF34;
|
||||
D_802BDF38 = 0x802BDF38;
|
||||
D_802BDF40 = 0x802BDF40;
|
||||
D_802BDF60 = 0x802BDF60;
|
||||
D_802BE0C0 = 0x802BE0C0;
|
||||
D_802BE0C4 = 0x802BE0C4;
|
||||
@ -1142,6 +1144,7 @@ D_802BE92C = 0x802BE92C;
|
||||
D_802BE930 = 0x802BE930;
|
||||
D_802BE934 = 0x802BE934;
|
||||
D_802BE938 = 0x802BE938;
|
||||
D_802BE940 = 0x802BE940;
|
||||
D_802BEBB0 = 0x802BEBB0;
|
||||
D_802BEBB4 = 0x802BEBB4;
|
||||
D_802BEBB8 = 0x802BEBB8;
|
||||
|
Loading…
Reference in New Issue
Block a user