mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-01 08:07:49 -04:00
Finished porting all actor classes to headers
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
// Translation Unit: d_a_obj_paper.cpp
|
||||
//
|
||||
|
||||
#include "d/actor/d_a_obj_paper.h"
|
||||
#include "JSystem/JKernel/JKRHeap.h"
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
#include "f_op/f_op_actor.h"
|
||||
@@ -27,12 +28,6 @@ static f64 dummy4[2] = {3.0f, 0.5f};
|
||||
|
||||
namespace daObjPaper {
|
||||
namespace {
|
||||
enum Type_e {
|
||||
Opaper_e,
|
||||
Ppos_e,
|
||||
Piwa_e,
|
||||
};
|
||||
|
||||
struct Attr_c {
|
||||
/* 0x00 */ char* mResName;
|
||||
/* 0x04 */ s32 mHeapSize;
|
||||
@@ -59,7 +54,7 @@ namespace daObjPaper {
|
||||
inline const Attr_c & attr(Type_e type) { return L_attr[type]; }
|
||||
}
|
||||
|
||||
static const dCcD_SrcCyl M_cyl_src = {
|
||||
const dCcD_SrcCyl Act_c::M_cyl_src = {
|
||||
// dCcD_SrcGObjInf
|
||||
{
|
||||
/* Flags */ 0,
|
||||
@@ -89,64 +84,6 @@ namespace daObjPaper {
|
||||
},
|
||||
};
|
||||
|
||||
enum Act_Mode_e {
|
||||
ActMode_WAIT_e,
|
||||
ActMode_TALKBEGIN_e,
|
||||
ActMode_GETMSG_e,
|
||||
ActMode_TALKWAIT_e,
|
||||
};
|
||||
|
||||
class Act_c : public fopAc_ac_c {
|
||||
public:
|
||||
static int solidHeapCB(fopAc_ac_c*);
|
||||
bool create_heap();
|
||||
s32 _create();
|
||||
bool _delete();
|
||||
|
||||
void mode_wait_init();
|
||||
void mode_wait();
|
||||
|
||||
void mode_talk0_init();
|
||||
void mode_talk0();
|
||||
|
||||
void mode_talk1_init();
|
||||
void mode_talk1();
|
||||
|
||||
void mode_talk2_init();
|
||||
void mode_talk2();
|
||||
|
||||
void set_mtx();
|
||||
void init_mtx();
|
||||
|
||||
void damage_cc_proc();
|
||||
bool _execute();
|
||||
bool _draw();
|
||||
|
||||
public:
|
||||
/* 0x290 */ request_of_phase_process_class mPhs;
|
||||
/* 0x298 */ J3DModel* mpModel;
|
||||
|
||||
/* 0x29C */ dCcD_Cyl mCylinderCol;
|
||||
/* 0x3CC */ dCcD_Stts mColStatus;
|
||||
/* 0x408 */ bool mbHasCc;
|
||||
|
||||
/* 0x40C */ int mMode;
|
||||
/* 0x410 */ u32 mMsgId;
|
||||
/* 0x414 */ msg_class* mpMsg;
|
||||
/* 0x418 */ Type_e mType;
|
||||
|
||||
enum Prm_e {
|
||||
PRM_MSG_NO_W = 0x10,
|
||||
PRM_MSG_NO_S = 0x00,
|
||||
|
||||
PRM_TYPE_W = 0x04,
|
||||
PRM_TYPE_S = 0x10,
|
||||
};
|
||||
|
||||
u32 prm_get_msgNo() const { return daObj::PrmAbstract<Prm_e>(this, PRM_MSG_NO_W, PRM_MSG_NO_S); }
|
||||
Type_e prm_get_type() const { return (Type_e)daObj::PrmAbstract<Prm_e>(this, PRM_TYPE_W, PRM_TYPE_S); }
|
||||
};
|
||||
|
||||
/* 00000078-0000009C .text solidHeapCB__Q210daObjPaper5Act_cFP10fopAc_ac_c */
|
||||
int Act_c::solidHeapCB(fopAc_ac_c* i_this) {
|
||||
return static_cast<Act_c*>(i_this)->create_heap();
|
||||
@@ -177,7 +114,7 @@ namespace daObjPaper {
|
||||
s32 result = dComIfG_resLoad(&mPhs, attr(mType).mResName);
|
||||
|
||||
if (result == cPhs_COMPLEATE_e) {
|
||||
if (fopAcM_entrySolidHeap(this, (heapCallbackFunc)solidHeapCB, attr(mType).mHeapSize)) {
|
||||
if (fopAcM_entrySolidHeap(this, solidHeapCB, attr(mType).mHeapSize)) {
|
||||
mEyePos.y += attr(mType).mEyeOffset;
|
||||
|
||||
mAttentionInfo.mPosition.y += attr(mType).mAttentionOffset;
|
||||
|
||||
Reference in New Issue
Block a user