summaryrefslogtreecommitdiff
path: root/src/d/actor/d_a_b_ob.cpp
diff options
context:
space:
mode:
authorTakaRikka <38417346+TakaRikka@users.noreply.github.com>2025-11-30 14:23:42 -0800
committerGitHub <noreply@github.com>2025-11-30 15:23:42 -0700
commita6e76c0841cae03cae0c0e6ac75c32f979043093 (patch)
tree76b5f590c59c6abdf2c80d0a3d5c0ccb31ebd0fe /src/d/actor/d_a_b_ob.cpp
parent434415337d268e405b09f6b72935a7e918e4cfe7 (diff)
project cleanup (#2895)
* some wii OS fixes * remove old dol2asm comments * remove dol2asm.h * remove function address comments * normalize ATTRIBUTE_ALIGN usage * DECL_WEAK macro * fix gcc attribute weak macro * wrap more mwcc specific things in ifdefs * fixes * fix revo sdk version flags * fixes
Diffstat (limited to 'src/d/actor/d_a_b_ob.cpp')
-rw-r--r--src/d/actor/d_a_b_ob.cpp57
1 files changed, 2 insertions, 55 deletions
diff --git a/src/d/actor/d_a_b_ob.cpp b/src/d/actor/d_a_b_ob.cpp
index dde55e3723..4c104b494d 100644
--- a/src/d/actor/d_a_b_ob.cpp
+++ b/src/d/actor/d_a_b_ob.cpp
@@ -1,8 +1,3 @@
-//
-// Generated By: dol2asm
-// Translation Unit: d_a_b_ob
-//
-
#include "d/dolzel_rel.h" // IWYU pragma: keep
#include "d/actor/d_a_b_ob.h"
@@ -77,8 +72,8 @@ enum B_oh_RES_File_ID {
class daB_OB_HIO_c {
public:
public:
- /* 8061056C */ daB_OB_HIO_c();
- /* 8061A808 */ virtual ~daB_OB_HIO_c() {}
+ daB_OB_HIO_c();
+ virtual ~daB_OB_HIO_c() {}
/* 0x04 */ s8 field_0x04;
/* 0x08 */ f32 mCoreSize;
@@ -91,7 +86,6 @@ public:
};
-/* 8061056C-806105BC 0000EC 0050+00 1/1 0/0 0/0 .text __ct__12daB_OB_HIO_cFv */
daB_OB_HIO_c::daB_OB_HIO_c() {
field_0x04 = -1;
mCoreSize = 1.0f;
@@ -103,14 +97,12 @@ daB_OB_HIO_c::daB_OB_HIO_c() {
mRange = 3.0f;
}
-/* 806105BC-8061066C 00013C 00B0+00 8/8 0/0 0/0 .text anm_init__FP10b_ob_classifUcf */
static void anm_init(b_ob_class* i_this, int i_anmID, f32 i_morf, u8 i_mode, f32 i_speed) {
J3DAnmTransform* pbck = (J3DAnmTransform*)dComIfG_getObjectRes("B_oh", i_anmID);
i_this->mBodyParts[0].mpMorf->setAnm(pbck, i_mode, i_morf, i_speed, 0.0f, -1.0f, NULL);
i_this->mAnmID = i_anmID;
}
-/* 8061066C-806107B4 0001EC 0148+00 1/1 0/0 0/0 .text HeadCallBack__FP8J3DJointi */
static int HeadCallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -135,7 +127,6 @@ static int HeadCallBack(J3DJoint* i_joint, int param_1) {
return 1;
}
-/* 806107B4-806109AC 000334 01F8+00 1/1 0/0 0/0 .text TailCallBack__FP8J3DJointi */
static int TailCallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -174,22 +165,16 @@ static int TailCallBack(J3DJoint* i_joint, int param_1) {
static u8 data_8061B4FD;
-/* 8061B500-8061B504 000048 0004+00 0/2 0/0 0/0 .bss moveSW */
static BOOL moveSW;
-/* 8061B504-8061B508 00004C 0004+00 1/4 0/0 0/0 .bss moveSW2 */
static BOOL moveSW2;
-/* 8061B514-8061B534 00005C 0020+00 4/7 0/0 0/0 .bss l_HIO */
static daB_OB_HIO_c l_HIO;
-/* 8061B534-8061B538 00007C 0004+00 3/4 0/0 0/0 .bss pno */
static int pno;
-/* 8061B538-8061B53C 000080 0004+00 1/2 0/0 0/0 .bss fin */
static int fin;
-/* 806109AC-80610B3C 00052C 0190+00 1/1 0/0 0/0 .text FinACallBack__FP8J3DJointi */
static int FinACallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -218,7 +203,6 @@ static int FinACallBack(J3DJoint* i_joint, int param_1) {
return 1;
}
-/* 80610B3C-80610C24 0006BC 00E8+00 1/1 0/0 0/0 .text FinBCallBack__FP8J3DJointi */
static int FinBCallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -238,7 +222,6 @@ static int FinBCallBack(J3DJoint* i_joint, int param_1) {
return 1;
}
-/* 80610C24-80610D24 0007A4 0100+00 1/1 0/0 0/0 .text FinCCallBack__FP8J3DJointi */
static int FinCCallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -259,7 +242,6 @@ static int FinCCallBack(J3DJoint* i_joint, int param_1) {
return 1;
}
-/* 80610D24-80610E2C 0008A4 0108+00 1/1 0/0 0/0 .text sui_nodeCallBack__FP8J3DJointi */
static int sui_nodeCallBack(J3DJoint* i_joint, int param_1) {
if (param_1 == 0) {
int joint_no = i_joint->getJntNo();
@@ -281,7 +263,6 @@ static int sui_nodeCallBack(J3DJoint* i_joint, int param_1) {
return 1;
}
-/* 80610E2C-80610EE4 0009AC 00B8+00 1/1 0/0 0/0 .text dark__FP12J3DModelDatas */
static void dark(J3DModelData* i_modelData, s16 i_color) {
if (i_color != 0) {
for (u16 i = 0; i < i_modelData->getMaterialNum(); i++) {
@@ -293,7 +274,6 @@ static void dark(J3DModelData* i_modelData, s16 i_color) {
}
}
-/* 80610EE4-80611408 000A64 0524+00 1/0 0/0 0/0 .text daB_OB_Draw__FP10b_ob_class */
static int daB_OB_Draw(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
@@ -413,7 +393,6 @@ static int daB_OB_Draw(b_ob_class* i_this) {
return 1;
}
-/* 80611444-80611824 000FC4 03E0+00 1/1 0/0 0/0 .text core_start__FP10b_ob_class */
static void core_start(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
cXyz sp28;
@@ -518,7 +497,6 @@ static void core_start(b_ob_class* i_this) {
a_this->shape_angle.z += 0xA00;
}
-/* 80611824-80611C20 0013A4 03FC+00 1/1 0/0 0/0 .text core_hand_move__FP10b_ob_class */
static void core_hand_move(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
cXyz sp38;
@@ -614,10 +592,8 @@ static void core_hand_move(b_ob_class* i_this) {
a_this->shape_angle.z += 0xA00;
}
-/* 8061B53C-8061B540 000084 0004+00 2/2 0/0 0/0 .bss bf_ct */
static int bf_ct;
-/* 80611C20-80611C78 0017A0 0058+00 1/1 0/0 0/0 .text s_bf_sub__FPvPv */
static void* s_bf_sub(void* i_this, void* i_data) {
if (fopAcM_IsActor(i_this) && fopAcM_GetName(i_this) == PROC_E_OctBg) {
bf_ct++;
@@ -626,7 +602,6 @@ static void* s_bf_sub(void* i_this, void* i_data) {
return NULL;
}
-/* 80611C78-80611CC4 0017F8 004C+00 1/1 0/0 0/0 .text s_bfdel_sub__FPvPv */
static void* s_bfdel_sub(void* i_this, void* i_data) {
if (fopAcM_IsActor(i_this) && fopAcM_GetName(i_this) == PROC_E_OctBg) {
fopAcM_delete((fopAc_ac_c*)i_this);
@@ -635,7 +610,6 @@ static void* s_bfdel_sub(void* i_this, void* i_data) {
return NULL;
}
-/* 80611CC4-80611D10 001844 004C+00 1/1 0/0 0/0 .text s_kaisoudel_sub__FPvPv */
static void* s_kaisoudel_sub(void* i_this, void* i_data) {
if (fopAcM_IsActor(i_this) && fopAcM_GetName(i_this) == PROC_Obj_Kaisou) {
fopAcM_delete((fopAc_ac_c*)i_this);
@@ -644,7 +618,6 @@ static void* s_kaisoudel_sub(void* i_this, void* i_data) {
return NULL;
}
-/* 80611D10-80611EF8 001890 01E8+00 1/1 0/0 0/0 .text bombfishset__FP10b_ob_class */
static void bombfishset(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
cXyz pos;
@@ -693,7 +666,6 @@ static void bombfishset(b_ob_class* i_this) {
}
}
-/* 80611F34-80611FAC 001AB4 0078+00 1/1 0/0 0/0 .text core_hook__FP10b_ob_class */
static void core_hook(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
i_this->mHitIFrameTimer = 20;
@@ -716,7 +688,6 @@ static void core_hook(b_ob_class* i_this) {
a_this->shape_angle.z += 0xA00;
}
-/* 80611FAC-80612484 001B2C 04D8+00 1/1 0/0 0/0 .text core_chance__FP10b_ob_class */
static int core_chance(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
cXyz sp68;
@@ -812,7 +783,6 @@ static int core_chance(b_ob_class* i_this) {
return var_r30;
}
-/* 80612484-8061285C 002004 03D8+00 1/1 0/0 0/0 .text core_end__FP10b_ob_class */
static void core_end(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
int frame = i_this->mBodyParts[0].mpMorf->getFrame();
@@ -900,7 +870,6 @@ static void core_end(b_ob_class* i_this) {
}
}
-/* 8061285C-80612CC8 0023DC 046C+00 1/1 0/0 0/0 .text core_action__FP10b_ob_class */
static void core_action(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
fopAc_ac_c* player = dComIfGp_getPlayer(0);
@@ -1005,8 +974,6 @@ static void core_action(b_ob_class* i_this) {
}
}
-/* 80612CC8-80612ED4 002848 020C+00 1/1 0/0 0/0 .text core_damage_check__FP10b_ob_class
- */
static void core_damage_check(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
@@ -1046,8 +1013,6 @@ static void core_damage_check(b_ob_class* i_this) {
}
}
-/* 80612ED4-806131A8 002A54 02D4+00 1/1 0/0 0/0 .text fish_damage_check__FP10b_ob_class
- */
static void fish_damage_check(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
@@ -1123,7 +1088,6 @@ static void fish_damage_check(b_ob_class* i_this) {
}
}
-/* 806131A8-80613270 002D28 00C8+00 2/2 0/0 0/0 .text pl_check__FP10b_ob_classfs */
static BOOL pl_check(b_ob_class* i_this, f32 i_range, s16 i_maxAngle) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
@@ -1144,7 +1108,6 @@ static BOOL pl_check(b_ob_class* i_this, f32 i_range, s16 i_maxAngle) {
return false;
}
-/* 80613270-80613E00 002DF0 0B90+00 1/1 0/0 0/0 .text fish_normal__FP10b_ob_class */
static int fish_normal(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
@@ -1388,7 +1351,6 @@ static int fish_normal(b_ob_class* i_this) {
return ret;
}
-/* 80613E00-80614228 003980 0428+00 1/1 0/0 0/0 .text fish_vacume__FP10b_ob_class */
static int fish_vacume(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
@@ -1466,7 +1428,6 @@ static int fish_vacume(b_ob_class* i_this) {
return 2;
}
-/* 80614228-806147D4 003DA8 05AC+00 1/1 0/0 0/0 .text fish_end__FP10b_ob_class */
static int fish_end(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
@@ -1583,18 +1544,15 @@ static int fish_end(b_ob_class* i_this) {
return 4;
}
-/* 8061B0D0-8061B11C 00002C 004C+00 1/1 0/0 0/0 .data buf_p */
static f32 buf_p[] = {
0.0f, 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f, 8.8f,
9.6f, 10.4f, 11.2f, 12.0f, 12.6f, 13.2f, 13.8f, 14.4f, 15.0f,
};
-/* 8061B11C-8061B168 000078 004C+00 1/1 0/0 0/0 .data size_p */
static f32 size_p[] = {1.0f, 1.05f, 1.075f, 1.1f, 1.1f, 1.075f, 1.05f,
1.0f, 0.9f, 0.85f, 0.8f, 0.75f, 0.7f, 0.65f,
0.6f, 0.55f, 0.5f, 0.45f, 1.0f};
-/* 806147D4-80614B70 004354 039C+00 1/1 0/0 0/0 .text dmcalc__FP10b_ob_class */
static void dmcalc(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
int i;
@@ -1695,7 +1653,6 @@ static void dmcalc(b_ob_class* i_this) {
}
}
-/* 80614B70-806158E0 0046F0 0D70+00 1/1 0/0 0/0 .text fish_move__FP10b_ob_class */
static void fish_move(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
fopAc_ac_c* player = dComIfGp_getPlayer(0);
@@ -2012,7 +1969,6 @@ static void fish_move(b_ob_class* i_this) {
i_this->mFishBattleMode = 2;
}
-/* 806158E0-806159C4 005460 00E4+00 1/1 0/0 0/0 .text cam_3d_morf__FP10b_ob_classf */
static void cam_3d_morf(b_ob_class* i_this, f32 i_scale) {
cLib_addCalc2(&i_this->mDemoCamCenter.x, i_this->mDemoCamCenterTarget.x, i_scale,
i_this->field_0x5cc0 * i_this->field_0x5cd0);
@@ -2029,7 +1985,6 @@ static void cam_3d_morf(b_ob_class* i_this, f32 i_scale) {
i_this->field_0x5cbc * i_this->field_0x5cd0);
}
-/* 806159C4-80615A10 005544 004C+00 1/1 0/0 0/0 .text s_hasidel_sub__FPvPv */
static void* s_hasidel_sub(void* i_this, void* i_data) {
if (fopAcM_IsActor(i_this) && fopAcM_GetName(i_this) == PROC_OCTHASHI) {
fopAcM_delete((fopAc_ac_c*)i_this);
@@ -2038,7 +1993,6 @@ static void* s_hasidel_sub(void* i_this, void* i_data) {
return NULL;
}
-/* 80615A10-80618540 005590 2B30+00 2/1 0/0 0/0 .text demo_camera__FP10b_ob_class */
static void demo_camera(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
@@ -3046,7 +3000,6 @@ static void demo_camera(b_ob_class* i_this) {
}
}
-/* 80618650-806193B4 0081D0 0D64+00 2/1 0/0 0/0 .text daB_OB_Execute__FP10b_ob_class */
static int daB_OB_Execute(b_ob_class* i_this) {
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
@@ -3314,12 +3267,10 @@ static int daB_OB_Execute(b_ob_class* i_this) {
return 1;
}
-/* 806193B4-806193BC 008F34 0008+00 1/0 0/0 0/0 .text daB_OB_IsDelete__FP10b_ob_class */
static int daB_OB_IsDelete(b_ob_class* i_this) {
return 1;
}
-/* 806193BC-80619438 008F3C 007C+00 1/0 0/0 0/0 .text daB_OB_Delete__FP10b_ob_class */
static int daB_OB_Delete(b_ob_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "B_oh");
@@ -3335,7 +3286,6 @@ static int daB_OB_Delete(b_ob_class* i_this) {
return 1;
}
-/* 80619438-80619C14 008FB8 07DC+00 1/1 0/0 0/0 .text useHeapInit__FP10fopAc_ac_c */
static int useHeapInit(fopAc_ac_c* i_this) {
b_ob_class* a_this = (b_ob_class*)i_this;
@@ -3525,7 +3475,6 @@ static int useHeapInit(fopAc_ac_c* i_this) {
return 1;
}
-/* 80619C5C-8061A0C0 0097DC 0464+00 1/0 0/0 0/0 .text daB_OB_Create__FP10fopAc_ac_c */
static int daB_OB_Create(fopAc_ac_c* i_this) {
b_ob_class* a_this = (b_ob_class*)i_this;
fopAcM_ct(i_this, b_ob_class);
@@ -3691,7 +3640,6 @@ static int daB_OB_Create(fopAc_ac_c* i_this) {
AUDIO_INSTANCES;
-/* 8061B3DC-8061B3FC -00001 0020+00 1/0 0/0 0/0 .data l_daB_OB_Method */
static actor_method_class l_daB_OB_Method = {
(process_method_func)daB_OB_Create,
(process_method_func)daB_OB_Delete,
@@ -3700,7 +3648,6 @@ static actor_method_class l_daB_OB_Method = {
(process_method_func)daB_OB_Draw,
};
-/* 8061B3FC-8061B42C -00001 0030+00 0/0 0/0 1/0 .data g_profile_B_OB */
extern actor_process_profile_definition g_profile_B_OB = {
fpcLy_CURRENT_e,
4,