d_a_obj_swpropeller OK, work on d_kankyo / misc

This commit is contained in:
TakaRikka
2023-08-02 01:31:23 -07:00
parent 24161e34d2
commit 854fb607b9
16 changed files with 1622 additions and 706 deletions
+2 -2
View File
@@ -10,13 +10,13 @@
#include "m_Do/m_Do_lib.h"
struct J3DGXColorS10 {
/* 8000E460 */ J3DGXColorS10();
/* 8000E460 */ J3DGXColorS10() {}
_GXColorS10 mColor;
};
struct J3DGXColor : public _GXColor {
/* 8000E538 */ J3DGXColor();
/* 8000E538 */ J3DGXColor() {}
};
struct J3DNBTScaleInfo {
+2
View File
@@ -23,6 +23,8 @@ class J3DLightObj {
public:
/* 80018C0C */ J3DLightObj() : mInfo(j3dDefaultLightInfo) {}
J3DLightInfo& getLightInfo() { return mInfo; }
/* 0x00 */ J3DLightInfo mInfo;
/* 0x34 */ u8 field_0x34[64];
}; // Size = 0x74
+30 -6
View File
@@ -29,6 +29,7 @@ enum cCcD_ObjAtType {
/* 0x00000008 */ AT_TYPE_THROW_OBJ = (1 << 3),
/* 0x00000010 */ AT_TYPE_SHIELD_ATTACK = (1 << 4),
/* 0x00000020 */ AT_TYPE_BOMB = (1 << 5),
/* 0x00000040 */ AT_TYPE_40 = (1 << 6),
/* 0x00000080 */ AT_TYPE_SLINGSHOT = (1 << 7),
/* 0x00000200 */ AT_TYPE_LANTERN_SWING = (1 << 9),
/* 0x00000400 */ AT_TYPE_CSTATUE_SWING = (1 << 10),
@@ -272,25 +273,33 @@ public:
STATIC_ASSERT(0x40 == sizeof(cCcD_DivideArea));
struct cCcD_SrcObjCommonBase {
/* 0x0 */ s32 mSPrm;
};
struct cCcD_SrcObjTg {
/* 0x0 */ s32 mType;
/* 0x4 */ s32 mSPrm;
/* 0x4 */ cCcD_SrcObjCommonBase mBase;
}; // Size: 0x8
struct cCcD_SrcObjAt {
/* 0x0 */ s32 mType;
/* 0x4 */ u8 mAtp;
/* 0x8 */ s32 mSPrm;
/* 0x8 */ cCcD_SrcObjCommonBase mBase;
}; // Size: 0xC
struct cCcD_SrcObjCo {
/* 0x0 */ cCcD_SrcObjCommonBase mBase;
}; // Size: 0x4
struct cCcD_SrcObjHitInf {
/* 0x00 */ cCcD_SrcObjAt mObjAt;
/* 0x0C */ cCcD_SrcObjTg mObjTg;
/* 0x14 */ s32 mSPrm;
/* 0x14 */ cCcD_SrcObjCo mObjCo;
}; // Size: 0x18
struct cCcD_SrcObj {
/* 0x0 */ int field_0x0;
/* 0x0 */ int mFlags;
/* 0x4 */ cCcD_SrcObjHitInf mSrcObjHitInf;
}; // Size: 0x1C
@@ -345,6 +354,13 @@ protected:
/* 0x08 */ cCcD_Obj* mHitObj;
/* 0x0C vtable */
public:
enum CoSPrm_e {
CO_SPRM_SET = 1,
CO_SPRM_NO_CRR = 0x100,
CO_SPRM_NO_CO_HIT_INF_SET = 0x200,
CO_SPRM_SAME_ACTOR_HIT = 0x400,
};
cCcD_ObjCommonBase() { ct(); }
/* 8008409C */ virtual ~cCcD_ObjCommonBase() {}
/* 802639B0 */ void ct();
@@ -357,6 +373,10 @@ public:
u32 MskRPrm(u32 mask) { return mRPrm & mask; }
void OnSPrmBit(u32 flag) { mSPrm |= flag; }
void OffSPrmBit(u32 flag) { mSPrm &= ~flag; }
void Set(cCcD_SrcObjCommonBase const& src) {
mSPrm = src.mSPrm;
}
};
STATIC_ASSERT(0x10 == sizeof(cCcD_ObjCommonBase));
@@ -421,6 +441,10 @@ public:
u32 ChkSph3DCrr() const { return MskSPrm(0x80); }
void ClrSet() { OffSPrmBit(1); }
u32 ChkHit() { return MskRPrm(1); }
void Set(cCcD_SrcObjCo const& src) {
cCcD_ObjCommonBase::Set(src.mBase);
}
};
STATIC_ASSERT(0x10 == sizeof(cCcD_ObjCo));
@@ -510,10 +534,10 @@ public:
void SetStts(cCcD_Stts* stts) { mStts = stts; }
cCcD_DivideInfo& GetDivideInfo() { return mDivideInfo; }
cCcD_DivideInfo* GetPDivideInfo() { return &mDivideInfo; }
int ChkBsRevHit() const { return field_0x40 & 2; }
int ChkBsRevHit() const { return mFlags & 2; }
private:
/* 0x040 */ int field_0x40;
/* 0x040 */ int mFlags;
/* 0x044 */ cCcD_Stts* mStts;
/* 0x048 */ cCcD_DivideInfo mDivideInfo;
}; // Size = 0x58
+1 -1
View File
@@ -4,7 +4,7 @@
#include "dolphin/types.h"
struct counter_class {
s32 mCounter0;
u32 mCounter0;
s32 mCounter1;
s32 mTimer;
};
+6
View File
@@ -1789,6 +1789,12 @@ inline u8 dComIfGp_att_getCatchChgItem() {
return dComIfGp_getAttention().getCatchChgItem();
}
inline void dComIfGp_att_LookRequest(fopAc_ac_c* param_0, f32 i_horizontalDist, f32 i_upDist,
f32 i_downDist, s16 i_angle, int param_5) {
dComIfGp_getAttention().LookRequest(param_0, i_horizontalDist, i_upDist, i_downDist, i_angle,
param_5);
}
inline J2DGrafContext* dComIfGp_getCurrentGrafPort() {
return g_dComIfG_gameInfo.play.getCurrentGrafPort();
}
+6 -1
View File
@@ -215,10 +215,15 @@ public:
int GetActionCount() { return mActionCount; }
int GetLockonCount() { return mLockonCount; }
bool Lockon() { return LockonTruth() || chkFlag(0x20000000); } // only matches with -O2?
int ZHintRequest(fopAc_ac_c *param_1, int param_2) {
int ZHintRequest(fopAc_ac_c* param_1, int param_2) {
return mZHintTarget.request(param_1, param_2);
}
void LookRequest(fopAc_ac_c* param_0, f32 i_horizontalDist, f32 i_upDist, f32 i_downDist,
s16 i_angle, int param_5) {
mLookTarget.request(param_0, i_horizontalDist, i_upDist, i_downDist, i_angle, param_5);
}
static dist_entry& i_getDistTable(int i_no) { return dist_table[i_no]; }
static type_tbl_entry loc_type_tbl[3];
+2 -2
View File
@@ -782,7 +782,7 @@ public:
/* 80024954 */ static bool resetArchiveBank(int);
/* 80024DB0 */ static void SetTimePass(int);
/* 8025BAAC */ static void setZoneNo(int, int);
static s32 GetTimePass();
static s8 GetTimePass();
static s8 getStayNo() { return mStayNo; }
static u8 getRegionNo(int i_roomNo) { return mStatus[i_roomNo].mRegionNo; }
@@ -1031,7 +1031,7 @@ inline s32 i_dStage_stagInfo_GetSaveTbl(stage_stag_info_class* param_0) {
}
inline s8 dStage_stagInfo_GetTimeH(stage_stag_info_class* p_info) {
return p_info->field_0x0c >> 8;
return (p_info->field_0x0c >> 8) & 0xFF;
}
inline BOOL dStage_staginfo_GetArchiveHeap(stage_stag_info_class* p_info) {
+10 -9
View File
@@ -12,6 +12,7 @@
class JPABaseEmitter;
class cBgS_PolyInfo;
class color_RGB_class;
void dKankyo_DayProc();
void dKy_set_nexttime(f32);
@@ -44,6 +45,11 @@ void dKy_setLight();
cXyz dKy_plight_near_pos();
void dKy_BossSpotLight_set(cXyz* param_0, f32 param_1, f32 param_2, f32 param_3, _GXColor* param_4,
f32 param_5, u8 param_6, u8 param_7);
static void dKy_calc_color_set(_GXColorS10* param_0, color_RGB_class* param_1,
color_RGB_class* param_2, color_RGB_class* param_3,
color_RGB_class* param_4, f32 param_5, f32 param_6,
_GXColorS10 param_7, f32 param_8);
static void dKy_twilight_camelight_set();
struct LIGHT_INFLUENCE {
/* 800CFC7C */ ~LIGHT_INFLUENCE() {}
@@ -203,7 +209,7 @@ public:
/* 0x367 */ u8 field_0x367;
/* 0x368 */ f32 mFogStartZ;
/* 0x36C */ f32 mFogEndZ;
/* 0x370 */ f32 field_0x370;
/* 0x370 */ f32 mColpatBlend;
/* 0x374 */ f32 field_0x374;
/* 0x378 */ u16 field_0x378;
/* 0x37A */ u8 field_0x37a;
@@ -379,9 +385,7 @@ public:
/* 0x1058 */ dKankyo_evil_Packet* mpEvilPacket;
/* 0x105C */ mDoExt_btkAnm* field_0x105c;
/* 0x1060 */ fopAc_ac_c* field_0x1060;
/* 0x1064 */ f32 field_0x1064;
/* 0x1068 */ f32 field_0x1068;
/* 0x106C */ f32 field_0x106c;
/* 0x1064 */ Vec field_0x1064;
/* 0x1070 */ cXyz mSunPos2;
/* 0x107C */ cXyz mPLightNearPos;
/* 0x1088 */ cXyz mSunPos;
@@ -394,10 +398,7 @@ public:
/* 0x10D8 */ GXColorS10 mUnderCloudShadowColor;
/* 0x10E0 */ GXColorS10 mCloudOuterHazeColor;
/* 0x10E8 */ GXColorS10 mCloudInnerHazeColor;
/* 0x10F0 */ s16 field_0x10f0;
/* 0x10F2 */ s16 field_0x10f2;
/* 0x10F4 */ s16 field_0x10f4;
/* 0x10F6 */ s16 field_0x10f6;
/* 0x10F0 */ GXColorS10 field_0x10f0;
/* 0x10F8 */ s16 field_0x10f8;
/* 0x10FA */ s16 field_0x10fa;
/* 0x10FC */ s16 field_0x10fc;
@@ -493,7 +494,7 @@ public:
/* 0x12B8 */ u8 field_0x12b8[4];
/* 0x12BC */ u16 mFogAdjCenter;
/* 0x12BE */ u16 mDate;
/* 0x12C0 */ u16 mActorLightEffect;
/* 0x12C0 */ s16 mActorLightEffect;
/* 0x12C2 */ u8 mColPatPrev;
/* 0x12C3 */ u8 mColPatCurr;
/* 0x12C4 */ u8 mColpatPrevGather;
-1
View File
@@ -237,7 +237,6 @@ public:
virtual void draw();
virtual ~dKankyo_vrkumo_Packet();
private:
/* 0x0010 */ GXColor mColor;
/* 0x0014 */ u8* mpResCloudtx_01;
/* 0x0018 */ u8* mpResCloudtx_02;
+4
View File
@@ -119,6 +119,10 @@ inline void mDoAud_mEnvse_framework() {
g_mEnvSeMgr.framework();
}
inline void mDoAud_mEnvse_resetScene() {
g_mEnvSeMgr.resetScene();
}
inline void mDoAud_mEnvSe_startFarThunderSe(const Vec* param_0) {
g_mEnvSeMgr.startFarThunderSe((Vec*)param_0, 0);
}
@@ -1,6 +1,49 @@
#ifndef D_A_OBJ_SWPROPELLER_H
#define D_A_OBJ_SWPROPELLER_H
#include "dolphin/types.h"
#include "d/cc/d_cc_d.h"
#include "f_op/f_op_actor_mng.h"
class daObjSwPr_c : public fopAc_ac_c {
public:
/* 8059A5E8 */ void initBaseMtx();
/* 8059A624 */ void setBaseMtx();
/* 8059A670 */ int Create();
/* 8059A808 */ int CreateHeap();
/* 8059A888 */ int create();
/* 8059AB04 */ int setRotateTime();
/* 8059AB14 */ void switchCtrl();
/* 8059AB9C */ void execute_type_boomerang();
/* 8059ADCC */ void execute_type_wind();
/* 8059B014 */ int execute();
/* 8059B148 */ int draw();
/* 8059B1AC */ int _delete();
u8 getNameArg() { return fopAcM_GetParamBit(this, 8, 8); }
u8 getMdlType() { return fopAcM_GetParamBit(this, 0x10, 4); }
int getSwbit() { return fopAcM_GetParamBit(this, 0, 8); }
u32 getSwbit2() { return fopAcM_GetParamBit(this, 0x18, 8); }
/* 0x568 */ request_of_phase_process_class mPhase;
/* 0x570 */ J3DModel* mpModel;
/* 0x574 */ dCcD_Stts mCcStts;
/* 0x5B0 */ dCcD_Cyl mCyl1;
/* 0x6EC */ dCcD_Cyl mCyl2;
/* 0x828 */ s16 mRotateSpeed;
/* 0x82A */ s16 mRotateInitSpeed;
/* 0x82C */ s16 field_0x82c; // rotate angle?
/* 0x82E */ s16 mRotateTime;
/* 0x830 */ u16 mKaitenJntID;
/* 0x832 */ s16 mSwDelayTimer;
/* 0x834 */ u16 field_0x834;
/* 0x836 */ u16 mSwOffDelayTimer;
/* 0x838 */ u8 field_0x838;
/* 0x839 */ u8 field_0x839;
/* 0x83A */ u8 field_0x83a;
/* 0x83B */ u8 field_0x83b;
/* 0x83C */ u8 mNameArg;
/* 0x83D */ u8 field_0x83d;
/* 0x83E */ u8 mModelType;
};
#endif /* D_A_OBJ_SWPROPELLER_H */