diff options
| author | inspectredc <78732756+inspectredc@users.noreply.github.com> | 2024-04-18 00:13:31 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-17 16:13:31 -0700 |
| commit | 30aaa1356fb359c25963fc1d2384a2a928bde32d (patch) | |
| tree | aed85f48c157b9f397137afa04bbfe76942c4103 /src | |
| parent | e6ea51bc3dcf69310c5dcdae5b812dc74e628aaf (diff) | |
ac_bee OK (#175)
* ac_bee OK
* fix warning
* change sAdo_OngenPos back
* and in code..
* fix linker script stuff
Diffstat (limited to 'src')
| -rw-r--r-- | src/objects/act_bee/act_bee.c | 16 | ||||
| -rw-r--r-- | src/objects/act_bee/act_bee.h | 20 | ||||
| -rw-r--r-- | src/overlays/actors/ovl_Bee/ac_bee.c | 326 | ||||
| -rw-r--r-- | src/overlays/actors/ovl_Bee/ac_bee.h | 43 | ||||
| -rw-r--r-- | src/overlays/actors/ovl_Fuusen/ac_fuusen.c | 5 | ||||
| -rw-r--r-- | src/overlays/actors/ovl_Koinobori/ac_koinobori.c | 2 | ||||
| -rw-r--r-- | src/overlays/actors/player_actor/m_player.h | 9 |
7 files changed, 399 insertions, 22 deletions
diff --git a/src/objects/act_bee/act_bee.c b/src/objects/act_bee/act_bee.c new file mode 100644 index 0000000..8d0b70d --- /dev/null +++ b/src/objects/act_bee/act_bee.c @@ -0,0 +1,16 @@ +#include "act_bee.h" + +#include "assets/jp/objects/act_bee/act_bee_v.vtx.inc.c" +#include "assets/jp/objects/act_bee/act_bee_C_model.gfx.inc.c" +#include "assets/jp/objects/act_bee/act_bee_B_model.gfx.inc.c" +#include "assets/jp/objects/act_bee/act_bee_A_model.gfx.inc.c" +u8 act_bee_tex_txt[] = { +#include "assets/jp/objects/act_bee/act_bee_tex_txt.i4.inc.c" +}; +#include "assets/jp/objects/act_bee/cKF_ckcb_r_act_bee_tbl.inc.c" +#include "assets/jp/objects/act_bee/cKF_kn_act_bee_tbl.inc.c" +#include "assets/jp/objects/act_bee/cKF_c_act_bee_tbl.inc.c" +#include "assets/jp/objects/act_bee/cKF_ds_act_bee_tbl.inc.c" +#include "assets/jp/objects/act_bee/cKF_ba_r_act_bee.inc.c" +#include "assets/jp/objects/act_bee/cKF_je_r_act_bee_tbl.inc.c" +#include "assets/jp/objects/act_bee/cKF_bs_r_act_bee.inc.c" diff --git a/src/objects/act_bee/act_bee.h b/src/objects/act_bee/act_bee.h new file mode 100644 index 0000000..5bde70c --- /dev/null +++ b/src/objects/act_bee/act_bee.h @@ -0,0 +1,20 @@ +#ifndef OBJECT_ACT_BEE_H +#define OBJECT_ACT_BEE_H + +#include "gbi.h" +#include "c_keyframe.h" + +extern Vtx act_bee_v[]; +extern Gfx act_bee_C_model[]; +extern Gfx act_bee_B_model[]; +extern Gfx act_bee_A_model[]; +extern u8 act_bee_tex_txt[]; +extern u8 cKF_ckcb_r_act_bee_tbl[]; +extern s16 cKF_kn_act_bee_tbl[]; +extern s16 cKF_c_act_bee_tbl[]; +extern Keyframe cKF_ds_act_bee_tbl[]; +extern BaseAnimationR cKF_ba_r_act_bee; +extern JointElemR cKF_je_r_act_bee_tbl[]; +extern BaseSkeletonR cKF_bs_r_act_bee; + +#endif diff --git a/src/overlays/actors/ovl_Bee/ac_bee.c b/src/overlays/actors/ovl_Bee/ac_bee.c index 2962e9e..5aae733 100644 --- a/src/overlays/actors/ovl_Bee/ac_bee.c +++ b/src/overlays/actors/ovl_Bee/ac_bee.c @@ -2,19 +2,29 @@ #include "m_actor_dlftbls.h" #include "m_object.h" #include "overlays/gamestates/ovl_play/m_play.h" +#include "overlays/actors/player_actor/m_player.h" +#include "m_field_info.h" +#include "libc/math.h" +#include "m_player_lib.h" +#include "m_rcp.h" +#include "macros.h" +#include "audio.h" + +#include "objects/act_bee/act_bee.h" + +#define THIS ((Bee*)thisx) void aBEE_actor_ct(Actor* thisx, Game_Play* game_play); void func_80A93DD0_jp(Actor* thisx, Game_Play* game_play); void aBEE_actor_move(Actor* thisx, Game_Play* game_play); void aBEE_actor_draw(Actor* thisx, Game_Play* game_play); -#if 0 ActorProfile Bee_Profile = { /* */ ACTOR_BEE, /* */ ACTOR_PART_4, /* */ ACTOR_FLAG_10, /* */ 0x0000, - /* */ OBJECT_392, + /* */ OBJECT_ACT_BEE, /* */ sizeof(Bee), /* */ aBEE_actor_ct, /* */ func_80A93DD0_jp, @@ -22,28 +32,314 @@ ActorProfile Bee_Profile = { /* */ aBEE_actor_draw, /* */ NULL, }; -#endif -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/aBEE_actor_ct.s") +void aBEE_setupAction(Bee*, s32, Game_Play*); + +void aBEE_actor_ct(Actor* thisx, Game_Play* game_play) { + Bee* this = THIS; + SkeletonInfoR* skeletonInfo = &this->skeletonInfo; + // Name Based on ac_fuusen + xyz_t InitSize = { 0.0f, 0.0f, 0.0f }; + + cKF_SkeletonInfo_R_ct(&this->skeletonInfo, &cKF_bs_r_act_bee, &cKF_ba_r_act_bee, this->jointTable, + this->morphTable); + cKF_SkeletonInfo_R_init_standard_repeat(&this->skeletonInfo, Lib_SegmentedToVirtual(&cKF_ba_r_act_bee), 0); + skeletonInfo->frameControl.currentFrame = 90.0f; + cKF_SkeletonInfo_R_play(skeletonInfo); + skeletonInfo->frameControl.speed = 0.0f; + this->texScrollCounter2 = -0x8000; + this->shapeFactor = 90.0f; + xyz_t_move(&this->actor.scale, &InitSize); + this->segment = game_play->objectExchangeBank.status[this->actor.unk_026].segment; + this->actor.update = aBEE_actor_move; + aBEE_setupAction(this, BEE_PROCESS_APPEAR, game_play); +} + +// Original name unknown. +void func_80A93DD0_jp(UNUSED Actor* thisx, UNUSED Game_Play* game_play) { +} + +void aBEE_appear_init(Bee* this, UNUSED Game_Play* game_play) { + xyz_t Size_data = { 0.01f, 0.01f, 0.01f }; + + xyz_t_move(&this->targetScale, &Size_data); + common_data.unk_10A39 = 1; +} + +// Original name unknown. +void func_80A93E38_jp(UNUSED Bee* this, UNUSED Game_Play* game_play) { +} + +void aBEE_disappear_init(Bee* this, UNUSED Game_Play* game_play) { + + this->actor.speed = 9.7f; + this->actor.shape.rot.x = this->actor.shape.rot.z = 0; +} + +void aBEE_appear(Bee* this, Game_Play* game_play) { + Player* player = get_player_actor_withoutCheck(game_play); + + this->targetHeight = player->actor.world.pos.y + 50.0f; + this->alpha += 6; + if (this->alpha >= 255) { + this->alpha = 255; + } + this->actor.shape.rot.x = 0x7FFF; + this->actor.shape.rot.z += 0x1000; + + // FAKE - Could use pointer to alpha throughout + if (1) {} + + if (this->alpha == 255) { + aBEE_setupAction(this, BEE_PROCESS_1, game_play); + } +} + +// Original name unknown. Possibly one of or a combination of aBEE_fly and aBEE_caught +void func_80A93EFC_jp(Bee* this, Game_Play* game_play) { + UNUSED UNK_TYPE1 pad[0x4]; + Player* player; + s16 angle; + f32 yRot; + f32 stepTargetOffset; + Actor* sp68; + s32 sp64; + xyz_t sp58; + f32 targetShapeFactor = 0.0f; + + player = get_player_actor_withoutCheck(game_play); + sp68 = func_800B3B74_jp(); + sp64 = func_800B56D0_jp(); + add_calc_short_angle2(&this->actor.shape.rot.z, 0, 0.3f, 2000, 0); + add_calc_short_angle2(&this->actor.shape.rot.x, 0, 0.3f, 2000, 0); + if (&this->actor != sp68) { + if (this->actor.shape.rot.x < 0x1001) { + if (this->state != BEE_STATE_2) { + + if (((get_player_actor_withoutCheck((Game_Play*)gamePT) + ->unk_1234((Player*)get_player_actor_withoutCheck((Game_Play*)gamePT), (Game_Play*)gamePT) > + 0.0f) || + (func_800B3B24_jp(&sp58) != 0)) && + (this->actor.xzDistToPlayer < 40.0f)) { + get_player_actor_withoutCheck((Game_Play*)gamePT) + ->unk_1238((Player*)get_player_actor_withoutCheck((Game_Play*)gamePT), (Game_Play*)gamePT, + &this->actor, 1); + } else { + get_player_actor_withoutCheck((Game_Play*)gamePT) + ->unk_1230((Player*)get_player_actor_withoutCheck((Game_Play*)gamePT), (Game_Play*)gamePT, + &this->actor, 1, &this->actor.world.pos, 24.0f); + } + } + } else { + return; + } + } + + if (&this->actor == sp68) { + if (this->unk_448 == 0) { + Clip_unk_07C_unk_0_arg0 sp3C; + sp3C.unk_00 = 8; + xyz_t_move(&sp3C.unk_04, &this->actor.world.pos); + sp3C.unk_10 = 0; + sp3C.unk_14 = game_play; + this->unk_448 = common_data.clip.unk_07C->unk_0(&sp3C, 1); + } else if (func_800B3BBC_jp(this->unk_448, 0) != 0) { + aBEE_setupAction(this, BEE_PROCESS_DISAPPEAR, game_play); + return; + } + } + + if (this->unk_448 == 0) { + if (func_800B5EA4_jp(game_play) != 0) { + this->state = BEE_STATE_1; + } + + if (this->state != BEE_STATE_2) { + if ((this->state != BEE_STATE_0) || (this->actor.xzDistToPlayer < 30.0f)) { + this->state = BEE_STATE_1; + if (sp64 == 1) { + func_800B2AD0_jp((Game_Play*)gamePT); + this->state = BEE_STATE_2; + } else if (sp64 == 2) { + aBEE_setupAction(this, BEE_PROCESS_DISAPPEAR, game_play); + return; + } + } + } else if ((func_800B1CBC_jp((Game_Play*)gamePT) == 0x5E) != 0) { + if (func_800B5718_jp() != 0) { + aBEE_setupAction(this, BEE_PROCESS_DISAPPEAR, game_play); + return; + } + } else { + func_800B2AD0_jp((Game_Play*)gamePT); + } + } + stepTargetOffset = fabsf(90.0f - this->shapeFactor); + this->targetRotStep = 1600; + if (this->state != BEE_STATE_0) { + this->targetRotStep = 5000; + } + stepTargetOffset *= 7.5f; + add_calc_short_angle2(&this->rotStep, this->targetRotStep - (s16)(stepTargetOffset), 0.4f, 500, 0); + add_calc_short_angle2(&this->actor.world.rot.y, this->actor.yawTowardsPlayer, 0.4f, this->rotStep, 0); + this->actor.shape.rot.y = this->actor.world.rot.y; + + angle = ABS((s16)(this->actor.world.rot.y - this->actor.yawTowardsPlayer)); + + if (angle > -0x8000) { + angle = 0; + } + + this->targetSpeed = 2.9f; + this->targetSpeed += fabsf((0x8000 - angle) / (0x8000 / 6)); + + add_calc(&this->actor.speed, this->targetSpeed, 0.3f, 0.3f, 0.0f); + this->heightAmplitudeCounter += 0x1200; + this->targetHeight = player->actor.world.pos.y + 50.0f; + this->targetHeight += sin_s(this->heightAmplitudeCounter) * 5.0f; + + yRot = this->actor.yawTowardsPlayer - this->actor.world.rot.y; + targetShapeFactor = (yRot / 30.0f) + 90.0f; + + if (targetShapeFactor < 0.0f) { + targetShapeFactor = 0.0f; + } else if (targetShapeFactor > 180.0f) { + targetShapeFactor = 180.0f; + } + add_calc(&this->shapeFactor, targetShapeFactor, 0.5f, 10.0f, 0.0f); +} + +void aBEE_disappear(Bee* this, UNUSED Game_Play* game_play) { + + this->targetScale.x = 0.03f; + this->targetScale.z = 0.03f; + this->targetScale.y = 0.03f; + this->alpha -= 30; + if (this->alpha < 0) { + this->alpha = 0; + Actor_delete(&this->actor); + } +} -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93DD0_jp.s") +void aBEE_setupAction(Bee* this, s32 processIndex, Game_Play* game_play) { + static BeeActionFunc init_proc[3] = { + aBEE_appear_init, + func_80A93E38_jp, + aBEE_disappear_init, + }; + static BeeActionFunc act_proc[3] = { + aBEE_appear, + func_80A93EFC_jp, + aBEE_disappear, + }; -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93DE0_jp.s") + this->processNum = processIndex; + this->process = act_proc[this->processNum]; + init_proc[this->processNum](this, game_play); +} -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93E38_jp.s") +// Original name unknown. +void func_80A9449C_jp(Bee* this, Game_Play* game_play) { + UNUSED UNK_TYPE1 pad[0x4]; + void* segment; -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93E48_jp.s") + segment = game_play->objectExchangeBank.status[this->actor.unk_026].segment; + if (segment != this->segment) { + SkeletonInfoR* skeletonInfo = &this->skeletonInfo; + skeletonInfo->skeleton = Lib_SegmentedToVirtual(&cKF_bs_r_act_bee); + skeletonInfo->animation = Lib_SegmentedToVirtual(&cKF_ba_r_act_bee); + this->segment = segment; + } +} -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93E6C_jp.s") +void aBEE_actor_move(Actor* thisx, Game_Play* game_play) { + // Original name unknown. + static f32 SizeFraction[3] = { + 0.1f, + 0.1f, + 0.1f, + }; + // Original name unknown. + static f32 SizeStep[3] = { + 0.005f, + 0.005f, + 0.01f, + }; + Bee* this = THIS; + SkeletonInfoR* skeletonInfo = &this->skeletonInfo; + f32 scaleFactor; -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A93EFC_jp.s") + func_80A9449C_jp(this, game_play); + sAdo_OngenPos((uintptr_t) & this->actor, 0x30, &this->actor.world.pos); + if (!(this->actor.world.pos.x < 0.0f) || !(this->actor.world.pos.z < 0.0f)) { + if ((this->state == BEE_STATE_2) || (mFI_GetPlayerWade() == 0)) { + Actor_position_moveF(&this->actor); + } + this->process(this, game_play); + if ((this->processNum == BEE_PROCESS_APPEAR) || (this->processNum == BEE_PROCESS_DISAPPEAR)) { + add_calc(&this->actor.scale.x, this->targetScale.x, SizeFraction[this->processNum], + SizeStep[this->processNum], 0.0f); + add_calc(&this->actor.scale.y, this->targetScale.y, SizeFraction[this->processNum], + SizeStep[this->processNum], 0.0f); + add_calc(&this->actor.scale.z, this->targetScale.z, SizeFraction[this->processNum], + SizeStep[this->processNum], 0.0f); + } else { + scaleFactor = fabsf(90.0f - this->shapeFactor); + this->targetScale.x = ((scaleFactor / 360.0f) + 0.75f) * 0.01f; + this->targetScale.y = ((scaleFactor / 360.0f) + 0.75f) * 0.01f; + this->targetScale.z = ((1.5f - (scaleFactor / 180.0f)) * 0.01f); + add_calc(&this->actor.scale.x, this->targetScale.x, 0.2f, 0.01f, 0.0f); + add_calc(&this->actor.scale.y, this->targetScale.y, 0.2f, 0.01f, 0.0f); + add_calc(&this->actor.scale.z, this->targetScale.z, 0.2f, 0.01f, 0.0f); + } + this->texScrollCounter1 += 1000; + this->texScrollCounter2 -= 1000; + skeletonInfo->frameControl.currentFrame = this->shapeFactor; + cKF_SkeletonInfo_R_play(skeletonInfo); + skeletonInfo->frameControl.speed = 0.0f; + add_calc(&this->actor.world.pos.y, this->targetHeight, 0.3f, 3.0f, 0.0f); + } +} -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A94408_jp.s") +#define OPEN_CUSTOM_POLY_XLU() \ + { \ + Gfx* __polyXlu = __gfxCtx->polyXlu.p; \ + int __xlu_opened = 0; \ + do { \ + } while (0) -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A94450_jp.s") +#define CLOSE_CUSTOM_POLY_XLU() \ + __gfxCtx->polyXlu.p = __polyXlu; \ + (void)__xlu_opened; \ + } \ + do { \ + } while (0) -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/func_80A9449C_jp.s") +void aBEE_actor_draw(Actor* thisx, Game_Play* game_play) { + Bee* this = THIS; + s32 mtxIndex = game_play->state.frameCounter & 1; + UNUSED UNK_TYPE1 pad[0x8]; + Gfx* texScroll; -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/aBEE_actor_move.s") + if (!(this->actor.world.pos.x < 0.0f) && !(this->actor.world.pos.z < 0.0f)) { + func_80A9449C_jp(this, game_play); + texScroll = two_tex_scroll(game_play->state.gfxCtx, 0, (s32)(sin_s(this->texScrollCounter1) * 90.0f), + (s32)(cos_s(this->texScrollCounter1) * 90.0f), 32, 32, 1, + (s32)(cos_s(this->texScrollCounter2) * 90.0f), + (s32)(sin_s(this->texScrollCounter2) * 90.0f), 32, 32); + if (texScroll != 0) { + Matrix_push(); + _texture_z_light_fog_prim_xlu(game_play->state.gfxCtx); + Setpos_HiliteReflect_xlu_init(&this->actor.world.pos, game_play); -#pragma GLOBAL_ASM("asm/jp/nonmatchings/overlays/actors/ovl_Bee/ac_bee/aBEE_actor_draw.s") + OPEN_DISPS(game_play->state.gfxCtx); + OPEN_CUSTOM_POLY_XLU(); + gDPSetPrimColor(__polyXlu++, 0, 255, 0, 0, 0, this->alpha); + gSPSegment(__polyXlu++, 0x08, texScroll); + CLOSE_CUSTOM_POLY_XLU(); + CLOSE_DISPS(game_play->state.gfxCtx); + cKF_Si3_draw_R_SV(game_play, &this->skeletonInfo, this->mtx[mtxIndex], NULL, NULL, this); + Matrix_pull(); + } + } +} diff --git a/src/overlays/actors/ovl_Bee/ac_bee.h b/src/overlays/actors/ovl_Bee/ac_bee.h index 3e8e8b8..c0f7faf 100644 --- a/src/overlays/actors/ovl_Bee/ac_bee.h +++ b/src/overlays/actors/ovl_Bee/ac_bee.h @@ -4,15 +4,54 @@ #include "ultra64.h" #include "m_actor.h" #include "unk.h" +#include "c_keyframe.h" struct Game_Play; struct Bee; +typedef enum BeeProcess { + BEE_PROCESS_APPEAR, + BEE_PROCESS_1, + BEE_PROCESS_DISAPPEAR, +} BeeProcess; + +typedef enum BeeState { + BEE_STATE_0, + BEE_STATE_1, + BEE_STATE_2, +} BeeState; + +typedef struct Clip_unk_07C_unk_0_arg0 { + /* 0x00 */ s32 unk_00; + /* 0x04 */ xyz_t unk_04; + /* 0x10 */ s32 unk_10; + /* 0x14 */ struct Game_Play* unk_14; +} Clip_unk_07C_unk_0_arg0; // size >= 0x18 + typedef void (*BeeActionFunc)(struct Bee*, struct Game_Play*); typedef struct Bee { /* 0x000 */ Actor actor; - /* 0x174 */ UNK_TYPE1 unk_174[0x2DC]; -} Bee; // size = 0x450 + /* 0x174 */ BeeActionFunc process; + /* 0x178 */ void* segment; + /* 0x17C */ s32 processNum; + /* 0x180 */ SkeletonInfoR skeletonInfo; + /* 0x1F0 */ s_xyz jointTable[4]; + /* 0x208 */ s_xyz morphTable[4]; + /* 0x220 */ Mtx mtx[2][4]; + /* 0x420 */ xyz_t targetScale; + /* 0x42C */ f32 targetSpeed; + /* 0x430 */ f32 shapeFactor; + /* 0x434 */ f32 targetHeight; + /* 0x438 */ s32 alpha; + /* 0x43C */ s16 heightAmplitudeCounter; + /* 0x43E */ s16 rotStep; + /* 0x440 */ s16 texScrollCounter1; + /* 0x442 */ s16 texScrollCounter2; + /* 0x444 */ s16 targetRotStep; + /* 0x446 */ u8 state; + /* 0x448 */ u32 unk_448; + /* 0x000 */ UNK_TYPE1 unk_44C[0x4]; +} Bee; // size 0x450 #endif diff --git a/src/overlays/actors/ovl_Fuusen/ac_fuusen.c b/src/overlays/actors/ovl_Fuusen/ac_fuusen.c index 16c8424..d4bef67 100644 --- a/src/overlays/actors/ovl_Fuusen/ac_fuusen.c +++ b/src/overlays/actors/ovl_Fuusen/ac_fuusen.c @@ -41,10 +41,9 @@ ActorProfile Fuusen_Profile = { }; void aFSN_actor_ct(Actor* thisx, Game_Play* game_play) { - static xyz_t Init_Size = { 0.01f, 0.01f, 0.01f }; Fuusen* this = THIS; SkeletonInfoR* skeletonInfo = &this->skeletonInfo; - xyz_t size = Init_Size; + xyz_t Init_Size = { 0.01f, 0.01f, 0.01f }; f32 balloonGroundY = mCoBG_GetBalloonGroundY(&this->actor.world.pos); this->escapeTimer = 1000; @@ -55,7 +54,7 @@ void aFSN_actor_ct(Actor* thisx, Game_Play* game_play) { this->actor.shape.drawShadow = 0; cKF_SkeletonInfo_R_play(skeletonInfo); skeletonInfo->frameControl.speed = 1.0f; - xyz_t_move(&this->actor.scale, &size); + xyz_t_move(&this->actor.scale, &Init_Size); this->actor.world.pos.y = balloonGroundY + 200.0f; this->heightOffset = 110.0f; this->segment = game_play->objectExchangeBank.status[this->actor.unk_026].segment; diff --git a/src/overlays/actors/ovl_Koinobori/ac_koinobori.c b/src/overlays/actors/ovl_Koinobori/ac_koinobori.c index e12ef87..9ca8afe 100644 --- a/src/overlays/actors/ovl_Koinobori/ac_koinobori.c +++ b/src/overlays/actors/ovl_Koinobori/ac_koinobori.c @@ -97,7 +97,7 @@ void aKOI_actor_move(Actor* thisx, Game_Play* game_play) { gSegments[6] = OS_K0_TO_PHYSICAL(common_data.clip.unk_08C->unk_AC(0x27)); cKF_SkeletonInfo_R_play(&this->skeletonInfo); this->unk2A0(this, game_play); - sAdo_OngenPos((u32)this, 0x35, &this->actor.world.pos); + sAdo_OngenPos((uintptr_t)this, 0x35, &this->actor.world.pos); } void aKOI_actor_init(Actor* thisx, Game_Play* game_play) { diff --git a/src/overlays/actors/player_actor/m_player.h b/src/overlays/actors/player_actor/m_player.h index fbf6436..444b92d 100644 --- a/src/overlays/actors/player_actor/m_player.h +++ b/src/overlays/actors/player_actor/m_player.h @@ -10,6 +10,9 @@ struct Game; struct Game_Play; struct Player; +typedef void (*PlayerUnk1230Func)(struct Player*, struct Game_Play*, Actor*, s32, xyz_t*, f32); +typedef f32 (*PlayerUnk1234Func)(struct Player*, struct Game_Play*); +typedef void (*PlayerUnk1238Func)(struct Player*, struct Game_Play*, Actor*, s32); typedef s32 (*SetMgrGetEndPosProc)(struct Game*, xyz_t*); typedef struct Player { @@ -35,7 +38,11 @@ typedef struct Player { /* 0x0FA4 */ ClObjTris colliderTris2; /* 0x0FB8 */ UNK_TYPE1 unk_0FB8[0x50]; /* 0x1008 */ ClObjPipe colliderPipe; - /* 0x1024 */ UNK_TYPE1 unk_1024[0x220]; + /* 0x1024 */ UNK_TYPE1 unk_1024[0x20C]; + /* 0x1230 */ PlayerUnk1230Func unk_1230; + /* 0x1234 */ PlayerUnk1234Func unk_1234; + /* 0x1238 */ PlayerUnk1238Func unk_1238; + /* 0x123C */ UNK_TYPE1 unk_123C[0x8]; /* 0x1244 */ SetMgrGetEndPosProc getEndPos; /* 0x1248 */ UNK_TYPE1 unk_1248[0x70]; /* 0x12B8 */ UNK_TYPE unk_12B8; |
