mirror of https://github.com/zeldaret/tp.git
d_a_e_zm matching (#2638)
* initial work * a little more work * matching * pr cleanup * changed 'subtype' to 'argument' * fixed debug error
This commit is contained in:
parent
1e50c25671
commit
bfeb1c048b
|
|
@ -1779,7 +1779,7 @@ config.libs = [
|
|||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_e_ymb"),
|
||||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_e_yr"),
|
||||
ActorRel(NonMatching, "d_a_e_zh"),
|
||||
ActorRel(NonMatching, "d_a_e_zm"),
|
||||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_e_zm"),
|
||||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_e_zs"),
|
||||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_formation_mng"),
|
||||
ActorRel(MatchingFor("GZ2E01", "GZ2J01"), "d_a_guard_mng"),
|
||||
|
|
|
|||
|
|
@ -1,6 +1,9 @@
|
|||
#ifndef D_A_E_ZM_H
|
||||
#define D_A_E_ZM_H
|
||||
|
||||
#include "d/d_bg_s_acch.h"
|
||||
#include "d/d_cc_d.h"
|
||||
#include "d/d_cc_uty.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
|
||||
/**
|
||||
|
|
@ -10,13 +13,15 @@
|
|||
*
|
||||
* @details
|
||||
*
|
||||
*/
|
||||
*/
|
||||
|
||||
class daE_ZM_c : public fopEn_enemy_c {
|
||||
/* 8082F9A0 */ void draw();
|
||||
public:
|
||||
/* 8082F9A0 */ int draw();
|
||||
/* 8082FBD4 */ void setBck(int, u8, f32, f32);
|
||||
/* 8082FC80 */ void setActionMode(int, int);
|
||||
/* 8082FC8C */ void damage_check();
|
||||
/* 808301E0 */ void mCutTypeCheck();
|
||||
/* 808301E0 */ bool mCutTypeCheck();
|
||||
/* 8083033C */ void executeSearchPoint();
|
||||
/* 80830398 */ void executeWait();
|
||||
/* 808309DC */ void executeMove();
|
||||
|
|
@ -27,21 +32,52 @@ class daE_ZM_c : public fopEn_enemy_c {
|
|||
/* 80831930 */ void action();
|
||||
/* 80831B08 */ void mtx_set();
|
||||
/* 80831B9C */ void cc_set();
|
||||
/* 80831D64 */ void execute();
|
||||
/* 80831E9C */ void _delete();
|
||||
/* 80831F4C */ void CreateHeap();
|
||||
/* 80832064 */ void create();
|
||||
|
||||
private:
|
||||
/* 0x5ac */ u8 field_0x5ac[0xc3c - 0x5ac];
|
||||
/* 80831D64 */ int execute();
|
||||
/* 80831E9C */ int _delete();
|
||||
/* 80831F4C */ int CreateHeap();
|
||||
/* 80832064 */ cPhs__Step create();
|
||||
|
||||
/* 0x5AC */ request_of_phase_process_class mPhase;
|
||||
/* 0x5B4 */ mDoExt_McaMorfSO* mpModelMorf;
|
||||
/* 0x5B8 */ Z2CreatureEnemy mSound;
|
||||
/* 0x65C */ int mAction;
|
||||
/* 0x660 */ int mMode;
|
||||
/* 0x664 */ u8 field_0x664[0x668 - 0x664];
|
||||
/* 0x668 */ int mAnm;
|
||||
/* 0x66C */ cXyz field_0x66c[10];
|
||||
/* 0x6E4 */ u8 field_0x6e4;
|
||||
/* 0x6E5 */ u8 field_0x6e5;
|
||||
/* 0x6E6 */ u8 field_0x6e6[0x6f4 - 0x6e6];
|
||||
/* 0x6F4 */ cXyz field_0x6f4;
|
||||
/* 0x700 */ csXyz field_0x700;
|
||||
/* 0x708 */ f32 mColor[3];
|
||||
/* 0x714 */ f32 field_0x714;
|
||||
/* 0x718 */ f32 field_0x718;
|
||||
/* 0x71C */ f32 field_0x71c;
|
||||
/* 0x720 */ s16 field_0x720;
|
||||
/* 0x722 */ u8 field_0x722;
|
||||
/* 0x723 */ u8 field_0x723;
|
||||
/* 0x724 */ u8 field_0x724;
|
||||
/* 0x725 */ u8 mTimer;
|
||||
/* 0x726 */ u8 arg0;
|
||||
/* 0x727 */ u8 arg1;
|
||||
/* 0x728 */ u8 arg2;
|
||||
/* 0x729 */ u8 bitSw;
|
||||
/* 0x72A */ u8 bitSw2;
|
||||
/* 0x72B */ u8 field_0x72b;
|
||||
/* 0x72C */ u8 field_0x72c;
|
||||
/* 0x72D */ u8 field_0x72d;
|
||||
/* 0x730 */ u32 field_0x730[3];
|
||||
/* 0x73C */ dBgS_AcchCir mAcchCir;
|
||||
/* 0x77C */ dBgS_ObjAcch mBgc;
|
||||
/* 0x954 */ dCcD_Stts mStts;
|
||||
/* 0x990 */ dCcD_Cyl mCyl;
|
||||
/* 0xACC */ dCcD_Sph mSph;
|
||||
/* 0xC04 */ dCcU_AtInfo mAtInfo;
|
||||
/* 0xC28 */ bool field_0xc28;
|
||||
/* 0xC29 */ u8 field_0xc29[0xc3c - 0xc29];
|
||||
};
|
||||
|
||||
STATIC_ASSERT(sizeof(daE_ZM_c) == 0xc3c);
|
||||
|
||||
class daE_ZM_HIO_c {
|
||||
/* 8082F94C */ daE_ZM_HIO_c();
|
||||
/* 80832800 */ ~daE_ZM_HIO_c();
|
||||
};
|
||||
|
||||
|
||||
#endif /* D_A_E_ZM_H */
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ public:
|
|||
int getGroupID() { return fopAcM_GetParam(this) & 0xff; }
|
||||
u8 getPathID() { return fopAcM_GetParam(this) >> 24; }
|
||||
int isStop() { return TRUE; }
|
||||
int getType() { return subtype & 0x7f; }
|
||||
int getType() { return argument & 0x7f; }
|
||||
int getSeqNum() { return shape_angle.x & 0x3f; }
|
||||
int getFlowNodeNum() { return shape_angle.z; }
|
||||
u16 getStartTime() { return (fopAcM_GetParam(this) >> 8) & 0xff; }
|
||||
|
|
|
|||
|
|
@ -211,7 +211,7 @@ public:
|
|||
|
||||
s16 getMessageNo() { return (fopAcM_GetParam(this) >> 8) & 0xFFFF; }
|
||||
int getWrestlerAction() { return mWrestlerAction; }
|
||||
u8 getType() { return subtype & 0x7F; }
|
||||
u8 getType() { return argument & 0x7F; }
|
||||
u8 getWrestlerType() { return getType(); }
|
||||
bool chkAction(actionFunc i_action) { return i_action == field_0xdcc; }
|
||||
bool selectAction();
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public:
|
|||
int iVar1 = fopAcM_GetParam(this) & 0xFF;
|
||||
u8 rv;
|
||||
|
||||
switch ((subtype & 127)) {
|
||||
switch ((argument & 127)) {
|
||||
case 0:
|
||||
switch (iVar1) {
|
||||
case 0:
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ public:
|
|||
int prm = fopAcM_GetParam(this) >> 0x1C;
|
||||
|
||||
u8 type;
|
||||
switch (subtype) {
|
||||
switch (argument) {
|
||||
case 0:
|
||||
switch (prm) {
|
||||
case 1:
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ public:
|
|||
/* 80D2B5C8 */ virtual int Draw();
|
||||
/* 80D2B6C0 */ virtual int Delete();
|
||||
|
||||
u8 getNameArg() { return subtype; }
|
||||
u8 getNameArg() { return argument; }
|
||||
u8 getSwNo() { return fopAcM_GetParamBit(this, 0, 8); }
|
||||
u8 getSwNo2() { return fopAcM_GetParamBit(this, 8, 8); }
|
||||
u8 getArg0() { return fopAcM_GetParamBit(this, 16, 8); }
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ public:
|
|||
static actionFuncEntry ActionTable[3];
|
||||
|
||||
const attributes* attr() const { return &M_attr; }
|
||||
int getType() { return subtype & 0x7F; }
|
||||
int getType() { return argument & 0x7F; }
|
||||
u8 getPathID() { return fopAcM_GetParam(this); }
|
||||
bool isPlayerCorrect() { return (s8)(u8)(fopAcM_GetParam(this) >> 8) > 0; }
|
||||
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ public:
|
|||
/* 80D467C0 */ void create_init();
|
||||
~daPasserMng_c() { delete [] childProcIds; }
|
||||
|
||||
u8 getDetailLevel() { return subtype; }
|
||||
u8 getDetailLevel() { return argument; }
|
||||
u8 getPathID() { return fopAcM_GetParam(this); }
|
||||
u8 getIntervalTime() { return fopAcM_GetParam(this) >> 24; }
|
||||
int getStartTime() { return (fopAcM_GetParam(this) >> 8) & 0xff; }
|
||||
|
|
|
|||
|
|
@ -246,7 +246,7 @@ public:
|
|||
/* 0x496 */ u8 group;
|
||||
/* 0x497 */ u8 cullType;
|
||||
/* 0x498 */ u8 demoActorID;
|
||||
/* 0x499 */ s8 subtype;
|
||||
/* 0x499 */ s8 argument;
|
||||
/* 0x49A */ u8 carryType;
|
||||
/* 0x49C */ u32 actor_status;
|
||||
/* 0x4A0 */ u32 actor_condition;
|
||||
|
|
|
|||
|
|
@ -707,7 +707,7 @@ void daL7ODR_c::dr_fly() {
|
|||
if (7.0f == mpModelMorf->getFrame() || 37.0f == mpModelMorf->getFrame()) {
|
||||
mSound.startCreatureSound(Z2SE_EN_DR_WING, 0, -1);
|
||||
} else if (62.0f == mpModelMorf->getFrame()) {
|
||||
subtype = 1;
|
||||
argument = 1;
|
||||
}
|
||||
|
||||
if (mpModelMorf->isStop()) {
|
||||
|
|
|
|||
|
|
@ -311,7 +311,7 @@ int daAlink_c::procGuardSlipInit(int param_0, dCcD_GObjInf* param_1) {
|
|||
mProcVar4.field_0x3010 = 0;
|
||||
mProcVar5.field_0x3012 = 0;
|
||||
|
||||
if (param_1 != NULL && param_1->GetTgHitAc() != NULL && fopAcM_GetName(param_1->GetTgHitAc()) == PROC_E_MM_MT && param_1->GetTgHitAc()->subtype == 1) {
|
||||
if (param_1 != NULL && param_1->GetTgHitAc() != NULL && fopAcM_GetName(param_1->GetTgHitAc()) == PROC_E_MM_MT && param_1->GetTgHitAc()->argument == 1) {
|
||||
if (checkBootsOrArmorHeavy()) {
|
||||
mNormalSpeed = daAlinkHIO_guard_c0::m.mMagneHvyGuardSpeed;
|
||||
mProcVar5.field_0x3012 = 1;
|
||||
|
|
|
|||
|
|
@ -3927,7 +3927,7 @@ int daB_DR_c::execute() {
|
|||
if (arg0 == 0xFF) {
|
||||
if (parentActorID != 0 && health > 1 && cLib_calcTimer<int>(&mTimer[0]) == 0) {
|
||||
fopAc_ac_c* parent;
|
||||
if (fopAcM_SearchByID(parentActorID, &parent) != 0 && parent != NULL && parent->subtype != 1) {
|
||||
if (fopAcM_SearchByID(parentActorID, &parent) != 0 && parent != NULL && parent->argument != 1) {
|
||||
if (dComIfGs_isZoneSwitch(20, fopAcM_GetRoomNo(this))) {
|
||||
dComIfGp_getEvent().setSkipProc(this, DemoSkipCallBack, 0);
|
||||
}
|
||||
|
|
@ -3965,7 +3965,7 @@ int daB_DR_c::execute() {
|
|||
current.angle = parent->current.angle;
|
||||
shape_angle = parent->shape_angle;
|
||||
|
||||
if (parent->subtype == 1 && field_0x7e0 < 54) {
|
||||
if (parent->argument == 1 && field_0x7e0 < 54) {
|
||||
if (mAnm != ANM_DR_BURU) {
|
||||
setBck(ANM_DR_BURU, 0, 0.0f, 1.0f);
|
||||
mpModelMorf->setStartFrame(111.0f);
|
||||
|
|
|
|||
|
|
@ -336,7 +336,7 @@ void daB_DRE_c::DrAction2() {
|
|||
break;
|
||||
case 2:
|
||||
if (mpModelMorf->checkFrame(110.0f)) {
|
||||
subtype = 1;
|
||||
argument = 1;
|
||||
mBlurRate = 150.0f;
|
||||
mTimers[0] = 100;
|
||||
mHideParts = true;
|
||||
|
|
|
|||
|
|
@ -1352,7 +1352,7 @@ int daDemo00_c::execute() {
|
|||
|
||||
if (actor == NULL) {
|
||||
fopAcM_delete(this);
|
||||
OS_REPORT("汎用くん<dactor%d>削除!!\n", subtype);
|
||||
OS_REPORT("汎用くん<dactor%d>削除!!\n", argument);
|
||||
} else {
|
||||
if (actor->checkEnable(dDemo_actor_c::ENABLE_SHAPE_e)) {
|
||||
mModel.field_0x0.mShapeID = actor->getShapeId();
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
|
||||
/* 80672838-80672844 000078 000C+00 15/15 0/0 0/0 .text getNowLevel__FP10fopAc_ac_c */
|
||||
static int getNowLevel(fopAc_ac_c* i_this) {
|
||||
return static_cast<daMBdoorL1_c*>(i_this)->subtype;
|
||||
return static_cast<daMBdoorL1_c*>(i_this)->argument;
|
||||
}
|
||||
|
||||
/* 80672844-80672894 000084 0050+00 1/1 0/0 0/0 .text searchStop__FPvPv */
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -119,12 +119,12 @@ static int daKytag01_Execute(kytag01_class* i_this) {
|
|||
camera_class* camera = dComIfGp_getCamera(0);
|
||||
fopAc_ac_c* player = dComIfGp_getPlayer(0);
|
||||
|
||||
if ((a_this->subtype & 0xFF) == 2) {
|
||||
if ((a_this->argument & 0xFF) == 2) {
|
||||
if (i_this->mStartPoint == dComIfGs_getStartPoint()) {
|
||||
i_this->mStartPoint = 0xFF;
|
||||
dKy_change_colpat(i_this->field_0x59e);
|
||||
}
|
||||
} else if ((a_this->subtype & 0xFF) == 0) {
|
||||
} else if ((a_this->argument & 0xFF) == 0) {
|
||||
if (a_this->home.roomNo == dComIfGp_roomControl_getStayNo()) {
|
||||
if (i_this->mSwNo1 != 0xFF) {
|
||||
if (dComIfGs_isSwitch(i_this->mSwNo1, a_this->home.roomNo)) {
|
||||
|
|
@ -178,7 +178,7 @@ static int daKytag01_Create(fopAc_ac_c* i_this) {
|
|||
kytag01_class* a_this = (kytag01_class*)i_this;
|
||||
fopAcM_SetupActor(i_this, kytag01_class);
|
||||
|
||||
if ((a_this->subtype & 0xFF) == 2) {
|
||||
if ((a_this->argument & 0xFF) == 2) {
|
||||
a_this->mNamiInnerRange = i_this->scale.x * 100.0f;
|
||||
a_this->field_0x59d = fopAcM_GetParam(i_this);
|
||||
a_this->mStartPoint = fopAcM_GetParam(i_this) >> 8;
|
||||
|
|
@ -197,7 +197,7 @@ static int daKytag01_Create(fopAc_ac_c* i_this) {
|
|||
a_this->mSwNo2 = (i_this->current.angle.x >> 8) & 0xFF;
|
||||
a_this->field_0x594 = 0.0f;
|
||||
|
||||
if ((a_this->subtype & 0xFF) == 0) {
|
||||
if ((a_this->argument & 0xFF) == 0) {
|
||||
if (a_this->mNamiSize == 255.0f) {
|
||||
a_this->mNamiSize = 10.0f;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ int daNocrm_c::execute() {
|
|||
|
||||
if (sp14.y < 0.0f || sp14.y > scale.y || fabsf(sp14.x) > scale.x || fabsf(sp14.z) > scale.z)
|
||||
{
|
||||
if (subtype == 0 || !mRoomLoading ||
|
||||
if (argument == 0 || !mRoomLoading ||
|
||||
dStage_stagInfo_GetSTType(dComIfGp_getStage()->getStagInfo()) != 0)
|
||||
{
|
||||
return 1;
|
||||
|
|
@ -87,7 +87,7 @@ int daNocrm_c::execute() {
|
|||
player_p->shape_angle.y, 1);
|
||||
}
|
||||
|
||||
if (subtype == 0) {
|
||||
if (argument == 0) {
|
||||
dStage_roomControl_c::setRoomReadId(getReadRoomId());
|
||||
} else {
|
||||
dStage_roomControl_c::onNoChangeRoom();
|
||||
|
|
@ -119,7 +119,7 @@ int daNocrm_c::getRoomNo(int param_0) {
|
|||
}
|
||||
|
||||
int daNocrm_c::create() {
|
||||
if (subtype == 0 && getReadRoomId() < 0) {
|
||||
if (argument == 0 && getReadRoomId() < 0) {
|
||||
// "Room Load Rectangle: Load ID is -1, so destroy self!\n"
|
||||
OSReport_Warning("部屋読み込み矩形:読み込みIDが−1ですので、自滅します!\n");
|
||||
return cPhs_ERROR_e;
|
||||
|
|
|
|||
|
|
@ -1570,7 +1570,7 @@ void daNpc_zrA_c::drawOtherMdls() {
|
|||
|
||||
/* 80B7C44C-80B7C4B4 00402C 0068+00 2/1 0/0 0/0 .text getTypeFromArgument__11daNpc_zrA_cFv */
|
||||
daNpc_zrA_c::Type daNpc_zrA_c::getTypeFromArgument() {
|
||||
switch (subtype) {
|
||||
switch (argument) {
|
||||
case 0:
|
||||
return TYPE_WAIT;
|
||||
case 1:
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ int daZraFreeze_c::CreateHeap() {
|
|||
"zrA_pain_TW.bmd",
|
||||
"zrA_sol_TW.bmd",
|
||||
};
|
||||
J3DModelData* model_data = (J3DModelData*)dComIfG_getObjectRes(l_arcName, l_bmdName[subtype]);
|
||||
J3DModelData* model_data = (J3DModelData*)dComIfG_getObjectRes(l_arcName, l_bmdName[argument]);
|
||||
mpModel = mDoExt_J3DModel__create(model_data, 0x80000, 0x11000084);
|
||||
if (mpModel == NULL) {
|
||||
return 0;
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@ static int CheckCreateHeap(fopAc_ac_c* i_this) {
|
|||
int daSwhit0_c::create() {
|
||||
fopAcM_SetupActor(this, daSwhit0_c);
|
||||
|
||||
if (subtype != 0) {
|
||||
if (argument != 0) {
|
||||
setDrawMtx();
|
||||
cMtx_copy(mDoMtx_stack_c::get(), field_0x5a8);
|
||||
fopAcM_SetMtx(this, field_0x5a8);
|
||||
|
|
@ -438,7 +438,7 @@ int daSwhit0_c::draw() {
|
|||
|
||||
/* 80487138-80487228 0011B8 00F0+00 1/0 0/0 0/0 .text daSwhit0_Draw__FP10daSwhit0_c */
|
||||
static int daSwhit0_Draw(daSwhit0_c* i_this) {
|
||||
if (i_this->subtype != 0) {
|
||||
if (i_this->argument != 0) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
@ -487,7 +487,7 @@ static int daSwhit0_Execute(daSwhit0_c* i_this) {
|
|||
|
||||
/* 804872E4-8048732C 001364 0048+00 1/0 0/0 0/0 .text daSwhit0_Delete__FP10daSwhit0_c */
|
||||
static int daSwhit0_Delete(daSwhit0_c* i_this) {
|
||||
if (i_this->subtype == 0) {
|
||||
if (i_this->argument == 0) {
|
||||
dComIfG_resDelete(i_this, l_arcName);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ static int fopAc_Create(void* i_this) {
|
|||
a_this->home.angle = append->base.angle;
|
||||
a_this->shape_angle = append->base.angle;
|
||||
a_this->parentActorID = append->parent_id;
|
||||
a_this->subtype = append->subtype;
|
||||
a_this->argument = append->subtype;
|
||||
a_this->scale.set(append->scale.x * 0.1f, append->scale.y * 0.1f,
|
||||
append->scale.z * 0.1f);
|
||||
a_this->setID = append->base.setID;
|
||||
|
|
|
|||
|
|
@ -1911,7 +1911,7 @@ void fopAcM_setEffectMtx(const fopAc_ac_c* i_actor, const J3DModelData* modelDat
|
|||
|
||||
/* 8001D5A4-8001D5EC 017EE4 0048+00 1/1 0/0 0/0 .text fopAcM_getProcNameString__FPC10fopAc_ac_c */
|
||||
static const char* fopAcM_getProcNameString(const fopAc_ac_c* i_actor) {
|
||||
const char* name = dStage_getName2(i_actor->base.profname, i_actor->subtype);
|
||||
const char* name = dStage_getName2(i_actor->base.profname, i_actor->argument);
|
||||
return name != NULL ? name : "UNKOWN";
|
||||
}
|
||||
|
||||
|
|
@ -1923,7 +1923,7 @@ static const fopAc_ac_c* fopAcM_findObjectCB(fopAc_ac_c const* i_actor, void* i_
|
|||
return NULL;
|
||||
}
|
||||
|
||||
if (prm->procname == fopAcM_GetProfName(i_actor) && prm->subtype == i_actor->subtype) {
|
||||
if (prm->procname == fopAcM_GetProfName(i_actor) && prm->subtype == i_actor->argument) {
|
||||
if (prm->prm0 == 0 || prm->prm1 == (prm->prm0 & fopAcM_GetParam(i_actor))) {
|
||||
return i_actor;
|
||||
}
|
||||
|
|
@ -1957,7 +1957,7 @@ fopAc_ac_c* fopAcM_findObject4EventCB(fopAc_ac_c* i_actor, void* i_data) {
|
|||
return NULL;
|
||||
}
|
||||
|
||||
if (prm->procname == fopAcM_GetProfName(i_actor) && prm->subtype == i_actor->subtype) {
|
||||
if (prm->procname == fopAcM_GetProfName(i_actor) && prm->subtype == i_actor->argument) {
|
||||
if (prm->event_id < 0 || prm->event_id == i_actor->eventInfo.getIdx()) {
|
||||
return i_actor;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue