summaryrefslogtreecommitdiff
path: root/include/d
diff options
context:
space:
mode:
authorTakaRikka <38417346+TakaRikka@users.noreply.github.com>2022-10-19 00:38:01 -0700
committerGitHub <noreply@github.com>2022-10-19 00:38:01 -0700
commitf03b959831d308b63ba72d79f7814faaa6818481 (patch)
treee5b31e52e6755877e7402cd81f8f490565b1855c /include/d
parent4913395dbd1a33d794028ceb82579b4baffe954d (diff)
parentc3a6d117295705a486bbd67cc0c84991b4d139c3 (diff)
Merge pull request #211 from TakaRikka/work1
d_attention / d_a_player / d_demo + misc
Diffstat (limited to 'include/d')
-rw-r--r--include/d/a/d_a_alink.h20
-rw-r--r--include/d/a/d_a_player.h24
-rw-r--r--include/d/bg/d_bg_s_acch.h2
-rw-r--r--include/d/com/d_com_inf_game.h75
-rw-r--r--include/d/com/d_com_static.h28
-rw-r--r--include/d/d_attention.h159
-rw-r--r--include/d/d_demo.h28
-rw-r--r--include/d/d_drawlist.h4
-rw-r--r--include/d/d_lib.h8
-rw-r--r--include/d/event/d_event.h2
-rw-r--r--include/d/msg/d_msg_object.h4
-rw-r--r--include/d/particle/d_particle.h23
12 files changed, 253 insertions, 124 deletions
diff --git a/include/d/a/d_a_alink.h b/include/d/a/d_a_alink.h
index 7df6f5c7a6..f0caef5526 100644
--- a/include/d/a/d_a_alink.h
+++ b/include/d/a/d_a_alink.h
@@ -1430,7 +1430,7 @@ public:
/* 800E01CC */ void cancelBoomerangLock(fopAc_ac_c*);
/* 800E0210 */ fopAc_ac_c* getBoomerangActor();
/* 800E0244 */ bool checkBoomerangChargeEnd();
- /* 800E02B8 */ void checkBoomerangCarry(fopAc_ac_c*);
+ /* 800E02B8 */ BOOL checkBoomerangCarry(fopAc_ac_c*);
/* 800E03D0 */ void initBoomerangUpperAnimeSpeed(int);
/* 800E0440 */ BOOL checkBoomerangAnime() const;
/* 800E04AC */ BOOL checkBoomerangThrowAnime() const;
@@ -5596,17 +5596,17 @@ class daAlinkHIO_boom_c1 {
public:
/* 0x00 */ daAlinkHIO_anm_c mThrowAnm;
/* 0x14 */ daAlinkHIO_anm_c mCatchAnm;
- /* 0x28 */ s16 field_0x28;
+ /* 0x28 */ s16 field_0x28; // return time?
/* 0x2A */ s16 mBgThroughTime;
- /* 0x2C */ f32 field_0x2c;
- /* 0x30 */ f32 field_0x30;
- /* 0x34 */ f32 field_0x34;
- /* 0x38 */ f32 field_0x38;
- /* 0x3C */ f32 field_0x3c;
- /* 0x40 */ f32 field_0x40;
- /* 0x44 */ f32 field_0x44;
+ /* 0x2C */ f32 mIdleAnmSpeed;
+ /* 0x30 */ f32 mStartInterpolation;
+ /* 0x34 */ f32 mFlySpeed;
+ /* 0x38 */ f32 mFlySpeed2; // return speed?
+ /* 0x3C */ f32 mFlyDistMax;
+ /* 0x40 */ f32 mHorsebackFlyDistMax;
+ /* 0x44 */ f32 mLockDistMax;
/* 0x48 */ f32 mCatchSpeed;
-}; // Size: 0x4c
+}; // Size: 0x4C
class daAlinkHIO_boom_c0 {
public:
diff --git a/include/d/a/d_a_player.h b/include/d/a/d_a_player.h
index 1e5e9c7604..f026d1bfa8 100644
--- a/include/d/a/d_a_player.h
+++ b/include/d/a/d_a_player.h
@@ -34,12 +34,15 @@ private:
class daPy_boomerangMove_c {
public:
/* 8015E5B0 */ void initOffset(cXyz const*);
- /* 8015E654 */ void posMove(cXyz*, s16*, fopAc_ac_c*, s16);
+ /* 8015E654 */ int posMove(cXyz*, s16*, fopAc_ac_c*, s16);
/* 8015E87C */ void bgCheckAfterOffset(cXyz const*);
+ static s16 m_dropAngleY;
+ static s16 m_eventKeepFlg;
+
private:
/* 0x0 */ u8 field_0x0;
- /* 0x2 */ u16 field_0x2;
+ /* 0x2 */ s16 field_0x2;
/* 0x4 */ f32 field_0x4;
/* 0x8 */ f32 field_0x8;
}; // Size: 0xC
@@ -213,7 +216,15 @@ public:
HEAVY_STATE_BOOTS = FLG0_UNK_40000000 | EQUIP_HEAVY_BOOTS | FLG0_UNK_20000,
};
- enum daPy_FLG1 { IS_WOLF = 0x2000000, FLG1_UNK_10000 = 0x10000, THROW_DAMAGE = 0x4000, FLG1_UNK_4 = 4, };
+
+ enum daPy_FLG1 {
+ IS_WOLF = 0x2000000,
+ FLG1_UNK_10000 = 0x10000,
+ THROW_DAMAGE = 0x4000,
+ FLG1_UNK_4 = 4,
+ FLG1_UNK_2 = 2,
+ };
+
enum daPy_FLG2 {
FLG2_UNK_20000000 = 0x20000000,
FLG2_UNK_4080000 = 0x4080000,
@@ -227,12 +238,14 @@ public:
UNK_FLG2_2 = 2,
UNK_DAPY_FLG2_1 = 1
};
+
enum daPy_FLG3 {
FLG3_UNK_2000000 = 0x2000000,
FLG3_UNK_1000000 = 0x1000000,
FLG3_UNK_100000 = 0x100000,
COPY_ROD_THROW_AFTER = 0x40000
};
+
enum daPy_ERFLG0 {
ERFLG0_UNK_8000000 = 0x8000000,
ERFLG0_UNK_1000000 = 0x1000000,
@@ -243,15 +256,18 @@ public:
ERFLG0_UNK_2 = 2,
ERFLG0_UNK_1 = 1,
};
+
enum daPy_ERFLG1 {
GANON_FINISH = 0x80000000,
UNK_FORCE_PUT_POS = 0x2000,
ERFLG1_UNK_2 = 2,
ERFLG1_UNK_1 = 1,
};
+
enum daPy_ERFLG2 {
ERFLG2_UNK_100 = 0x100,
};
+
enum daPy_RFLG0 {
RFLG0_UNK_8000000 = 0x8000000,
RFLG0_UNK_4000 = 0x4000,
@@ -321,7 +337,7 @@ public:
static u32 checkCarryStartLightBallA();
static u32 checkCarryStartLightBallB();
float getSpinnerRideSpeed() const;
- void checkSpinnerReflectEffect();
+ bool checkSpinnerReflectEffect();
static bool checkBoomerangCharge();
bool checkBoomerangChargeTime();
static daBoomerang_c* getThrowBoomerangActor();
diff --git a/include/d/bg/d_bg_s_acch.h b/include/d/bg/d_bg_s_acch.h
index 0754ceb3ec..7a56b4d3d6 100644
--- a/include/d/bg/d_bg_s_acch.h
+++ b/include/d/bg/d_bg_s_acch.h
@@ -47,7 +47,7 @@ public:
bool ChkWallHit() { return m_flags & WALL_HIT; }
void SetCir(cXyz& pos) { m_cir.Set(pos.x, pos.z, pos.y + GetWallH(), m_wall_r); }
-};
+}; // Size: 0x40
class dBgS;
class dBgS_Acch : public cBgS_Chk, public dBgS_Chk {
diff --git a/include/d/com/d_com_inf_game.h b/include/d/com/d_com_inf_game.h
index 0d0a803c88..687eaf1aef 100644
--- a/include/d/com/d_com_inf_game.h
+++ b/include/d/com/d_com_inf_game.h
@@ -364,7 +364,10 @@ public:
void setPlayerPtr(int i, fopAc_ac_c* ptr) { mPlayerPtr[i] = ptr; }
void setPlayer(int i, fopAc_ac_c* player) { mPlayer[i] = (daAlink_c*)player; }
- void setPlayerInfo(int i, fopAc_ac_c* ptr, int camIdx) { mPlayer[i] = (daAlink_c*)ptr; mPlayerCameraID[camIdx] = 0; }
+ void setPlayerInfo(int i, fopAc_ac_c* ptr, int camIdx) {
+ mPlayer[i] = (daAlink_c*)ptr;
+ mPlayerCameraID[camIdx] = 0;
+ }
void setPlayerStatus(int param_0, int i, u32 flag) { mPlayerStatus[i] |= flag; }
void clearPlayerStatus(int param_0, int i, u32 flag) { mPlayerStatus[i] &= ~flag; }
bool checkPlayerStatus(int param_0, int i, u32 flag) { return flag & mPlayerStatus[i]; }
@@ -377,6 +380,8 @@ public:
return mCameraInfo[i].mCameraAttentionStatus & flag;
}
void setCameraAttentionStatus(int i, u32 flag) { mCameraInfo[i].mCameraAttentionStatus = flag; }
+ void onCameraAttentionStatus(int i, u32 flag) { mCameraInfo[i].mCameraAttentionStatus |= flag; }
+ void offCameraAttentionStatus(int i, u32 flag) { mCameraInfo[i].mCameraAttentionStatus &= ~flag; }
void setCameraInfo(int camIdx, camera_class* p_cam, int param_2, int param_3, int param_4) {
mCameraInfo[camIdx].mCamera = p_cam;
mCameraInfo[camIdx].field_0x4 = param_2;
@@ -397,6 +402,7 @@ public:
int getMessageCountNumber() { return mMessageCountNum; }
void setWindowNum(u8 num) { mWindowNum = num; }
+ int getWindowNum() { return mWindowNum; }
dDlst_window_c* getWindow(int i) { return &mWindow[i]; }
void setWindow(int i, f32 param_1, f32 param_2, f32 param_3, f32 param_4, f32 param_5,
f32 param_6, int camID, int mode) {
@@ -1059,6 +1065,10 @@ inline u8 dComIfGs_getOptVibration() {
return g_dComIfG_gameInfo.info.getPlayer().getConfig().getVibration();
}
+inline u8 dComIfGs_getOptAttentionType() {
+ return g_dComIfG_gameInfo.info.getPlayer().getConfig().getAttentionType();
+}
+
inline BOOL dComIfGs_isTbox(int i_no) {
return g_dComIfG_gameInfo.info.getMemory().getBit().isTbox(i_no);
}
@@ -1397,7 +1407,7 @@ inline void dComIfGs_setTmpReg(u16 reg, u8 flag) {
g_dComIfG_gameInfo.info.getTmp().setEventReg(reg, flag);
}
-inline u8 dComIfGs_getTmpReg(u16 reg) {
+inline int dComIfGs_getTmpReg(u16 reg) {
return g_dComIfG_gameInfo.info.getTmp().getEventReg(reg);
}
@@ -1477,7 +1487,6 @@ inline void dComIfGs_setMemoryToCard(u8* p_saveData, int dataNum) {
g_dComIfG_gameInfo.info.memory_to_card((char*)p_saveData, dataNum);
}
-
void dComIfGp_setSelectItem(int index);
s32 dComIfGp_offHeapLockFlag(int flag);
void dComIfGp_createSubExpHeap2D();
@@ -2024,7 +2033,16 @@ inline BOOL dComIfGp_checkCameraAttentionStatus(int i, u32 flag) {
return g_dComIfG_gameInfo.play.checkCameraAttentionStatus(i, flag);
}
-inline void dComIfGp_setCameraInfo(int camIdx, camera_class* p_cam, int param_2, int param_3, int param_4) {
+inline void dComIfGp_onCameraAttentionStatus(int i, u32 flag) {
+ g_dComIfG_gameInfo.play.onCameraAttentionStatus(i, flag);
+}
+
+inline void dComIfGp_offCameraAttentionStatus(int i, u32 flag) {
+ g_dComIfG_gameInfo.play.offCameraAttentionStatus(i, flag);
+}
+
+inline void dComIfGp_setCameraInfo(int camIdx, camera_class* p_cam, int param_2, int param_3,
+ int param_4) {
g_dComIfG_gameInfo.play.setCameraInfo(camIdx, p_cam, param_2, param_3, param_4);
}
@@ -2168,6 +2186,10 @@ inline void dComIfGp_setWindowNum(int num) {
g_dComIfG_gameInfo.play.setWindowNum(num);
}
+inline int dComIfGp_getWindowNum() {
+ return g_dComIfG_gameInfo.play.getWindowNum();
+}
+
inline dDlst_window_c* dComIfGp_getWindow(int i) {
return g_dComIfG_gameInfo.play.getWindow(i);
}
@@ -2288,7 +2310,8 @@ inline int dComIfGp_event_moveApproval(void* actor) {
inline int dComIfGp_event_order(u16 eventType, u16 priority, u16 flag, u16 param_3, void* param_4,
void* param_5, s16 eventID, u8 infoIdx) {
- return g_dComIfG_gameInfo.play.getEvent().order(eventType, priority, flag, param_3, param_4, param_5, eventID, infoIdx);
+ return g_dComIfG_gameInfo.play.getEvent().order(eventType, priority, flag, param_3, param_4,
+ param_5, eventID, infoIdx);
}
inline void dComIfGp_event_setGtItm(int i_itemNo) {
@@ -2436,10 +2459,10 @@ inline u32 dComIfGp_particle_set(u32 param_0, u16 param_1, const cXyz* param_2,
param_10, param_11, 1.0f);
}
-inline u32 dComIfGp_particle_set(u32 param_0, u16 param_1, const cXyz* param_2, const csXyz* param_3,
- const cXyz* param_4, u8 param_5, dPa_levelEcallBack* param_6,
- s8 param_7, const GXColor* param_8, const GXColor* param_9,
- const cXyz* param_10) {
+inline u32 dComIfGp_particle_set(u32 param_0, u16 param_1, const cXyz* param_2,
+ const csXyz* param_3, const cXyz* param_4, u8 param_5,
+ dPa_levelEcallBack* param_6, s8 param_7, const GXColor* param_8,
+ const GXColor* param_9, const cXyz* param_10) {
return g_dComIfG_gameInfo.play.getParticle()->setNormal(
param_0, param_1, param_2, NULL, param_3, param_4, param_5, param_6, param_7, param_8,
param_9, param_10, 1.0f);
@@ -2454,20 +2477,29 @@ inline u32 dComIfGp_particle_set(u16 param_1, const cXyz* param_2, const dKy_tev
param_9, param_10, param_11, 1.0f);
}
+inline u32 dComIfGp_particle_set(u16 param_1, const cXyz* param_2, const csXyz* param_3,
+ const cXyz* param_4, u8 param_5, dPa_levelEcallBack* param_6,
+ s8 param_7, const GXColor* param_8, const GXColor* param_9,
+ const cXyz* param_10) {
+ return g_dComIfG_gameInfo.play.getParticle()->setNormal(param_1, param_2, NULL, param_3,
+ param_4, param_5, param_6, param_7,
+ param_8, param_9, param_10, 1.0f);
+}
+
inline u32 dComIfGp_particle_set(u16 param_0, const cXyz* param_1, const csXyz* param_2,
const cXyz* param_3) {
return dComIfGp_particle_set(param_0, param_1, NULL, param_2, param_3, 0xFF, NULL, -1, NULL,
NULL, NULL);
}
-inline u32 dComIfGp_particle_set(u16 param_0, const cXyz* param_1, const dKy_tevstr_c* param_2, const csXyz* param_3,
- const cXyz* param_4) {
+inline u32 dComIfGp_particle_set(u16 param_0, const cXyz* param_1, const dKy_tevstr_c* param_2,
+ const csXyz* param_3, const cXyz* param_4) {
return dComIfGp_particle_set(param_0, param_1, param_2, param_3, param_4, 0xFF, NULL, -1, NULL,
NULL, NULL);
}
-inline u32 dComIfGp_particle_set(u32 param_0, u16 param_1, const cXyz* param_2, const csXyz* param_3,
- const cXyz* param_4) {
+inline u32 dComIfGp_particle_set(u32 param_0, u16 param_1, const cXyz* param_2,
+ const csXyz* param_3, const cXyz* param_4) {
return dComIfGp_particle_set(param_0, param_1, param_2, param_3, param_4, 0xFF, NULL, -1, NULL,
NULL, NULL);
}
@@ -2496,7 +2528,6 @@ int dComIfGd_setShadow(u32 param_0, s8 param_1, J3DModel* param_2, cXyz* param_3
f32 param_5, f32 param_6, f32 param_7, cBgS_PolyInfo& param_8,
dKy_tevstr_c* param_9, s16 param_10, f32 param_11, _GXTexObj* param_12);
-
inline int dComIfGd_setRealShadow(u32 param_0, s8 param_1, J3DModel* param_2, cXyz* param_3,
f32 param_4, f32 param_5, dKy_tevstr_c* param_6) {
return g_dComIfG_gameInfo.drawlist.setRealShadow(param_0, param_1, param_2, param_3, param_4,
@@ -2522,6 +2553,10 @@ inline void dComIfGd_set2DOpa(dDlst_base_c* dlst) {
g_dComIfG_gameInfo.drawlist.set2DOpa(dlst);
}
+inline void dComIfGd_set2DXlu(dDlst_base_c* dlst) {
+ g_dComIfG_gameInfo.drawlist.set2DXlu(dlst);
+}
+
inline void dComIfGd_set2DOpaTop(dDlst_base_c* dlst) {
g_dComIfG_gameInfo.drawlist.set2DOpaTop(dlst);
}
@@ -2530,6 +2565,13 @@ inline view_class* dComIfGd_getView() {
return g_dComIfG_gameInfo.drawlist.getView();
}
+inline MtxP dComIfGd_getViewRotMtx() {
+ return ((camera_process_class*)g_dComIfG_gameInfo.drawlist.getView())->mViewMtxNoTrans;
+}
+inline MtxP dComIfGd_getViewMtx() {
+ return ((camera_process_class*)g_dComIfG_gameInfo.drawlist.getView())->mViewMtx;
+}
+
inline J3DDrawBuffer* dComIfGd_getListFilter() {
return g_dComIfG_gameInfo.drawlist.getOpaListFilter();
}
@@ -2562,6 +2604,11 @@ inline void dComIfGd_setListItem3D() {
g_dComIfG_gameInfo.drawlist.setXluListItem3D();
}
+inline void dComIfGd_setList3Dlast() {
+ g_dComIfG_gameInfo.drawlist.setOpaList3Dlast();
+ g_dComIfG_gameInfo.drawlist.setXluList3Dlast();
+}
+
inline void dComIfGd_setXluList2DScreen() {
g_dComIfG_gameInfo.drawlist.setXluList2DScreen();
}
diff --git a/include/d/com/d_com_static.h b/include/d/com/d_com_static.h
index 2268d3081a..9f15a06498 100644
--- a/include/d/com/d_com_static.h
+++ b/include/d/com/d_com_static.h
@@ -11,21 +11,36 @@ public:
class data_c {
public:
/* 80030F14 */ void set(s8, cXyz const&, cXyz const&, u8, u8, u8);
- /* 80030FBC */ void reset();
- /* 80030FCC */ void isSwitch();
- /* 800310C8 */ void check(fopAc_ac_c*);
- /* 80031038 */ void check(cXyz const&);
+ /* 80030FBC */ data_c* reset();
+ /* 80030FCC */ u8 isSwitch();
+ /* 800310C8 */ u8 check(fopAc_ac_c*);
+ /* 80031038 */ bool check(cXyz const&);
/* 80031150 */ void execute();
/* 80031F28 */ ~data_c();
/* 80031F64 */ data_c();
- };
+
+ void setNext(data_c* i_next) { mpNext = i_next; }
+ data_c* getNext() { return mpNext; }
+ u8 getType() { return mType; }
+
+ /* 0x00 */ s8 mRoomNo;
+ /* 0x01 */ bool field_0x1;
+ /* 0x02 */ u8 field_0x2;
+ /* 0x03 */ u8 field_0x3;
+ /* 0x04 */ u8 mType;
+ /* 0x08 */ cXyz field_0x8;
+ /* 0x14 */ cXyz field_0x14;
+ /* 0x20 */ data_c* mpNext;
+ }; // Size: 0x24
class room_c {
public:
/* 80031190 */ void add(daSus_c::data_c*);
/* 800311FC */ void reset();
/* 80031EE4 */ room_c();
- };
+
+ /* 0x0 */ data_c* mpData;
+ }; // Size: 0x4
/* 80031248 */ void newData(s8, cXyz const&, cXyz const&, u8, u8, u8);
/* 800313BC */ void reset();
@@ -35,6 +50,7 @@ public:
static u8 mData[1152];
static u8 mRoom[256];
+ static s16 mSetTop;
};
#endif /* D_COM_D_COM_STATIC_H */
diff --git a/include/d/d_attention.h b/include/d/d_attention.h
index d0c674f904..b214b991cd 100644
--- a/include/d/d_attention.h
+++ b/include/d/d_attention.h
@@ -10,32 +10,32 @@
class dAttHint_c {
public:
dAttHint_c() {}
- /* 800738B4 */ void getPId(void*);
- /* 800738CC */ void convPId(unsigned int);
- /* 800738FC */ void request(fopAc_ac_c*, int);
+ /* 800738B4 */ u32 getPId(void*);
+ /* 800738CC */ fopAc_ac_c* convPId(unsigned int);
+ /* 800738FC */ int request(fopAc_ac_c*, int);
/* 80073958 */ void init();
/* 80073970 */ void proc();
private:
/* 0x0 */ u32 mHintActorID;
- /* 0x4 */ u32 mPriority;
+ /* 0x4 */ int mPriority;
/* 0x8 */ u32 field_0x8;
};
class dAttCatch_c {
public:
dAttCatch_c() {}
- s32 convPId(unsigned int);
+ fopAc_ac_c* convPId(unsigned int);
void init();
void proc();
void request(fopAc_ac_c*, u8, f32, f32, f32, s16, int);
- s32 getCatghTarget() { return convPId(mCatghTargetID); }
+ fopAc_ac_c* getCatghTarget() { return convPId(mCatghTargetID); }
u8 getChangeItem() { return mChangeItem; }
private:
- /* 0x00 */ void* field_0x0;
- /* 0x04 */ f32 field_0x4;
+ /* 0x00 */ u32 field_0x0;
+ /* 0x04 */ int field_0x4;
/* 0x08 */ f32 field_0x8;
/* 0x0C */ u8 field_0xc;
/* 0x0D */ u8 field_0xd;
@@ -47,11 +47,7 @@ private:
class dAttParam_c {
public:
- dAttParam_c() {}
- /* 80070038 */ dAttParam_c(s32);
-
-private:
- /* 0x00 */ u16 field_0x0;
+ /* 0x00 */ u16 mFlags;
/* 0x04 */ f32 field_0x4;
/* 0x08 */ f32 field_0x8;
/* 0x0C */ f32 field_0xc;
@@ -66,21 +62,23 @@ private:
/* 0x30 */ f32 mAttnCursorOffsetY;
/* 0x34 */ u8 mAttnCursorAppearFrames;
/* 0x35 */ u8 mAttnCursorDisappearFrames;
+ /* 0x38 */ f32 field_0x38;
+ /* 0x3C */ f32 field_0x3c;
public:
+ dAttParam_c() {}
+ /* 80070038 */ dAttParam_c(s32);
+
/* 80070110 */ virtual ~dAttParam_c();
- /* 0x38 vtable */
-private:
- /* 0x3C */ f32 mSelCursorAnmSpeed;
- /* 0x40 */ f32 mAttnCursorAnmSpeed;
- /* 0x44 */ u32 mDispPosX;
- /* 0x48 */ u32 mDispPosY;
-}; // Size = 0x4C
+ bool CheckFlag(u16 flag) { return mFlags & flag; }
+
+ /* 0x40 vtable */
+}; // Size: 0x44
class dAttLook_c {
public:
- /* 80073CA4 */ void convPId(unsigned int);
+ /* 80073CA4 */ fopAc_ac_c* convPId(unsigned int);
/* 80073CD4 */ void init();
/* 80073CEC */ void proc();
/* 80073D08 */ void request(fopAc_ac_c*, f32, f32, f32, s16, int);
@@ -96,10 +94,11 @@ class dAttList_c {
public:
/* 800304D0 */ ~dAttList_c() {}
/* 8003050C */ dAttList_c() {}
- /* 80073864 */ void getActor();
+ /* 80073864 */ fopAc_ac_c* getActor();
/* 80073898 */ void setActor(fopAc_ac_c*);
-private:
+ u32 getPid() { return mActorID; }
+
/* 0x00 */ f32 mWeight;
/* 0x04 */ f32 mDistance;
/* 0x08 */ cSAngle mAngle;
@@ -117,15 +116,15 @@ public:
/* 800732B0 */ void draw(cXyz&, f32 (*)[4]);
/* 0x000 */ J3DModel* mModel[2];
- /* 0x008 */ mDoExt_bckAnm bckAnm[2];
- /* 0x040 */ mDoExt_bpkAnm bpkAnm[2];
- /* 0x070 */ mDoExt_brkAnm brkAnm[2];
- /* 0x0A0 */ mDoExt_brkAnm brkAnm2[2];
- /* 0x0D0 */ mDoExt_btkAnm btkAnm[2];
- /* 0x100 */ mDoExt_bckAnm bckAnm2;
- /* 0x11C */ mDoExt_bpkAnm bpkAnm2;
- /* 0x134 */ mDoExt_brkAnm brkAnm3;
- /* 0x14C */ mDoExt_btkAnm btkAnm2;
+ /* 0x008 */ mDoExt_bckAnm mNoticeCursorBck[2];
+ /* 0x040 */ mDoExt_bpkAnm mNoticeCursorBpk[2];
+ /* 0x070 */ mDoExt_brkAnm mNoticeCursorBrk[2];
+ /* 0x0A0 */ mDoExt_brkAnm mNoticeCursor02Brk[2];
+ /* 0x0D0 */ mDoExt_btkAnm mNoticeCursorBtk[2];
+ /* 0x100 */ mDoExt_bckAnm mImpactBck;
+ /* 0x11C */ mDoExt_bpkAnm mImpactBpk;
+ /* 0x134 */ mDoExt_brkAnm mImpactBrk;
+ /* 0x14C */ mDoExt_btkAnm mImpactBtk;
/* 0x164 */ cXyz field_0x164;
/* 0x170 */ u8 field_0x170;
/* 0x171 */ u8 field_0x171;
@@ -152,45 +151,56 @@ struct dist_entry {
u32 field_0x18;
}; // Size: 0x1C
+struct type_tbl_entry {
+ s16 field_0x0;
+ u16 field_0x2;
+};
+
class dAttention_c {
public:
+ enum EState {
+ ST_NONE,
+ ST_LOCK,
+ ST_RELEASE,
+ };
+
dAttention_c() {}
/* 80070198 */ dAttention_c(fopAc_ac_c*, u32);
/* 80070774 */ ~dAttention_c();
- /* 80070844 */ void GetLockonList(s32);
- /* 80070880 */ void getActionBtnB();
- /* 80070974 */ void getActionBtnXY();
- /* 80070A70 */ void chkAttMask(u32, u32);
- /* 80070E90 */ void calcWeight(int, fopAc_ac_c*, f32, s16, s16, u32*);
+ /* 80070844 */ dAttList_c* GetLockonList(s32);
+ /* 80070880 */ dAttList_c* getActionBtnB();
+ /* 80070974 */ dAttList_c* getActionBtnXY();
+ /* 80070A70 */ int chkAttMask(u32, u32);
+ /* 80070E90 */ f32 calcWeight(int, fopAc_ac_c*, f32, s16, s16, u32*);
/* 800710C0 */ void setList(int, fopAc_ac_c*, f32, f32, cSAngle, u32);
/* 80071240 */ void initList(u32);
- /* 800713CC */ void makeList();
+ /* 800713CC */ int makeList();
/* 80071424 */ void setOwnerAttentionPos();
- /* 80071488 */ void SelectAttention(fopAc_ac_c*);
+ /* 80071488 */ int SelectAttention(fopAc_ac_c*);
/* 800716B8 */ void sortList();
/* 800718A4 */ void stockAttention();
- /* 80071960 */ void nextAttention();
- /* 80071A68 */ void freeAttention();
- /* 80071A98 */ void chaseAttention();
- /* 80071CC0 */ void EnemyDistance(fopAc_ac_c*);
+ /* 80071960 */ fopAc_ac_c* nextAttention();
+ /* 80071A68 */ int freeAttention();
+ /* 80071A98 */ bool chaseAttention();
+ /* 80071CC0 */ f32 EnemyDistance(fopAc_ac_c*);
/* 80071DEC */ void runSoundProc();
/* 80071E84 */ void runDrawProc();
/* 800720F4 */ void runDebugDisp();
/* 800720F8 */ void checkButton();
- /* 800722A0 */ void triggerProc();
- /* 800722EC */ void lostCheck();
+ /* 800722A0 */ bool triggerProc();
+ /* 800722EC */ int lostCheck();
/* 80072344 */ void judgementStatus4Hold();
/* 800725F0 */ void judgementStatus4Switch();
- /* 80072924 */ void Run();
+ /* 80072924 */ int Run();
/* 80072BD4 */ void Draw();
/* 80072D80 */ void lockSoundStart(u32);
- /* 8007353C */ void LockonTarget(s32);
- /* 800735DC */ void LockonReleaseDistanse();
- /* 800736CC */ void LockonTargetPId(s32);
- /* 80073734 */ void ActionTarget(s32);
- /* 8007378C */ void CheckObjectTarget(s32);
+ /* 8007353C */ fopAc_ac_c* LockonTarget(s32);
+ /* 800735DC */ f32 LockonReleaseDistanse();
+ /* 800736CC */ u32 LockonTargetPId(s32);
+ /* 80073734 */ fopAc_ac_c* ActionTarget(s32);
+ /* 8007378C */ fopAc_ac_c* CheckObjectTarget(s32);
/* 800737E4 */ bool LockonTruth();
- /* 80073838 */ void checkDistance(cXyz*, s16, cXyz*, f32, f32, f32, f32);
+ /* 80073838 */ int checkDistance(cXyz*, s16, cXyz*, f32, f32, f32, f32);
/* 8016E424 */ void LockEdge();
/* 80182994 */ void GetCheckObjectCount();
/* 80182AD0 */ void keepLock(int);
@@ -199,6 +209,8 @@ public:
dAttCatch_c& getCatghTarget() { return mCatghTarget; }
u8 getCatchChgItem() { return mCatghTarget.getChangeItem(); }
BOOL chkFlag(u32 flag) { return mFlags & flag; }
+ void setFlag(u32 flag) { mFlags |= flag; }
+ void clrFlag(u32 flag) { mFlags &= ~flag; }
s8 Lockon() {
/* s32 chk = true;
if (!LockonTruth() && !chkFlag(0x20000000)) {
@@ -209,28 +221,28 @@ public:
return !LockonTruth() && !chkFlag(0x20000000);
}
- static u8 loc_type_tbl[12];
- static u8 act_type_tbl[20];
+ static type_tbl_entry loc_type_tbl[3];
+ static type_tbl_entry act_type_tbl[5];
static dist_entry dist_table[234];
- static u32 loc_type_num;
- static u32 act_type_num;
- static u32 chk_type_tbl;
- static u32 chk_type_num;
+ static int loc_type_num;
+ static int act_type_num;
+ static type_tbl_entry chk_type_tbl[1];
+ static int chk_type_num;
public:
/* 0x000 */ fopAc_ac_c* mpPlayer;
/* 0x004 */ u32 mLockTargetID;
/* 0x008 */ dAttDraw_CallBack_c mpDrawCallback;
- /* 0x00C */ u32 field_0xc;
+ /* 0x00C */ u32 mPadNo;
/* 0x010 */ u32 field_0x10;
/* 0x014 */ u8 field_0x14[4];
/* 0x018 */ JKRSolidHeap* heap;
- /* 0x01C */ cXyz field_0x1c;
+ /* 0x01C */ cXyz mDrawAttnPos;
/* 0x028 */ dAttDraw_c draw[2];
- /* 0x318 */ int field_0x318;
- /* 0x31C */ cXyz field_0x31c;
- /* 0x328 */ u8 field_0x328;
- /* 0x329 */ u8 field_0x329;
+ /* 0x318 */ u32 mTargetActorID;
+ /* 0x31C */ cXyz mOwnerAttnPos;
+ /* 0x328 */ s8 field_0x328;
+ /* 0x329 */ u8 mAttnStatus;
/* 0x32A */ u8 field_0x32a;
/* 0x32B */ u8 field_0x32b;
/* 0x32C */ u8 field_0x32c;
@@ -248,22 +260,17 @@ public:
/* 0x3E0 */ dAttList_c mActionList[4];
/* 0x430 */ int mActionCount;
/* 0x434 */ int mActionOffset;
- /* 0x438 */ dAttList_c field_0x438[4];
+ /* 0x438 */ dAttList_c mCheckObjectList[4];
/* 0x488 */ int mCheckObjectCount;
- /* 0x48C */ int field_0x48c;
+ /* 0x48C */ int mCheckObjectOffset;
/* 0x490 */ dAttHint_c mZHintTarget;
/* 0x49C */ dAttCatch_c mCatghTarget;
/* 0x4B4 */ dAttLook_c mLookTarget;
- /* 0x4C4 */ int field_0x4c4;
- /* 0x4C8 */ u8 field_0x4c8;
- /* 0x4C9 */ u8 field_0x4c9;
- /* 0x4CA */ u8 field_0x4ca;
- /* 0x4CB */ u8 field_0x4cb;
- /* 0x4CC */ u8 field_0x4cc;
- /* 0x4CD */ u8 field_0x4cd;
- /* 0x4CE */ u8 field_0x4ce;
- /* 0x4CF */ u8 field_0x4cf;
- /* 0x4D0 */ dAttParam_c mAttParam;
+ /* 0x4C4 */ int mAttnBlockTimer;
+ /* 0x4C8 */ dAttParam_c mAttParam;
+ /* 0x50C */ u8 field_0x50c[0x514 - 0x50c];
+ /* 0x514 */ u32 mEnemyActorID;
+ /* 0x518 */ f32 mEnemyDist;
}; // Size: 0x51C
STATIC_ASSERT(sizeof(dAttention_c) == 0x51C);
diff --git a/include/d/d_demo.h b/include/d/d_demo.h
index 584e24cc85..15d09fb5cd 100644
--- a/include/d/d_demo.h
+++ b/include/d/d_demo.h
@@ -52,15 +52,15 @@ public:
class dDemo_actor_c : public JStage::TActor {
public:
/* 80038020 */ dDemo_actor_c();
- /* 80038128 */ void getActor();
+ /* 80038128 */ fopAc_ac_c* getActor();
/* 8003815C */ void setActor(fopAc_ac_c*);
- /* 8003819C */ void getPrm_Morf();
+ /* 8003819C */ f32 getPrm_Morf();
/* 80038338 */ void getDemoIDData(int*, int*, int*, u16*, u8*);
/* 80038098 */ virtual ~dDemo_actor_c();
/* 800387EC */ virtual void JSGSetData(u32, void const*, u32);
- /* 8003A05C */ virtual void JSGFindNodeID(char const*) const;
- /* 8003A088 */ virtual void JSGGetNodeTransformation(u32, f32 (*)[4]) const;
+ /* 8003A05C */ virtual s32 JSGFindNodeID(char const*) const;
+ /* 8003A088 */ virtual int JSGGetNodeTransformation(u32, f32 (*)[4]) const;
/* 8003A0D8 */ virtual void JSGGetTranslation(Vec*) const;
/* 80038920 */ virtual void JSGSetTranslation(Vec const&);
/* 8003A0F4 */ virtual void JSGGetScaling(Vec*) const;
@@ -77,6 +77,16 @@ public:
/* 8003A0D0 */ virtual f32 JSGGetTextureAnimationFrameMax() const;
void setModel(J3DModel* p_model) { mModel = p_model; }
+ u8 checkEnable(u16 flag) { return mFlags & flag; }
+ void onEnable(u16 flag) { mFlags |= flag; }
+ cXyz& getTrans() { return mTrans; }
+ cXyz& getScale() { return mScale; }
+ csXyz& getRatate() { return mRotate; }
+ u32 getAnmId() { return mAnmId; }
+ u32 getOldAnmId() { return mOldAnmId; }
+ void setOldAnmId(u32 id) { mOldAnmId = id; }
+ void setAnmFrameMax(f32 max) { mAnmFrameMax = max; }
+ f32 getAnmFrame() { return mAnmFrame; }
private:
/* 0x04 */ u16 mFlags;
@@ -136,6 +146,8 @@ public:
/* 80038EA8 */ virtual void JSGSetAngleAttenuation(f32, GXSpotFn);
/* 80038EC0 */ virtual void JSGSetDirection(Vec const&);
+ void onEnable(u8 flag) { mFlags |= flag; }
+
private:
/* 0x04 */ u8 mFlags;
/* 0x08 */ JStage::TELight mLightType;
@@ -161,6 +173,8 @@ public:
/* 80038F10 */ virtual void JSGSetEndZ(f32);
/* 80038F24 */ virtual void JSGSetColor(GXColor);
+ void onEnable(u8 flag) { mFlags |= flag; }
+
private:
/* 0x04 */ u8 mFlags;
/* 0x05 */ u8 mFogType;
@@ -193,6 +207,8 @@ public:
/* 80038D84 */ virtual f32 JSGGetViewRoll() const;
/* 80038DDC */ virtual void JSGSetViewRoll(f32);
+ void onEnable(u8 flag) { mFlags |= flag; }
+
private:
/* 0x04 */ u8 mFlags;
/* 0x08 */ f32 mProjNear;
@@ -214,6 +230,8 @@ public:
/* 800394C8 */ virtual ~dDemo_ambient_c();
/* 80038DF0 */ virtual void JSGSetColor(GXColor);
+ void onEnable(u8 flag) { mFlags |= flag; }
+
private:
/* 0x04 */ u8 mFlags;
/* 0x05 */ GXColor mColor;
@@ -255,6 +273,8 @@ public:
static s32 getMode() { return m_mode; }
static JStudio::stb::TControl* getControl() { return m_control; }
static bool isStatus(u32 status) { return m_status & status; }
+ static void onStatus(u32 status) { m_status |= status; }
+ static void offStatus(u32 status) { m_status &= ~status; }
static void setBranchData(const u8* p_data) { m_branchData = p_data; }
static s16 m_branchId;
diff --git a/include/d/d_drawlist.h b/include/d/d_drawlist.h
index 4a4abb8f91..423383e051 100644
--- a/include/d/d_drawlist.h
+++ b/include/d/d_drawlist.h
@@ -226,6 +226,7 @@ public:
/* 80051ADC */ void setScissor(f32, f32, f32, f32);
void setCameraID(int id) { mCameraID = id; }
+ s8 getCameraID() { return mCameraID; }
void setMode(int mode) { mMode = mode; }
f32 getViewPort() { return mXOrig; }
@@ -284,6 +285,7 @@ public:
void set2DOpa(dDlst_base_c* dlst) { set(mp2DOpaSet[0], mp2DOpaSet[1], dlst); }
void set2DOpaTop(dDlst_base_c* dlst) { set(mp2DOpaTopSet[0], mp2DOpaTopSet[1], dlst); }
+ void set2DXlu(dDlst_base_c* dlst) { set(mp2DXluSet[0], mp2DXluSet[1], dlst); }
view_class* getView() { return mView; }
void setView(view_class* view) { mView = view; }
void setWindow(dDlst_window_c* window) { mWindow = window; }
@@ -303,6 +305,8 @@ public:
void setXluListItem3D() { setXluDrawList(mDrawBuffers[DB_XLU_LIST_ITEM3D]); }
void setXluListBG() { setXluDrawList(mDrawBuffers[DB_XLU_LIST_BG]); }
void setOpaListBG() { setOpaDrawList(mDrawBuffers[DB_OPA_LIST_BG]); }
+ void setOpaList3Dlast() { setOpaDrawList(mDrawBuffers[DB_LIST_3D_LAST]); }
+ void setXluList3Dlast() { setXluDrawList(mDrawBuffers[DB_LIST_3D_LAST]); }
void setXluList2DScreen() { setXluDrawList(mDrawBuffers[DB_LIST_2D_SCREEN]); }
void peekZdata() { mPeekZ.peekData(); }
diff --git a/include/d/d_lib.h b/include/d/d_lib.h
index 121bff182e..0f87597d27 100644
--- a/include/d/d_lib.h
+++ b/include/d/d_lib.h
@@ -2,6 +2,7 @@
#define D_D_LIB_H
#include "dolphin/types.h"
+#include "dolphin/os/OS.h"
struct JKRAramArchive;
u32 dLib_getExpandSizeFromAramArchive(JKRAramArchive* arc, char const* resName);
@@ -71,12 +72,13 @@ struct CSTControl : public STControl {
};
struct dLib_time_c {
- /* 80032804 */ void getTime();
+ /* 80032804 */ static OSTime getTime();
/* 80032880 */ static void stopTime();
/* 800328BC */ static void startTime();
- static u8 m_diffTime[4];
- static u8 m_stopTime[4];
+ static OSTime m_diffTime;
+ static OSTime m_stopTime;
+ static bool m_timeStopped;
};
#endif /* D_D_LIB_H */
diff --git a/include/d/event/d_event.h b/include/d/event/d_event.h
index 04a9a610cb..8da3453ea6 100644
--- a/include/d/event/d_event.h
+++ b/include/d/event/d_event.h
@@ -104,6 +104,8 @@ public:
void setPtD(void* ptr);
void setGtItm(u8 itemNo);
void isOrderOK();
+ /* 807DFAD8 */ void checkSkipEdge();
+ /* 807E2908 */ void startCheckSkipEdge(void*);
u16 chkFlag2(u16 flag) { return flag & mFlag2; }
bool runCheck() { return mEventStatus != 0; }
diff --git a/include/d/msg/d_msg_object.h b/include/d/msg/d_msg_object.h
index dbf173e88b..b42daaa3bb 100644
--- a/include/d/msg/d_msg_object.h
+++ b/include/d/msg/d_msg_object.h
@@ -273,6 +273,10 @@ inline void dMsgObject_readMessageGroup(mDoDvdThd_mountXArchive_c** param_0) {
dMsgObject_getMsgObjectClass()->readMessageGroup(param_0);
}
+inline void dMsgObject_setDemoMessage(u32 param_0) {
+ dMsgObject_getMsgObjectClass()->setDemoMessage(param_0);
+}
+
inline void dMsgObject_setShopWaitTimer(u8 timer) {
dMsgObject_c::setShopWaitTimer(timer);
}
diff --git a/include/d/particle/d_particle.h b/include/d/particle/d_particle.h
index d4a8cc965d..270c1347d0 100644
--- a/include/d/particle/d_particle.h
+++ b/include/d/particle/d_particle.h
@@ -2,9 +2,9 @@
#define D_PARTICLE_D_PARTICLE_H
#include "JSystem/JParticle/JPAParticle.h"
+#include "d/particle/d_particle_name.h"
#include "dolphin/types.h"
#include "f_op/f_op_actor.h"
-#include "d/particle/d_particle_name.h"
class dPa_levelEcallBack : public JPAEmitterCallBack {
public:
@@ -138,8 +138,8 @@ public:
/* 8004AB1C */ void create(u8);
/* 8004ABC4 */ void remove();
- /* 8004AC00 */ void setModel(JPABaseEmitter*, J3DModelData*, dKy_tevstr_c const&, u8, void*, u8,
- u8);
+ /* 8004AC00 */ static void setModel(JPABaseEmitter*, J3DModelData*, dKy_tevstr_c const&, u8,
+ void*, u8, u8);
/* 8004AC90 */ void resetModel(JPABaseEmitter*);
/* 8004ACC0 */ void setupModel(JPABaseEmitter*);
/* 8004ACEC */ void drawModel(JPABaseEmitter*, f32 (*)[4]);
@@ -152,7 +152,15 @@ public:
/* 80050014 */ virtual void drawAfter(JPABaseEmitter*);
/* 8004AAA8 */ virtual void setup(JPABaseEmitter*, cXyz const*, csXyz const*, s8);
- static u8 mEcallback[4];
+ static void setModel(JPABaseEmitter* param_0, J3DModelData* param_1,
+ const dKy_tevstr_c& param_2, u8 param_3, J3DAnmTexPattern* param_4,
+ u8 param_5) {
+ setModel(param_0, param_1, param_2, param_3, param_4, param_5);
+ }
+
+ static dPa_modelEcallBack* getEcallback() { return mEcallback; }
+
+ static dPa_modelEcallBack* mEcallback;
static u8 mPcallback[4];
static J3DModel* mModel;
};
@@ -207,7 +215,6 @@ public:
/* 8004FE6C */ virtual ~dPa_fsenthPcallBack();
/* 8004DCA0 */ virtual void execute(JPABaseEmitter*, JPABaseParticle*);
/* 8004DD0C */ virtual void draw(JPABaseEmitter*, JPABaseParticle*);
-
};
class dPa_simpleData_c {
@@ -244,7 +251,7 @@ public:
void offActive() { mStatus &= ~1; }
bool isActive() { return mStatus & 1; }
-
+
private:
/* 0x00 */ u32 mId;
/* 0x04 */ u16 mNameId;
@@ -341,6 +348,10 @@ public:
static void offStatus(u8 status) { mStatus &= ~status; }
static bool isStatus(u8 status) { return mStatus & status; }
+ static dPa_selectTexEcallBack* getTsuboSelectTexEcallBack(int idx) {
+ return ((dPa_selectTexEcallBack*)mTsubo) + idx;
+ }
+
static u8 mTsubo[64];
static u8 mLifeBall[24];
static Mtx mWindViewMatrix;