GCN data 100% matching (#2987)

* Update GZ2J01 symbols from linked DOL

* GCN data 100% matching

* Run dtk apply
This commit is contained in:
Max Roncace
2025-12-22 18:41:19 -05:00
committed by GitHub
parent 8fece471c6
commit 9767e76ba0
2576 changed files with 14309 additions and 12675 deletions
-2
View File
@@ -295,8 +295,6 @@ static u32 SizeOfLoadAmbColors = 13;
static u32 SizeOfLoadColorChans = 21;
static u8 sdata_padding[4] = {};
static u32 SizeOfJ3DColorBlockLightOffLoad = SizeOfLoadMatColors + SizeOfLoadColorChans;
void J3DColorBlockLightOff::load() {
+6 -8
View File
@@ -21,13 +21,11 @@ void JASDrumSet::newPercArray(u8 param_0, JKRHeap* param_1) {
}
}
static JASOscillator::Data osc;
static JASOscillator::Data* oscp;
static s8 data_80451274[4];
bool JASDrumSet::getParam(int param_0, int param_1, JASInstParam* param_2) const {
static JASOscillator::Data osc;
static JASOscillator::Data* oscp;
static s8 data_80451274;
if (field_0x4 == NULL) {
return false;
}
@@ -54,9 +52,9 @@ bool JASDrumSet::getParam(int param_0, int param_1, JASInstParam* param_2) const
osc.mScale = 1.0f;
osc._14 = 0.0f;
if (data_80451274[0] == 0) {
if (data_80451274 == 0) {
oscp = &osc;
data_80451274[0] = 1;
data_80451274 = 1;
}
param_2->field_0x14 = &oscp;
@@ -83,7 +83,6 @@ typedef struct mem_pool_obj {
} mem_pool_obj;
mem_pool_obj __malloc_pool;
static int initialized = 0;
static SubBlock* SubBlock_merge_prev(SubBlock*, SubBlock**);
static void SubBlock_merge_next(SubBlock*, SubBlock**);
+6 -6
View File
@@ -24,8 +24,8 @@ f32 daAlink_c::getCrawlMoveSpeed() {
}
void daAlink_c::setCrawlMoveDirectionArrow() {
static const u8 data_80452F38[1] = {1};
static const u8 data_80452F39[1] = {4};
static const u8 data_80452F38 = 1;
static const u8 data_80452F39 = 4;
u8 direction = 0;
camera_class* camera = (camera_class*)dComIfGp_getCamera(field_0x317c);
@@ -33,17 +33,17 @@ void daAlink_c::setCrawlMoveDirectionArrow() {
if (field_0x3198 & 4) {
if (!bvar) {
direction = *data_80452F38;
direction |= data_80452F38;
} else {
direction = *data_80452F39;
direction |= data_80452F39;
}
}
if (field_0x3198 & 8) {
if (!bvar) {
direction |= *data_80452F39;
direction |= data_80452F39;
} else {
direction |= *data_80452F38;
direction |= data_80452F38;
}
}
+42 -42
View File
@@ -1444,11 +1444,11 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamEyeTarget.set(240.0f, 274.0f, 2075.0f);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
}
spFC.set(0.0f, 0.0f, 1700.0f);
@@ -1478,16 +1478,16 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamCenterTarget.set(76.0f, 204.0f, 1782.0f);
i_this->mDemoCamEyeTarget.set(-41.0f, 261.0f, 2095.0f);
i_this->field_0x127c.x = fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x127c.x = std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
i_this->field_0x129c = 0.0f;
i_this->mDemoMode = 12;
@@ -1584,16 +1584,16 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamCenterTarget.set(0.0f, 278.0f, 1252.0f);
i_this->mDemoCamEyeTarget.set(0.0f, 86.0f, 2167.0f);
i_this->field_0x127c.x = fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x127c.x = std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
i_this->field_0x129c = 0.0f;
i_this->mDemoMode = 14;
@@ -1741,16 +1741,16 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamCenterTarget.set(-2243.0f, 1340.0f, 977.0f);
i_this->mDemoCamEyeTarget.set(-1226.0f, 980.0f, 1350.0f);
i_this->field_0x127c.x = fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x127c.x = std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
i_this->field_0x129c = 0.0f;
i_this->mDemoMode = 34;
@@ -1814,9 +1814,9 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamEye.set(95.0f, 50.0f, 2800.0f);
i_this->mDemoCamEyeTarget.set(72.0f, 52.0f, 2153.0f);
i_this->field_0x127c.x = fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x127c.x = std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y = std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z = std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.set(0.0f, 0.0f, 0.0f);
i_this->field_0x129c = 0.0f;
@@ -1973,18 +1973,18 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamEyeTarget.set(1214.0f, 350.0f, 2696.0f);
i_this->field_0x127c.x =
fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y =
fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z =
fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
i_this->field_0x129c = 0.0f;
} else if (i_this->mDemoModeTimer < 140) {
@@ -1993,18 +1993,18 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamEyeTarget.set(23.0f, 108.0f, 2155.0f);
i_this->field_0x127c.x =
fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y =
fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z =
fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
}
cam_3d_morf(i_this, 0.1f);
@@ -2042,18 +2042,18 @@ static void demo_camera(b_bq_class* i_this) {
i_this->mDemoCamEyeTarget.set(953.0f, 997.0f, -36.0f);
i_this->field_0x127c.x =
fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
std::fabsf(i_this->mDemoCamEyeTarget.x - i_this->mDemoCamEye.x);
i_this->field_0x127c.y =
fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
std::fabsf(i_this->mDemoCamEyeTarget.y - i_this->mDemoCamEye.y);
i_this->field_0x127c.z =
fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
std::fabsf(i_this->mDemoCamEyeTarget.z - i_this->mDemoCamEye.z);
i_this->field_0x1288.x =
fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
std::fabsf(i_this->mDemoCamCenterTarget.x - i_this->mDemoCamCenter.x);
i_this->field_0x1288.y =
fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
std::fabsf(i_this->mDemoCamCenterTarget.y - i_this->mDemoCamCenter.y);
i_this->field_0x1288.z =
fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
std::fabsf(i_this->mDemoCamCenterTarget.z - i_this->mDemoCamCenter.z);
cXyz pos(0.0f, 0.0f, 0.0f);
for (int i = 0; i < 5; i++) {
+4 -4
View File
@@ -1553,7 +1553,7 @@ bool daB_TN_c::checkMoveAngle() {
}
void daB_TN_c::setAttackBlurEffect(int i_data) {
static u16 blur_effect_id_5997[4] = {
static u16 blur_effect_id[4] = {
0x87DA,
0x87DB,
0x87DC,
@@ -1562,7 +1562,7 @@ void daB_TN_c::setAttackBlurEffect(int i_data) {
if (i_data != 0) {
for (int i = 0; i < 4; i++) {
mParticleKeys[i] = dComIfGp_particle_set(mParticleKeys[i], blur_effect_id_5997[i],
mParticleKeys[i] = dComIfGp_particle_set(mParticleKeys[i], blur_effect_id[i],
&current.pos, &tevStr);
JPABaseEmitter* mBaseEmitter = dComIfGp_particle_getEmitter(mParticleKeys[i]);
@@ -1574,7 +1574,7 @@ void daB_TN_c::setAttackBlurEffect(int i_data) {
}
void daB_TN_c::setArmorBreakEffect(int i_idx) {
static u16 blur_effect_id_6035[3] = {0x87DE, 0x87DF, 0x87E0};
static u16 blur_effect_id[3] = {0x87DE, 0x87DF, 0x87E0};
cXyz sp24(l_HIO.mScale, l_HIO.mScale, l_HIO.mScale);
cXyz sp30;
@@ -1582,7 +1582,7 @@ void daB_TN_c::setArmorBreakEffect(int i_idx) {
mDoMtx_stack_c::multVecZero(&sp30);
for (int i = 0; i < 3; i++) {
dComIfGp_particle_set(blur_effect_id_6035[i], &sp30, &tevStr, &shape_angle, &sp24);
dComIfGp_particle_set(blur_effect_id[i], &sp30, &tevStr, &shape_angle, &sp24);
}
}
+38 -38
View File
@@ -51,9 +51,9 @@ char* daKnob20_c::getDummyBmd() {
static char* l_bmd_base_name = "door-knob_";
static char l_bmdName[32];
char* daKnob20_c::getBmd() {
static char l_bmdName[32];
sprintf(l_bmdName, "%s%02d.bmd", l_bmd_base_name, knob_param_c::getDoorModel(this));
return l_bmdName;
}
@@ -192,17 +192,17 @@ void daKnob20_c::setActionFromFlow() {
}
}
static char* ev_name_table[7] = {
"DEFAULT_KNOB_DOOR_F_OPEN",
"DEFAULT_KNOB_DOOR_B_OPEN",
"DEFAULT_KNOB_TALK",
"DEFAULT_KNOB_TALK_B",
"DEFAULT_KNOB_TALK_F_OPEN",
"DEFAULT_KNOB_TALK_B_OPEN",
"DEFAULT_KNOB_TALK",
};
void daKnob20_c::setEventId() {
static char* ev_name_table[7] = {
"DEFAULT_KNOB_DOOR_F_OPEN",
"DEFAULT_KNOB_DOOR_B_OPEN",
"DEFAULT_KNOB_TALK",
"DEFAULT_KNOB_TALK_B",
"DEFAULT_KNOB_TALK_F_OPEN",
"DEFAULT_KNOB_TALK_B_OPEN",
"DEFAULT_KNOB_TALK",
};
for (int i = 0; i < 7; i++) {
field_0x5b2[i] = 0xff;
field_0x5a4[i] =
@@ -294,26 +294,26 @@ int daKnob20_c::frontCheck() {
return 1;
}
static char* action_table[16] = {
"WAIT",
"SETSTART",
"SETANGLE",
"ADJUSTMENT",
"OPEN_PUSH",
"OPEN_PULL",
"OPEN_PUSH2",
"OPEN_PULL2",
"OPEN_PUSH_STOP",
"OPEN_PULL_STOP",
"TALK",
"TALK_END",
"SETSTART_PUSH",
"SETSTART_PULL",
"DEMO_OPEN",
"DEMO_CLOSE",
};
int daKnob20_c::getDemoAction() {
static char* action_table[16] = {
"WAIT",
"SETSTART",
"SETANGLE",
"ADJUSTMENT",
"OPEN_PUSH",
"OPEN_PULL",
"OPEN_PUSH2",
"OPEN_PULL2",
"OPEN_PUSH_STOP",
"OPEN_PULL_STOP",
"TALK",
"TALK_END",
"SETSTART_PUSH",
"SETSTART_PULL",
"DEMO_OPEN",
"DEMO_CLOSE",
};
return dComIfGp_evmng_getMyActIdx(field_0x5bc, action_table, 16, 0, 0);
}
@@ -461,14 +461,14 @@ int daKnob20_c::adjustmentProc() {
return 0;
}
static char* bck_table[4] = {
"FDoorA.bck",
"FDoorB.bck",
"FDoorA.bck",
"FDoorB.bck",
};
int daKnob20_c::openInit(int param_1) {
static char* bck_table[4] = {
"FDoorA.bck",
"FDoorB.bck",
"FDoorA.bck",
"FDoorB.bck",
};
J3DAnmTransform* anm =
(J3DAnmTransform*)dComIfG_getObjectRes(getAlwaysArcName(), bck_table[param_1]);
JUT_ASSERT(937, anm != NULL);
+2 -2
View File
@@ -228,9 +228,9 @@ void daDoorPush_c::actionEvent() {
demoProc();
}
static char* action_table[3] = {"WAIT", "OPEN", "SCENE_CHG"};
int daDoorPush_c::demoProc() {
static char* action_table[3] = {"WAIT", "OPEN", "SCENE_CHG"};
daPy_py_c* player = daPy_getPlayerActorClass();
field_0x644 = dComIfGp_evmng_getMyStaffId("pdoor", NULL, 0);
+12 -12
View File
@@ -1340,11 +1340,11 @@ static void anm_se_set(e_dd_class* i_this) {
if ((i_this->mAnm == BCK_DD_FIRE_A && i_this->mpModelMorf->getFrame() >= 44.0f) || i_this->mAnm == BCK_DD_FIRE_B) {
for (int i = 0; i < 4; i++) {
static u16 fire_eff_name_0[4] = {
static u16 fire_eff_name[4] = {
0x846C, 0x846D, 0x846E, 0x846F,
};
i_this->field_0xe68[i] = dComIfGp_particle_set(i_this->field_0xe68[i], fire_eff_name_0[i], &a_this->current.pos, NULL, NULL);
i_this->field_0xe68[i] = dComIfGp_particle_set(i_this->field_0xe68[i], fire_eff_name[i], &a_this->current.pos, NULL, NULL);
JPABaseEmitter* fire_emitter = dComIfGp_particle_getEmitter(i_this->field_0xe68[i]);
if (fire_emitter != NULL) {
fire_emitter->setGlobalSRTMatrix(i_this->mpModelMorf->getModel()->getAnmMtx(JNT_NECK));
@@ -1362,11 +1362,11 @@ static void anm_se_set(e_dd_class* i_this) {
if (i_this->mAnm == BCK_DD_FIRE_A) {
for (int i = 0; i < 2; i++) {
static u16 fire_eff_name_1[2] = {
static u16 fire_eff_name[2] = {
0x8471, 0x8472,
};
i_this->field_0xe7c[i] = dComIfGp_particle_set(i_this->field_0xe7c[i], fire_eff_name_1[i], &a_this->current.pos, NULL, NULL);
i_this->field_0xe7c[i] = dComIfGp_particle_set(i_this->field_0xe7c[i], fire_eff_name[i], &a_this->current.pos, NULL, NULL);
JPABaseEmitter* emitter_4 = dComIfGp_particle_getEmitter(i_this->field_0xe7c[i]);
if (emitter_4 != NULL) {
emitter_4->setGlobalSRTMatrix(i_this->mpModelMorf->getModel()->getAnmMtx(i + 10));
@@ -1620,15 +1620,15 @@ static int useHeapInit(fopAc_ac_c* a_this) {
return 1;
}
static s16 ya[5] = {
-0x4000, 0x4000, 0x0000, -0x8000, 0x0000,
};
static s16 xa[5] = {
-0x4000, -0x4000, -0x4000, -0x4000, -0x8000,
};
static int kabe_initial_pos_set(e_dd_class* i_this) {
static s16 ya[5] = {
-0x4000, 0x4000, 0x0000, -0x8000, 0x0000,
};
static s16 xa[5] = {
-0x4000, -0x4000, -0x4000, -0x4000, -0x8000,
};
fopAc_ac_c* a_this = &i_this->actor;
dBgS_LinChk lin_chk;
cXyz sp98, start, end;
+2 -1
View File
@@ -43,7 +43,7 @@ enum E_DK_RES_FILE_ID {
/* 0x1B */ BTK_DK_WAIT,
};
namespace {
static dCcD_SrcSph cc_dk_src = {
{ // mObjInf
{ 0x0, { { 0, 0, { 0 } }, { (s32)0xd8fbbddf, { 3 } }, { { 0x75 } } } }, // mObj
@@ -73,6 +73,7 @@ static dCcD_SrcSph cc_dk_core_src = {
},
{ { { 0.0f, 0.0f, 0.0f }, 40.0f, } } // mSphAttr
};
}
daE_DK_HIO_c::daE_DK_HIO_c() {
field_0x4 = -1;
+53 -52
View File
@@ -175,41 +175,42 @@ static int daE_OctBg_Delete(daE_OctBg_c* i_this) {
/* 8073A14C 0024+01 data_8073A14C l_HIO */
/* 8073A171 0001+00 data_8073A171 None */
/* 8073A172 0002+00 data_8073A172 None */
static daE_OctBg_HIO_c struct_8073A14C;
static u8 struct_8073A14C_field_0x23;
static u8 struct_8073A14C_field_0x24;
static u8 struct_8073A14C_field_0x25;
static u8 struct_8073A14C_field_0x26;
static daE_OctBg_HIO_c l_HIO;
u8 unk_bss_78;
u8 unk_bss_79;
u8 unk_bss_7A;
u8 unk_bss_7B;
void daE_OctBg_c::cc_set() {
cXyz cStack_1c;
cXyz cStack_28;
J3DModel* model = field_0x5b4->getModel();
mDoMtx_stack_c::copy(model->getAnmMtx(0));
cStack_1c.set(0.0f, struct_8073A14C.field_0x18 * 25.0f, 0.0f);
cStack_1c.set(0.0f, l_HIO.field_0x18 * 25.0f, 0.0f);
mDoMtx_stack_c::multVec(&cStack_1c, &eyePos);
attention_info.position = eyePos;
attention_info.position.y += struct_8073A14C.field_0x18 * 25.0f;
attention_info.position.y += l_HIO.field_0x18 * 25.0f;
mDoMtx_stack_c::copy(model->getAnmMtx(0));
cStack_1c.set(0.0f, struct_8073A14C.field_0x18 * 25.0f, 0.0f);
cStack_1c.set(0.0f, l_HIO.field_0x18 * 25.0f, 0.0f);
mDoMtx_stack_c::multVec(&cStack_1c, &cStack_28);
field_0x8c0.SetC(cStack_28);
field_0x8c0.SetR(struct_8073A14C.field_0x18 * 35.0f);
field_0x8c0.SetR(l_HIO.field_0x18 * 35.0f);
dComIfG_Ccsp()->Set(&field_0x8c0);
mDoMtx_stack_c::copy(model->getAnmMtx(0));
cStack_1c.set(0.0f, struct_8073A14C.field_0x18 * 25.0f, struct_8073A14C.field_0x18 * 20.0f);
cStack_1c.set(0.0f, l_HIO.field_0x18 * 25.0f, l_HIO.field_0x18 * 20.0f);
mDoMtx_stack_c::multVec(&cStack_1c, &cStack_28);
field_0x9f8.SetC(cStack_28);
field_0x9f8.SetR(struct_8073A14C.field_0x18 * 20.0f);
field_0x9f8.SetR(l_HIO.field_0x18 * 20.0f);
dComIfG_Ccsp()->Set(&field_0x9f8);
}
void daE_OctBg_c::mtx_set() {
mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z);
mDoMtx_stack_c::transM(0.0f, struct_8073A14C.field_0x18 * 25.0f, 0.0f);
mDoMtx_stack_c::transM(0.0f, l_HIO.field_0x18 * 25.0f, 0.0f);
mDoMtx_stack_c::ZXYrotM(shape_angle.x, shape_angle.y, shape_angle.z);
mDoMtx_stack_c::transM(0.0f, struct_8073A14C.field_0x18 * -25.0f, 0.0f);
mDoMtx_stack_c::scaleM(struct_8073A14C.field_0x18, struct_8073A14C.field_0x18, struct_8073A14C.field_0x18);
mDoMtx_stack_c::transM(0.0f, l_HIO.field_0x18 * -25.0f, 0.0f);
mDoMtx_stack_c::scaleM(l_HIO.field_0x18, l_HIO.field_0x18, l_HIO.field_0x18);
J3DModel* model = field_0x5b4->getModel();
model->setBaseTRMtx(mDoMtx_stack_c::get());
for (u16 i = 1; i < model->getModelData()->getJointNum(); i++) {
@@ -226,9 +227,9 @@ bool daE_OctBg_c::checkNormalAttack() {
if (dComIfGp_event_runCheck() != 0) {
return false;
}
if (struct_8073A14C_field_0x25 < struct_8073A14C.field_0x20 &&
home.pos.absXZ(player->current.pos) < struct_8073A14C.field_0x08 &&
player->current.pos.y < struct_8073A14C.field_0x0c &&
if (unk_bss_7A < l_HIO.field_0x20 &&
home.pos.absXZ(player->current.pos) < l_HIO.field_0x08 &&
player->current.pos.y < l_HIO.field_0x0c &&
!fopAcM_otherBgCheck(this, player))
{
s16 targetAngle = cLib_targetAngleY(&current.pos, &player->current.pos);
@@ -242,12 +243,12 @@ bool daE_OctBg_c::checkNormalAttack() {
bool daE_OctBg_c::checkChase() {
if (field_0xbac == 0) {
return false;
}
}
fopAc_ac_c* actor;
if (fopAcM_SearchByID(fopAcM_GetLinkId(this), &actor) == 0 || actor == NULL) {
field_0xbac = 0;
struct_8073A14C_field_0x24--;
unk_bss_79--;
return false;
}
return true;
@@ -290,7 +291,7 @@ void daE_OctBg_c::swim() {
if (field_0xb70 == 0) {
field_0xb8c = 0;
field_0xb82 = 0xc00;
if (current.pos.absXZ(home.pos) < (struct_8073A14C.field_0x08 - 100.0f)) {
if (current.pos.absXZ(home.pos) < (l_HIO.field_0x08 - 100.0f)) {
field_0xb96 = current.angle.y - 0x8000 + cM_rndFX(16384.0f);
} else {
field_0xb96 = cLib_targetAngleY(&current.pos, &home.pos) + cM_rndFX(8192.0f);
@@ -307,7 +308,7 @@ void daE_OctBg_c::swim() {
if (checkNormalAttack()) {
setAction(&daE_OctBg_c::normal_attack);
} else {
if (field_0x660.y > (home.pos.y + struct_8073A14C.field_0x0c) - 100.0f) {
if (field_0x660.y > (home.pos.y + l_HIO.field_0x0c) - 100.0f) {
field_0x660.y = current.pos.y - cM_rndF(2000.0f);
}
cXyz cStack_58(current.pos);
@@ -325,14 +326,14 @@ void daE_OctBg_c::swim() {
field_0xb8c = field_0xb96 - current.angle.y;
cLib_addCalcAngleS(&field_0xb80, 0x1000, 0x20, 0x400, 0x80);
field_0xb7c += field_0xb80;
if (struct_8073A14C_field_0x26 != 0 &&
struct_8073A14C_field_0x24 < struct_8073A14C_field_0x23 >> 1)
if (unk_bss_7B != 0 &&
unk_bss_79 < unk_bss_78 >> 1)
{
field_0xbac = 1;
struct_8073A14C_field_0x24++;
unk_bss_79++;
setAction(&daE_OctBg_c::chase_core);
if (struct_8073A14C_field_0x24 >= struct_8073A14C_field_0x23 >> 1) {
struct_8073A14C_field_0x26 = 0;
if (unk_bss_79 >= unk_bss_78 >> 1) {
unk_bss_7B = 0;
}
} else if (field_0xbac != 0 && !dComIfGp_event_runCheck()) {
setAction(&daE_OctBg_c::chase_core);
@@ -354,16 +355,16 @@ bool daE_OctBg_c::checkCoreFishAttack() {
fopAc_ac_c* actor;
if (fopAcM_SearchByID(fopAcM_GetLinkId(this), &actor) == 0 || actor == NULL) {
return false;
}
}
if (fopAcM_CheckStatus(actor, 0x100000) == 0) {
return false;
}
}
return true;
}
void daE_OctBg_c::chase_core() {
if (field_0xb70 == 0) {
setChasePos(field_0x660, cM_rndF(struct_8073A14C.field_0x10));
setChasePos(field_0x660, cM_rndF(l_HIO.field_0x10));
field_0xbaf = cM_rndFX(20.0f) + 100.0f;
field_0xb70++;
} else if (field_0xb70 != -1) {
@@ -372,9 +373,9 @@ void daE_OctBg_c::chase_core() {
if (fopAcM_SearchByID(fopAcM_GetLinkId(this), &local_6c) == 0 || local_6c == NULL) {
setAction(&daE_OctBg_c::swim);
} else {
if (local_6c->current.pos.y < home.pos.y + struct_8073A14C.field_0x14) {
if (local_6c->current.pos.y < home.pos.y + l_HIO.field_0x14) {
acStack_2c = local_6c->current.pos + field_0x660;
acStack_2c.y = (home.pos.y + struct_8073A14C.field_0x14) + cM_rndF(200.0f);
acStack_2c.y = (home.pos.y + l_HIO.field_0x14) + cM_rndF(200.0f);
} else {
acStack_2c = local_6c->current.pos + field_0x660;
}
@@ -383,7 +384,7 @@ void daE_OctBg_c::chase_core() {
if (abs(current.angle.y - field_0xb96) > 0x4000) {
cLib_chaseAngleS(&current.angle.y, field_0xb96, 0x400);
cLib_chaseAngleS(&current.angle.x, -cLib_targetAngleX(&current.pos, &acStack_2c), 0x400);
if (current.pos.abs(acStack_2c) < struct_8073A14C.field_0x10 - 100.0f) {
if (current.pos.abs(acStack_2c) < l_HIO.field_0x10 - 100.0f) {
cLib_chaseF(&speedF, cM_scos(current.angle.x) * 8.0f, 0.2f);
cLib_chaseF(&speed.y, cM_ssin(current.angle.x) * -8.0f, 0.2f);
cLib_addCalcAngleS(&field_0xb80, 0xc00, 0x20, 0x400, 0x80);
@@ -393,7 +394,7 @@ void daE_OctBg_c::chase_core() {
cLib_chaseAngleS(&current.angle.x, -cLib_targetAngleX(&current.pos, &acStack_2c),
0x200);
;
if (current.pos.abs(acStack_2c) > struct_8073A14C.field_0x10 - 100.0f) {
if (current.pos.abs(acStack_2c) > l_HIO.field_0x10 - 100.0f) {
cLib_chaseF(&speedF, 18.0f * cM_scos(current.angle.x), 0.4f);
cLib_chaseF(&speed.y, (-18.0f * cM_ssin(current.angle.x)), 0.4f);
cLib_addCalcAngleS(&field_0xb80, 0x2400, 0x20, 0x400, 0x80);
@@ -405,7 +406,7 @@ void daE_OctBg_c::chase_core() {
} else if (dComIfGp_event_runCheck()) {
setAction(&daE_OctBg_c::swim);
} else if (field_0xbaf == 0) {
setChasePos(field_0x660, cM_rndF(struct_8073A14C.field_0x10));
setChasePos(field_0x660, cM_rndF(l_HIO.field_0x10));
field_0xbaf = cM_rndFX(20.0f) + 100.0f;
}
}
@@ -416,12 +417,12 @@ void daE_OctBg_c::normal_attack() {
daPy_py_c* player = daPy_getPlayerActorClass();
if (field_0xb70 == 0) {
field_0xb74 = true;
struct_8073A14C_field_0x25++;
unk_bss_7A++;
field_0xbae = cM_rndFX(20.0f) + 60.0f;
field_0xb70++;
} else if (field_0xb70 == -1) {
field_0xb74 = false;
struct_8073A14C_field_0x25--;
unk_bss_7A--;
} else if (field_0xb70 == 1) {
cXyz acStack_34;
acStack_34 = player->current.pos;
@@ -462,7 +463,7 @@ void daE_OctBg_c::normal_attack() {
field_0xb8c = fopAcM_searchPlayerAngleY(this) - current.angle.y;
cLib_addCalcAngleS(&field_0xb80, 0x2400, 0x20, 0x400, 0x80);
field_0xb7c = field_0xb7c + field_0xb80;
if (home.pos.absXZ(player->current.pos) >= struct_8073A14C.field_0x08 && player->current.pos.y >= struct_8073A14C.field_0x0c) {
if (home.pos.absXZ(player->current.pos) >= l_HIO.field_0x08 && player->current.pos.y >= l_HIO.field_0x0c) {
setAction(&daE_OctBg_c::swim);
} else {
if (dComIfGp_event_runCheck() || field_0xbae == 0) {
@@ -781,10 +782,10 @@ int daE_OctBg_c::CreateHeap() {
field_0x5b8 = new mDoExt_brkAnm();
if (field_0x5b8 == NULL) {
return 0;
}
}
if (!field_0x5b8->init(model->getModelData(), (J3DAnmTevRegKey*)dComIfG_getObjectRes("E_bg", 13), 1, 0, 1.0f, 0, -1)) {
return 0;
}
}
return 1;
}
@@ -796,12 +797,12 @@ int daE_OctBg_c::create() {
OS_REPORT("///////////// E_OctBg ////////////////\n");
if (fopAcM_entrySolidHeap(this, useHeapInit, 0x10e0) == 0) {
return cPhs_ERROR_e;
}
}
OS_REPORT("//////////// E_OctBg SET OK //////////\n");
if (struct_8073A13D == 0) {
struct_8073A13D = 1;
field_0xbb3 = 1;
struct_8073A14C.field_0x04 = -1;
l_HIO.field_0x04 = -1;
}
attention_info.flags = fopAc_AttnFlag_BATTLE_e;
onWolfNoLock();
@@ -810,8 +811,8 @@ int daE_OctBg_c::create() {
fopAcM_SetMax(this, 50.0f, 50.0f, 50.0f);
field_0x6ac.Set(fopAcM_GetPosition_p(this), fopAcM_GetOldPosition_p(this), this, 1,
&field_0x66c, fopAcM_GetSpeed_p(this), NULL, NULL);
field_0x66c.SetWall(struct_8073A14C.field_0x18 * 10.0f,
struct_8073A14C.field_0x18 * 20.0f);
field_0x66c.SetWall(l_HIO.field_0x18 * 10.0f,
l_HIO.field_0x18 * 20.0f);
health = 10;
field_0x560 = 10;
field_0x884.Init(100, 0, this);
@@ -827,13 +828,13 @@ int daE_OctBg_c::create() {
attention_info.distances[fopAc_attn_BATTLE_e] = 4;
field_0xb74 = false;
field_0xbac = fopAcM_GetID(this) & 1;
struct_8073A14C_field_0x23++;
unk_bss_78++;
if (field_0xbac != 0) {
struct_8073A14C_field_0x24++;
unk_bss_79++;
}
setAction(&daE_OctBg_c::born_swim);
daE_OctBg_Execute(this);
}
return rv;
}
@@ -868,15 +869,15 @@ static int daE_OctBg_Draw(daE_OctBg_c* i_this) {
}
static int daE_OctBg_IsDelete(daE_OctBg_c* i_this) {
struct_8073A14C_field_0x23--;
unk_bss_78--;
if (i_this->getChaseFlag() != 0) {
struct_8073A14C_field_0x24--;
if (struct_8073A14C_field_0x24 < struct_8073A14C_field_0x23 >> 2) {
struct_8073A14C_field_0x26 = 1;
unk_bss_79--;
if (unk_bss_79 < unk_bss_78 >> 2) {
unk_bss_7B = 1;
}
}
}
if (i_this->checkNormalAttk()) {
struct_8073A14C_field_0x25--;
unk_bss_7A--;
}
return 1;
}
+4 -4
View File
@@ -104,7 +104,7 @@ static int daE_SG_Draw(e_sg_class* i_this) {
return 1;
}
static bool hio_init;
static bool hio_set;
static daE_SG_HIO_c l_HIO;
@@ -1105,7 +1105,7 @@ static int daE_SG_Delete(e_sg_class* i_this) {
dComIfG_resDelete(&i_this->mPhaseReq, "E_sg");
if (i_this->mHioInit) {
hio_init = false;
hio_set = false;
}
if (i_this->heap != NULL) {
@@ -1170,9 +1170,9 @@ static int daE_SG_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (hio_init == false) {
if (hio_set == false) {
a_this->mHioInit = true;
hio_init = true;
hio_set = true;
l_HIO.mUnk0 = -1;
}
+12 -12
View File
@@ -673,19 +673,19 @@ static int useHeapInit(fopAc_ac_c* a_this) {
return 1;
}
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0xd}, {0xd8fbfdff, 0x3}, 0x75}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
static int daE_TK_Create(fopAc_ac_c* i_this) {
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0xd}, {0xd8fbfdff, 0x3}, 0x75}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
fopAcM_ct(i_this, e_tk_class);
e_tk_class* const a_this = static_cast<e_tk_class*>(i_this);
+12 -12
View File
@@ -486,19 +486,19 @@ static int useHeapInit(fopAc_ac_c* a_this) {
return 1;
}
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0xd}, {0xd8fbfdff, 0x3}, 0x75}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
static int daE_TK2_Create(fopAc_ac_c* i_this) {
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0xd}, {0xd8fbfdff, 0x3}, 0x75}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
fopAcM_ct(i_this, e_tk2_class);
e_tk2_class* a_this = static_cast<e_tk2_class*>(i_this);
+1 -1
View File
@@ -227,7 +227,7 @@ static void e_tk_ball_drop(e_tk_ball_class* i_this) {
static void action(e_tk_ball_class* i_this) {
fopAc_ac_c* actor = i_this;
static u16 e_id[4] = {0x819D, 0x819E, 0x819A, 0x0000};
static u16 e_id[3] = {0x819D, 0x819E, 0x819A};
s8 is_moving = true;
switch (i_this->mAction) {
+4 -4
View File
@@ -189,7 +189,7 @@ static void damage_check(e_yd_class* i_this) {
}
}
static u8 data_807F7D68;
static u8 hio_set;
static daE_YD_HIO_c l_HIO;
@@ -1300,7 +1300,7 @@ static int daE_YD_IsDelete(e_yd_class* i_this) {
static int daE_YD_Delete(e_yd_class* i_this) {
dComIfG_resDelete(&i_this->field_0x5ac, "E_yd");
if (i_this->field_0x1268 != 0) {
data_807F7D68 = 0;
hio_set = 0;
}
if (i_this->actor.heap != NULL) {
i_this->mpMorf->stopZelAnime();
@@ -1423,9 +1423,9 @@ static int daE_YD_Create(fopAc_ac_c* i_this) {
OS_REPORT("//////////////E_YD SET 2 !!\n");
if (data_807F7D68 == 0) {
if (hio_set == 0) {
((e_yd_class*)i_this)->field_0x1268 = 1;
data_807F7D68 = 1;
hio_set = 1;
l_HIO.field_0x4 = -1;
}
+6 -6
View File
@@ -53,7 +53,7 @@ daE_YK_HIO_c::daE_YK_HIO_c() {
mChargeSpeed = 40.0f;
}
static u8 data_80807EF8;
static u8 hio_set;
static daE_YK_HIO_c l_HIO;
@@ -327,8 +327,6 @@ static void damage_check(e_yk_class* i_this) {
}
}
static u8 check_index[255];
/**
* @brief Checks visibility and accessibility of path points for Shadow Keese navigation
*
@@ -349,6 +347,8 @@ static u8 check_index[255];
* and maintain valid flight paths.
*/
static int path_check(e_yk_class* i_this) {
static u8 check_index[255];
if (i_this->mpPath) {
dBgS_LinChk lin_chk;
@@ -1388,7 +1388,7 @@ static int daE_YK_Delete(e_yk_class* i_this) {
dComIfG_resDelete(&i_this->mPhase,"E_YK");
if (i_this->mIsFirstSpawn != 0) {
data_80807EF8 = 0;
hio_set = 0;
}
if (i_this->heap) {
@@ -1499,9 +1499,9 @@ static int daE_YK_Create(fopAc_ac_c* i_this) {
}
}
if (data_80807EF8 == 0) {
if (hio_set == 0) {
yk->mIsFirstSpawn = 1;
data_80807EF8 = 1;
hio_set = 1;
l_HIO.field_0x04 = -1;
}
+15 -15
View File
@@ -33,22 +33,22 @@ static int daHitobj_Delete(hitobj_class* i_this) {
return 1;
}
static dCcD_SrcSph cc_sph_src = {
{
{0, {{0, 0, 0x13}, {0, 3}, 0}},
{dCcD_SE_NONE, 0, 0, 0, {0}},
{dCcD_SE_NONE, 0, 0, 0, {0}},
{0},
},
{
{
{0.0f, 0.0f, 0.0f},
100.0f,
},
}
};
static int daHitobj_Create(fopAc_ac_c* i_this) {
static dCcD_SrcSph cc_sph_src = {
{
{0, {{0, 0, 0x13}, {0, 3}, 0}},
{dCcD_SE_NONE, 0, 0, 0, {0}},
{dCcD_SE_NONE, 0, 0, 0, {0}},
{0},
},
{
{
{0.0f, 0.0f, 0.0f},
100.0f,
},
}
};
hitobj_class* hitobj = (hitobj_class*)i_this;
fopAcM_ct(i_this, hitobj_class);
-2
View File
@@ -40,10 +40,8 @@ const daHoZelda_hio_c1 daHoZelda_hio_c0::m = {
4000.0f,
};
#if VERSION != VERSION_GCN_PAL
u8 daHoZelda_matAnm_c::mEyeMoveFlg;
u8 daHoZelda_matAnm_c::mMorfFrame;
#endif
void daHoZelda_matAnm_c::init() {
field_0xf4 = 0.0f;
-2
View File
@@ -125,10 +125,8 @@ daMidna_hio_c1 const daMidna_hio_c0::m = {
25.0f,
};
#if VERSION != VERSION_GCN_PAL
bool daMidna_matAnm_c::sEyeMoveFlg;
u8 daMidna_matAnm_c::sMorfFrame;
#endif
void daMidna_matAnm_c::init() {
mOldTransX = 0.0f;
-2
View File
@@ -504,8 +504,6 @@ static BOOL message(npc_du_class* i_this) {
static bool hio_set;
static u8 lit_3757[12];
static daNpc_Du_HIO_c l_HIO;
static int daNpc_Du_Execute(npc_du_class* i_this) {
+10 -10
View File
@@ -11,12 +11,6 @@
#include "d/actor/d_a_npc_lf.h"
#include "f_op/f_op_camera_mng.h"
static f32 wp[3] = {
0.5f,
1.0f,
2.5f
};
daNPC_LF_HIO_c::daNPC_LF_HIO_c() {
field_0x04 = -1;
field_0x08 = 1.0f;
@@ -70,7 +64,7 @@ static int daNPC_LF_Draw(npc_lf_class* i_this) {
return 1;
}
static u8 data_80A6AA90;
static u8 hio_set;
static daNPC_LF_HIO_c l_HIO;
@@ -155,6 +149,12 @@ static void npc_lf_move(fopAc_ac_c* param_0, lf_s* pFish) {
}
static void action(fopAc_ac_c* param_0, lf_s* pFish) {
static f32 wp[3] = {
0.5f,
1.0f,
2.5f
};
cXyz pos;
pFish->field_0x18++;
@@ -231,7 +231,7 @@ static int daNPC_LF_Delete(npc_lf_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "NPC_LF");
if (i_this->field_0x1fc0 != 0) {
data_80A6AA90 = 0;
hio_set = 0;
}
return 1;
@@ -293,9 +293,9 @@ static cPhs__Step daNPC_LF_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (data_80A6AA90 == 0) {
if (hio_set == 0) {
a_this->field_0x1fc0 = 1;
data_80A6AA90 = 1;
hio_set = 1;
l_HIO.field_0x04 = -1;
}
+4 -4
View File
@@ -247,7 +247,7 @@ static s16 m_near_angle;
static fopAc_ac_c* m_near_actor;
static u8 g_isHioChildInitted;
static u8 hio_set;
static daNPC_TK_HIO_c l_HIO;
@@ -3089,7 +3089,7 @@ static int daNPC_TK_IsDelete(daNPC_TK_c* i_this) {
int daNPC_TK_c::_delete() {
dComIfG_resDelete(&mPhase, "Npc_tk");
if (field_0xb40) {
g_isHioChildInitted = 0;
hio_set = 0;
}
if (heap != NULL) {
@@ -3218,9 +3218,9 @@ int daNPC_TK_c::create() {
return cPhs_ERROR_e;
}
if (g_isHioChildInitted == 0) {
if (hio_set == 0) {
field_0xb40 = 1;
g_isHioChildInitted = 1;
hio_set = 1;
l_HIO.field_0x4 = mDoHIO_CREATE_CHILD("", &l_HIO); // hawk
}
+4 -4
View File
@@ -55,7 +55,7 @@ static f32 dummyLiterals() {
return dummy;
}
static u8 data_80B26678;
static u8 hio_set;
static daNPC_TR_HIO_c l_HIO;
@@ -194,7 +194,7 @@ static int daNPC_TR_Delete(npc_tr_class* npc_tr) {
dComIfG_resDelete(&npc_tr->mPhaseReq, "NPC_TR");
if (npc_tr->field_0x600) {
data_80B26678 = 0;
hio_set = 0;
}
return 1;
@@ -231,9 +231,9 @@ static int daNPC_TR_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (!data_80B26678) {
if (!hio_set) {
npc_tr->field_0x600 = 1;
data_80B26678 = 1;
hio_set = 1;
l_HIO.field_0x4 = -1;
}
+7 -8
View File
@@ -142,19 +142,18 @@ static dCcD_SrcCyl l_cc_cyl_src = {
} // mCyl
};
static u16 l_offsetAngle[4] = {
0x0, 0xC000, 0x8000, 0x4000,
};
void daObjYtaihou_c::setNextAngle() {
static u16 l_offsetAngle[4] = {
0x0, 0xC000, 0x8000, 0x4000,
};
current.angle.z = home.angle.y + l_offsetAngle[field_0x775];
}
static f32 l_wheelMinR;
static u8 lbl_396_bss_4C;
void daObjYtaihou_c::setMtx() {
static f32 l_wheelMinR;
static u8 lbl_396_bss_4C;
home.angle.z += (s16) ((s16)(shape_angle.y - old.angle.y) * 0.8f);
if ((s8)lbl_396_bss_4C == 0) {
l_wheelMinR = cM_scos(0xccc) * 60.0f;
-2
View File
@@ -12,8 +12,6 @@
static daBarDesk_HIO_c l_HIO;
static u8 data_80BA9D2C[4];
dCcD_SrcGObjInf const daBarDesk_c::mCcDObjInfo = {
{0, {{0, 0, 0}, {0xD8FAFDBF, 0x11}, {0}}},
{1, 0, 0, 0, 0},
+10 -10
View File
@@ -37,16 +37,6 @@ static dCcD_SrcCyl l_ccDCyl = {
static char* l_resName = "H_BouMato";
static Vec jntCoOffset[2] = {
{0.0f, 0.0f, 0.0f},
{0.0f, 300.0f, 0.0f},
};
// /* 80BBC58C-80BBC598 -00001 000C+00 1/1 0/0 0/0 .data jntCoData$4045 */
static dJntColData_c jntCoData = {
1, 1, 0, 4.0f, jntCoOffset,
};
daObj_BouMato_c::~daObj_BouMato_c() {
OS_REPORT("|%06d:%x|daObj_BouMato_c -> デストラクト\n", g_Counter.mCounter0, this);
dComIfG_resDelete(&mPhase, getResName());
@@ -89,6 +79,16 @@ int daObj_BouMato_c::create() {
}
int daObj_BouMato_c::CreateHeap() {
static Vec jntCoOffset[2] = {
{0.0f, 0.0f, 0.0f},
{0.0f, 300.0f, 0.0f},
};
// /* 80BBC58C-80BBC598 -00001 000C+00 1/1 0/0 0/0 .data jntCoData$4045 */
static dJntColData_c jntCoData = {
1, 1, 0, 4.0f, jntCoOffset,
};
J3DModelData* mdlData_p = (J3DModelData*)dComIfG_getObjectRes(getResName(), 4);
JUT_ASSERT(374, NULL != mdlData_p);
mModel = mDoExt_J3DModel__create(mdlData_p, 0x80000, 0x11000084);
+4 -4
View File
@@ -148,13 +148,13 @@ static int daObj_Cb_IsDelete(obj_cb_class* param_0) {
return 1;
}
static u8 data_80BC58F8;
static u8 hio_set;
static int daObj_Cb_Delete(obj_cb_class* i_this) {
fopAcM_GetID(i_this);
dComIfG_resDelete(&i_this->mPhase, "Obj_cb");
if (i_this->field_0x978 != 0) {
data_80BC58F8 = 0;
hio_set = 0;
}
if (i_this->mBgW != NULL) {
dComIfG_Bgsp().Release(i_this->mBgW);
@@ -211,9 +211,9 @@ static int daObj_Cb_Create(fopAc_ac_c* actor) {
return cPhs_ERROR_e;
}
}
if (data_80BC58F8 == 0) {
if (hio_set == 0) {
i_this->field_0x978 = 1;
data_80BC58F8 = 1;
hio_set = 1;
l_HIO.field_0x4 = -1;
}
fopAcM_SetMtx(i_this, i_this->mModel->getBaseTRMtx());
-4
View File
@@ -44,10 +44,6 @@ static cXyz l_chainOffset(0.0f, 105.0f, 30.0f);
static cXyz l_smokeSetOffset(0.0f, 0.0f, -200.0f);
#if !DEBUG
static s32 unused_bss_70 = 0;
#endif
static cull_box const l_cull_box = {
{-250.0f, 0.0f, -450.0f},
{250.0f, 250.0f, 400.0f},
+7 -7
View File
@@ -36,13 +36,6 @@ static dCcD_SrcSph l_sphSrc = {
} // mSphAttr
};
static GXColor color = {
0x00,
0x00,
0x00,
0xFF,
};
int daObjCrope_c::create() {
fopAcM_ct(this, daObjCrope_c);
int rv = dComIfG_resLoad(&mPhase, l_arcName);
@@ -360,6 +353,13 @@ static int daObjCrope_Execute(daObjCrope_c* i_this) {
}
int daObjCrope_c::draw() {
static GXColor color = {
0x00,
0x00,
0x00,
0xFF,
};
g_env_light.settingTevStruct(0, &current.pos, &tevStr);
mLineMat.update(100, 5.0f, color, 0, &tevStr);
dComIfGd_set3DlineMat(&mLineMat);
+5 -5
View File
@@ -22,7 +22,7 @@ static void rideCallBack(dBgW* param_0, fopAc_ac_c* param_1, fopAc_ac_c* param_2
daPy_py_c* pdVar1 = daPy_getPlayerActorClass();
if (fopAcM_CheckStatus(param_2, 0x400) != 0 && fopAcM_GetName(param_2) == 0xfd) {
static cXyz l_push_check_pos0[4] = {
static cXyz l_push_check_pos[4] = {
cXyz(-50.0f, 0.0f, -50.0f),
cXyz(50.0f, 0.0f, -50.0f),
cXyz(50.0f, 0.0f, 50.0f),
@@ -33,10 +33,10 @@ static void rideCallBack(dBgW* param_0, fopAc_ac_c* param_1, fopAc_ac_c* param_2
mDoMtx_stack_c::YrotS(-param_1->current.angle.y);
mDoMtx_stack_c::multVec(&local_2c, &local_2c);
if (l_push_check_pos0[0].x <= local_2c.x) {
if (l_push_check_pos0[2].x >= local_2c.x) {
if (l_push_check_pos0[0].z <= local_2c.z) {
if (l_push_check_pos0[2].z >= local_2c.z) {
if (l_push_check_pos[0].x <= local_2c.x) {
if (l_push_check_pos[2].x >= local_2c.x) {
if (l_push_check_pos[0].z <= local_2c.z) {
if (l_push_check_pos[2].z >= local_2c.z) {
if ((pdVar1->checkEquipHeavyBoots())) {
pthis->field_0x632 = 1;
pthis->field_0x634 = 1;
+14 -14
View File
@@ -255,21 +255,21 @@ void daObjFan_c::action() {
}
}
static Vec l_offset_posM[4] = {
{-150.0f, 150.0f, 0.0f},
{-150.0f, -150.0f, 0.0f},
{150.0f, 150.0f, 0.0f},
{150.0f, -150.0f, 0.0f},
};
static Vec l_offset_posL[4] = {
{-300.0f, 300.0f, 0.0f},
{-300.0f, -300.0f, 0.0f},
{300.0f, 300.0f, 0.0f},
{300.0f, -300.0f, 0.0f},
};
void daObjFan_c::setCollision() {
static Vec l_offset_posM[4] = {
{-150.0f, 150.0f, 0.0f},
{-150.0f, -150.0f, 0.0f},
{150.0f, 150.0f, 0.0f},
{150.0f, -150.0f, 0.0f},
};
static Vec l_offset_posL[4] = {
{-300.0f, 300.0f, 0.0f},
{-300.0f, -300.0f, 0.0f},
{300.0f, 300.0f, 0.0f},
{300.0f, -300.0f, 0.0f},
};
if (field_0xad4 == 0) {
return;
}
+43 -38
View File
@@ -13,6 +13,8 @@
#include "d/d_bg_w.h"
#include "f_op/f_op_actor_mng.h"
namespace daObjLadder {
namespace {
struct Attr {
/* 0x00 */ f32 field_0x00;
/* 0x04 */ f32 field_0x04;
@@ -40,7 +42,7 @@ inline static const Attr& attr() {
return L_attr;
}
char const daObjLadder::Act_c::M_arcname[5] = "Mhsg";
char const Act_c::M_arcname[5] = "Mhsg";
struct AttrType {
/* 0x0 */ s16 field_0x0;
@@ -57,18 +59,18 @@ static AttrType L_attr_type[6] = {
{ 0x06, 0x0E, 300.0f},
};
static inline const AttrType& attr_type(daObjLadder::Act_c::Type_e type) {
static inline const AttrType& attr_type(Act_c::Type_e type) {
return L_attr_type[type];
}
int daObjLadder::Act_c::CreateHeap() {
int Act_c::CreateHeap() {
J3DModelData* model_data = (J3DModelData*)dComIfG_getObjectRes(M_arcname, attr_type(mType).field_0x0);
JUT_ASSERT(382, model_data != NULL);
mModel = mDoExt_J3DModel__create(model_data, 0x80000, 0x11000084);
return mModel != NULL;
}
int daObjLadder::Act_c::Create() {
int Act_c::Create() {
fopAcM_SetMtx(this, mModel->getBaseTRMtx());
init_mtx();
fopAcM_setCullSizeBox(this, -55.0f, -1.0f, -10.0f, 55.0f, attr_type(mType).field_0x4 + 41.0f,
@@ -96,7 +98,7 @@ int daObjLadder::Act_c::Create() {
return 1;
}
int daObjLadder::Act_c::Mthd_Create() {
int Act_c::Mthd_Create() {
fopAcM_ct(this, Act_c);
int phase_state = dComIfG_resLoad(&mPhase, M_arcname);
if (phase_state == cPhs_COMPLEATE_e) {
@@ -108,39 +110,39 @@ int daObjLadder::Act_c::Mthd_Create() {
return phase_state;
}
int daObjLadder::Act_c::Delete() {
int Act_c::Delete() {
return 1;
}
int daObjLadder::Act_c::Mthd_Delete() {
int Act_c::Mthd_Delete() {
int rv = MoveBGDelete();
dComIfG_resDelete(&mPhase, M_arcname);
return rv;
}
void daObjLadder::Act_c::demo_end_reset() {
void Act_c::demo_end_reset() {
if (mInDemo && dComIfGp_evmng_endCheck(mEventIdx)) {
dComIfGp_event_reset();
mInDemo = false;
}
}
void daObjLadder::Act_c::mode_wait_init() {
void Act_c::mode_wait_init() {
mMode = MODE_WAIT;
}
void daObjLadder::Act_c::mode_wait() {
void Act_c::mode_wait() {
if (fopAcM_isSwitch(this, prm_get_swSave())) {
mode_demoreq_init();
}
}
void daObjLadder::Act_c::mode_demoreq_init() {
void Act_c::mode_demoreq_init() {
mMode = MODE_DEMOREQ;
mInDemo = false;
}
void daObjLadder::Act_c::mode_demoreq() {
void Act_c::mode_demoreq() {
bool isDemo = false;
if (dComIfGp_evmng_existence(mEventIdx)) {
if (eventInfo.checkCommandDemoAccrpt()) {
@@ -158,14 +160,14 @@ void daObjLadder::Act_c::mode_demoreq() {
}
}
void daObjLadder::Act_c::mode_vib_init() {
void Act_c::mode_vib_init() {
mVibrationTimer = attr().vibrationTimer;
field_0x610 = 0;
field_0x612 = 0;
mMode = MODE_VIB;
}
void daObjLadder::Act_c::mode_vib() {
void Act_c::mode_vib() {
field_0x610 += attr().field_0x16;
field_0x612 += attr().field_0x18;
field_0x614 = cM_scos(field_0x610) * attr().field_0x1c;
@@ -175,14 +177,14 @@ void daObjLadder::Act_c::mode_vib() {
}
}
void daObjLadder::Act_c::mode_drop_init() {
void Act_c::mode_drop_init() {
gravity = -5.0f;
speed.set(cXyz::Zero);
field_0x5b6 = attr().field_0x10;
mMode = MODE_DROP;
}
void daObjLadder::Act_c::mode_drop() {
void Act_c::mode_drop() {
daObj::posMoveF_stream(this, NULL, &cXyz::Zero, attr().field_0x04, attr().field_0x08);
if (current.pos.y < mHeight) {
if (field_0x5b6 == attr().field_0x10) {
@@ -214,16 +216,16 @@ void daObjLadder::Act_c::mode_drop() {
}
}
void daObjLadder::Act_c::mode_fell_init() {
void Act_c::mode_fell_init() {
mMode = MODE_FELL;
}
void daObjLadder::Act_c::mode_fell() {
void Act_c::mode_fell() {
}
Mtx daObjLadder::Act_c::M_tmp_mtx;
Mtx Act_c::M_tmp_mtx;
void daObjLadder::Act_c::set_mtx() {
void Act_c::set_mtx() {
mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z);
mDoMtx_stack_c::ZXYrotM(shape_angle.x, shape_angle.y, shape_angle.z);
cMtx_copy(mDoMtx_stack_c::get(), M_tmp_mtx);
@@ -231,16 +233,16 @@ void daObjLadder::Act_c::set_mtx() {
mModel->setBaseTRMtx(mDoMtx_stack_c::get());
}
void daObjLadder::Act_c::init_mtx() {
void Act_c::init_mtx() {
mModel->setBaseScale(scale);
set_mtx();
}
int daObjLadder::Act_c::Execute(f32 (**param_1)[3][4]) {
static const daObjLadder::Act_c::modeProc mode_proc[5] = {
&daObjLadder::Act_c::mode_wait, &daObjLadder::Act_c::mode_demoreq,
&daObjLadder::Act_c::mode_vib, &daObjLadder::Act_c::mode_drop,
&daObjLadder::Act_c::mode_fell,
int Act_c::Execute(f32 (**param_1)[3][4]) {
static const Act_c::modeProc mode_proc[5] = {
&Act_c::mode_wait, &Act_c::mode_demoreq,
&Act_c::mode_vib, &Act_c::mode_drop,
&Act_c::mode_fell,
};
demo_end_reset();
@@ -251,7 +253,7 @@ int daObjLadder::Act_c::Execute(f32 (**param_1)[3][4]) {
return 1;
}
int daObjLadder::Act_c::Draw() {
int Act_c::Draw() {
g_env_light.settingTevStruct(0x10, &current.pos, &tevStr);
g_env_light.setLightTevColorType_MAJI(mModel, &tevStr);
dComIfGd_setListBG();
@@ -261,24 +263,24 @@ int daObjLadder::Act_c::Draw() {
return 1;
}
static int Mthd_Create(daObjLadder::Act_c* i_this) {
return i_this->Mthd_Create();
static int Mthd_Create(void* i_this) {
return ((Act_c*)i_this)->Mthd_Create();
}
static int Mthd_Delete(daObjLadder::Act_c* i_this) {
return i_this->Mthd_Delete();
static int Mthd_Delete(void* i_this) {
return ((Act_c*)i_this)->Mthd_Delete();
}
static int Mthd_Execute(daObjLadder::Act_c* i_this) {
return i_this->MoveBGExecute();
static int Mthd_Execute(void* i_this) {
return ((Act_c*)i_this)->MoveBGExecute();
}
static int Mthd_Draw(daObjLadder::Act_c* i_this) {
return i_this->MoveBGDraw();
static int Mthd_Draw(void* i_this) {
return ((Act_c*)i_this)->MoveBGDraw();
}
static int Mthd_IsDelete(daObjLadder::Act_c* i_this) {
return i_this->MoveBGIsDelete();
static int Mthd_IsDelete(void* i_this) {
return ((Act_c*)i_this)->MoveBGIsDelete();
}
static actor_method_class Mthd_Table = {
@@ -289,6 +291,9 @@ static actor_method_class Mthd_Table = {
(process_method_func)Mthd_Draw,
};
}
}
extern actor_process_profile_definition g_profile_Obj_Ladder = {
fpcLy_CURRENT_e, // mLayerID
3, // mListID
@@ -300,7 +305,7 @@ extern actor_process_profile_definition g_profile_Obj_Ladder = {
0, // mParameters
&g_fopAc_Method.base, // sub_method
23, // mPriority
&Mthd_Table, // sub_method
&daObjLadder::Mthd_Table, // sub_method
0x00040100, // mStatus
fopAc_ACTOR_e, // mActorType
fopAc_CULLBOX_CUSTOM_e, // cullType
+16 -16
View File
@@ -11,19 +11,7 @@
#include "f_op/f_op_actor_mng.h"
#include "m_Do/m_Do_hostIO.h"
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0x0}, {0xd8fbfdff, 0x3}, 0x0}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
static u8 data_80C540E8;
static u8 hio_set;
static daObj_Lbox_HIO_c l_HIO;
@@ -116,7 +104,7 @@ static int daObj_Lbox_Delete(obj_lbox_class* i_this) {
fopAcM_GetID(i_this);
dComIfG_resDelete(&i_this->mPhaseReq, "Obj_lbox");
if (i_this->field_0xa8c != 0) {
data_80C540E8 = 0;
hio_set = 0;
}
dComIfG_Bgsp().Release(i_this->mpBgW);
return 1;
@@ -147,6 +135,18 @@ static int useHeapInit(fopAc_ac_c* i_this) {
}
static cPhs__Step daObj_Lbox_Create(fopAc_ac_c* i_this) {
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0x0}, {0xd8fbfdff, 0x3}, 0x0}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
obj_lbox_class* a_this = static_cast<obj_lbox_class*>(i_this);
fopAcM_ct(a_this, obj_lbox_class);
cPhs__Step step = (cPhs__Step)dComIfG_resLoad(&a_this->mPhaseReq, "Obj_lbox");
@@ -165,9 +165,9 @@ static cPhs__Step daObj_Lbox_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (data_80C540E8 == 0) {
if (hio_set == 0) {
a_this->field_0xa8c = 1;
data_80C540E8 = 1;
hio_set = 1;
l_HIO.field_0x4 = -1;
}
+4 -4
View File
@@ -28,7 +28,7 @@ static int daObj_Myogan_Draw(obj_myogan_class* i_this) {
return 1;
}
static bool initialized;
static bool hio_set;
static daObj_Myogan_HIO_c l_HIO;
@@ -74,7 +74,7 @@ static int daObj_Myogan_IsDelete(obj_myogan_class* i_this) {
static int daObj_Myogan_Delete(obj_myogan_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "S_YOGAN");
if (i_this->mInitialized) {
initialized = false;
hio_set = false;
}
dComIfG_Bgsp().Release(i_this->mpBgW);
@@ -142,9 +142,9 @@ static int daObj_Myogan_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (!initialized) {
if (!hio_set) {
a_this->mInitialized = 1;
initialized = true;
hio_set = true;
l_HIO.field_0x4 = -1;
}
+4 -4
View File
@@ -573,12 +573,12 @@ int daObjNAN_c::execute() {
return 1;
}
static u8 l_hio_init;
static u8 hio_set;
int daObjNAN_c::_delete() {
dComIfG_resDelete(&mPhase, "I_Nan");
if (field_0x7fd != 0) {
l_hio_init = 0;
hio_set = 0;
}
if (heap != NULL) {
mMorf->stopZelAnime();
@@ -686,8 +686,8 @@ int daObjNAN_c::create() {
return cPhs_ERROR_e;
}
OS_REPORT("/////////////// I_NAN SET OK //////////\n");
if (l_hio_init == 0) {
l_hio_init = 1;
if (hio_set == 0) {
hio_set = 1;
field_0x7fd = 1;
l_HIO.field_0x4 = -1;
}
+14 -14
View File
@@ -28,23 +28,23 @@ static char* l_arcName[1] = {
"Octhashi"
};
static dCcD_SrcCyl ccCylSrc = {
{
{0x0, {{0x0, 0x0, 0xd}, {0x104002, 0x1f}, 0x75}}, // mObj
{dCcD_SE_STONE, 0x2, 0x0, 0x0, 0x1}, // mGObjAt
{dCcD_SE_STONE, 0x2, 0x0, 0x0, 0x1}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{0.0f, 0.0f, 0.0f}, // mCenter
400.0f, // mRadius
0.0f // mHeight
} // mCyl
};
static s8 l_cyl_height_init = 0;
void daObjOCTHASHI_c::initCcCylinder() {
static dCcD_SrcCyl ccCylSrc = {
{
{0x0, {{0x0, 0x0, 0xd}, {0x104002, 0x1f}, 0x75}}, // mObj
{dCcD_SE_STONE, 0x2, 0x0, 0x0, 0x1}, // mGObjAt
{dCcD_SE_STONE, 0x2, 0x0, 0x0, 0x1}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{0.0f, 0.0f, 0.0f}, // mCenter
400.0f, // mRadius
0.0f // mHeight
} // mCyl
};
if (l_cyl_height_init == 0) {
ccCylSrc.mCyl.mHeight = (f32)(mPieceNum + 1) * 800.0f - 100.f;
l_cyl_height_init = 1;
+4 -4
View File
@@ -103,7 +103,7 @@ void daObjRIVERROCK_c::CheckBG() {
field_0x5d0 = particlePos;
}
static bool mHIOInitialized;
static bool hio_set;
static daObjRIVERROCK_HIO_c l_HIO;
@@ -244,8 +244,8 @@ int daObjRIVERROCK_c::create() {
} else {
field_0x5c4.set(1.0f, 1.0f, 1.0f);
}
if (!mHIOInitialized) {
mHIOInitialized = true;
if (!hio_set) {
hio_set = true;
mHIONeedDelete = true;
l_HIO.field_0x4 = -1;
}
@@ -304,7 +304,7 @@ int daObjRIVERROCK_c::Draw() {
int daObjRIVERROCK_c::Delete() {
dComIfG_resDelete(&mPhase, l_arcName);
if (mHIONeedDelete) {
mHIOInitialized = false;
hio_set = false;
}
mSoundObj.deleteObject();
return 1;
+12 -12
View File
@@ -89,19 +89,19 @@ static int set_pos_check(obj_rock_class* i_this, int target_index) {
return TRUE;
}
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0x0}, {0xd8fbfdff, 0x11}, 0x79}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_METAL, 0x2, 0x0, 0x0, 0x3}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
static int daObj_Rock_Create(fopAc_ac_c* i_this) {
static dCcD_SrcSph cc_sph_src = {
{
{0x0, {{0x0, 0x0, 0x0}, {0xd8fbfdff, 0x11}, 0x79}}, // mObj
{dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
{dCcD_SE_METAL, 0x2, 0x0, 0x0, 0x3}, // mGObjTg
{0x0}, // mGObjCo
}, // mObjInf
{
{{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
} // mSphAttr
};
obj_rock_class* a_this = static_cast<obj_rock_class*>(i_this);
fopAcM_ct(a_this, obj_rock_class);
+5 -5
View File
@@ -877,7 +877,7 @@ static void demo_camera(obj_so_class* i_this) {
}
}
static u8 data_80CE3C90;
static u8 hio_set;
static daObj_So_HIO_c l_HIO;
@@ -909,8 +909,8 @@ static int daObj_So_Delete(obj_so_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "Obj_so");
if (i_this->field_0x1bcc != 0) {
data_80CE3C90 = 0;
mDoHIO_DELETE_CHILD(data_80CE3C90);
hio_set = 0;
mDoHIO_DELETE_CHILD(hio_set);
}
for (int i = 0; i < 2; i++) {
@@ -1027,9 +1027,9 @@ static int daObj_So_Create(fopAc_ac_c* a_this) {
}
}
if (data_80CE3C90 == 0) {
if (hio_set == 0) {
i_this->field_0x1bcc = 1;
data_80CE3C90 = 1;
hio_set = 1;
mDoHIO_CREATE_CHILD("猿オリOBJ", &l_HIO); // Monkey jail OBJ
l_HIO.field_0x4 = -1;
}
+4 -4
View File
@@ -615,12 +615,12 @@ void daObjTEN_c::Z_BufferChk() {
field_0x618 = ((near + ((far * near) / local_5c.z)) / (far - near) + 1.0f) * 16777215.0f;
}
static u8 data_80D0BAB8;
static u8 hio_set;
int daObjTEN_c::Delete() {
dComIfG_resDelete(&mPhase, "I_Ten");
if (field_0xa64 != 0) {
data_80D0BAB8 = 0;
hio_set = 0;
}
mCreature.deleteObject();
return 1;
@@ -722,8 +722,8 @@ int daObjTEN_c::create() {
if (fopAcM_entrySolidHeap(this, useHeapInit, 0xbc0) == 0) {
return cPhs_ERROR_e;
}
if (data_80D0BAB8 == 0) {
data_80D0BAB8 = 1;
if (hio_set == 0) {
hio_set = 1;
field_0xa64 = 1;
l_HIO.field_0x4 = -1;
}
+4 -4
View File
@@ -157,13 +157,13 @@ static int daObj_Web0_IsDelete(obj_web0_class* i_this) {
return 1;
}
static u8 data_80D35290;
static u8 hio_set;
static int daObj_Web0_Delete(obj_web0_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "Obj_web0");
if (i_this->field_0x739) {
data_80D35290 = 0;
hio_set = 0;
}
dComIfG_Bgsp().Release(i_this->mpBgW);
@@ -251,9 +251,9 @@ static int daObj_Web0_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (!data_80D35290) {
if (!hio_set) {
_this->field_0x739 = 1;
data_80D35290 = true;
hio_set = true;
l_HIO.field_0x4 = -1;
}
+4 -4
View File
@@ -181,13 +181,13 @@ static int daObj_Web1_IsDelete(obj_web1_class* i_this) {
return 1;
}
static u8 data_80D361F8;
static u8 hio_set;
static int daObj_Web1_Delete(obj_web1_class* i_this) {
dComIfG_resDelete(&i_this->mPhase, "Obj_web1");
if (i_this->field_0x76c) {
data_80D361F8 = 0;
hio_set = 0;
}
dComIfG_Bgsp().Release(i_this->mpBgW);
@@ -279,9 +279,9 @@ static int daObj_Web1_Create(fopAc_ac_c* i_this) {
return cPhs_ERROR_e;
}
if (!data_80D361F8) {
if (!hio_set) {
_this->field_0x76c = 1;
data_80D361F8 = true;
hio_set = true;
l_HIO.field_0x4 = -1;
}
+3 -3
View File
@@ -27,10 +27,10 @@ static int daObj_Wflag_Draw(obj_wflag_class* i_this) {
return 1;
}
static f32 pd[19] = {1.0f, 0.9f, 0.8f, 0.7f, 0.6f, 0.5f, 0.4f, 0.3f, 0.2f, 0.2f,
0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f};
static void tail_control(fopAc_ac_c* param_1, wf_tail_s* param_2) {
static f32 pd[19] = {1.0f, 0.9f, 0.8f, 0.7f, 0.6f, 0.5f, 0.4f, 0.3f, 0.2f, 0.2f,
0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f, 0.2f};
cXyz local_74;
cXyz cStack_80;
int i;
+12 -12
View File
@@ -19,18 +19,6 @@ static char const* l_arcName[7] = {
"MirrorB",
};
static char const* l_stageName[9] = {
"D_MN05A",
"D_MN04A",
"D_MN01A",
"D_MN10A",
"D_MN11A",
"D_MN06A",
"D_MN07A",
"D_MN01A",
"D_MN01A",
};
static int const l_bmdIndex[7] = {4, 4, 4, 9, 9, 10, 11};
static int const l_brkIndex[3] = {7, 7, 7};
@@ -38,6 +26,18 @@ static int const l_brkIndex[3] = {7, 7, 7};
static int const l_btkIndex[7] = {14, 14, 14, 14, 14, 15, 16};
static int getNowLevel() {
static char const* l_stageName[9] = {
"D_MN05A",
"D_MN04A",
"D_MN01A",
"D_MN10A",
"D_MN11A",
"D_MN06A",
"D_MN07A",
"D_MN01A",
"D_MN01A",
};
for (int i = 0; i < 9; i++) {
if (!strcmp(dComIfGp_getStartStageName(), l_stageName[i])) {
return i + 1;
+1 -1
View File
@@ -56,7 +56,7 @@ int daTagKagoFall_c::execute() {
return TRUE;
}
void daTagKagoFall_c::setActionMode(ActionMode mode, u8 state) {
void daTagKagoFall_c::setActionMode(u8 mode, u8 state) {
mActionMode = mode;
mActionState = state;
}
+26 -26
View File
@@ -241,33 +241,33 @@ void daTagStatue_c::actionDead() {
/* empty function */
}
static char* action_table[3] = {
"WAIT",
"ST_MOVE",
"ITEM"
};
// Saved positions of Owl Statues for cutscenes
static Vec l_statue_pos[6] = {
{-17312.3007812f, -349.100006104f, -20523.1992188f}, // Faron Woods
{-17312.3007812f, -349.100006104f, -20523.1992188f}, // Gerudo Desert
{-9675.59960938f, -4800.0f, 39693.8984375f}, // Kakariko Gorge
{33345.6015625f, -75.5999984741f, -36331.1015625f}, // Great Eldin Bridge
{-94009.5f, -5440.10009766f, 18534.9003906f}, // Lake Hylia
{-81451.296875f, -1654.09997559f, 20832.1992188} // Ruined Theatre
};
// Saved y orientations of Owl Statues for cutscenes
static s16 l_statue_ang[6] = {
16384, // Faron Woods
16384, // Gerudo Desert
8485, // Kakariko Gorge
16384, // Great Eldin Bridge
16384, // Lake Hylia
16384 // Ruined Theatre
};
int daTagStatue_c::demoProc() {
static char* action_table[3] = {
"WAIT",
"ST_MOVE",
"ITEM"
};
// Saved positions of Owl Statues for cutscenes
static Vec l_statue_pos[6] = {
{-17312.3007812f, -349.100006104f, -20523.1992188f}, // Faron Woods
{-17312.3007812f, -349.100006104f, -20523.1992188f}, // Gerudo Desert
{-9675.59960938f, -4800.0f, 39693.8984375f}, // Kakariko Gorge
{33345.6015625f, -75.5999984741f, -36331.1015625f}, // Great Eldin Bridge
{-94009.5f, -5440.10009766f, 18534.9003906f}, // Lake Hylia
{-81451.296875f, -1654.09997559f, 20832.1992188} // Ruined Theatre
};
// Saved y orientations of Owl Statues for cutscenes
static s16 l_statue_ang[6] = {
16384, // Faron Woods
16384, // Gerudo Desert
8485, // Kakariko Gorge
16384, // Great Eldin Bridge
16384, // Lake Hylia
16384 // Ruined Theatre
};
int act_id = dComIfGp_evmng_getMyActIdx(mStaffId, action_table, ARRAY_SIZEU(action_table), 0, 0);
if(dComIfGp_evmng_getIsAddvance(mStaffId)) {
+4 -4
View File
@@ -11,11 +11,11 @@
#include "d/d_msg_object.h"
#include "d/d_pane_class.h"
static u64 t_tag[6] = {
'right_s', 'right', 'center_s', 'center', 'left_s', 'left',
};
dMsgScrnStaff_c::dMsgScrnStaff_c(u8 unused) {
static u64 t_tag[6] = {
'right_s', 'right', 'center_s', 'center', 'left_s', 'left',
};
init();
field_0xd0 = 0.0f;