mirror of https://github.com/zeldaret/tp.git
Adressed review comments, added CUT_TYPE_NONE in cut type enum
This commit is contained in:
parent
0624b9e81d
commit
63f7e71235
|
@ -599,7 +599,8 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
enum CutType {
|
enum CutType {
|
||||||
/* 0x01 */ CUT_TYPE_NM_VERTICAL = 1,
|
/* 0x00 */ CUT_TYPE_NONE,
|
||||||
|
/* 0x01 */ CUT_TYPE_NM_VERTICAL,
|
||||||
/* 0x02 */ CUT_TYPE_NM_STAB,
|
/* 0x02 */ CUT_TYPE_NM_STAB,
|
||||||
/* 0x03 */ CUT_TYPE_NM_RIGHT,
|
/* 0x03 */ CUT_TYPE_NM_RIGHT,
|
||||||
/* 0x04 */ CUT_TYPE_NM_LEFT,
|
/* 0x04 */ CUT_TYPE_NM_LEFT,
|
||||||
|
|
|
@ -9,11 +9,11 @@
|
||||||
#include "d/actor/d_a_npc_kkri.h"
|
#include "d/actor/d_a_npc_kkri.h"
|
||||||
#include "d/d_cc_d.h"
|
#include "d/d_cc_d.h"
|
||||||
#include "d/d_s_play.h"
|
#include "d/d_s_play.h"
|
||||||
|
#include "Z2AudioLib/Z2Instances.h"
|
||||||
|
UNK_REL_BSS
|
||||||
|
|
||||||
/* ############################################################################################## */
|
/* ############################################################################################## */
|
||||||
|
|
||||||
static u8 padding[0x3D]; // Padding to align .bss
|
|
||||||
|
|
||||||
struct land_pos {
|
struct land_pos {
|
||||||
/* 0x00 */ s32 unk;
|
/* 0x00 */ s32 unk;
|
||||||
|
@ -176,7 +176,7 @@ static void pl_check(bd_class* i_this) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((i_this->field_0x618 & 0xF) == 0) {
|
if ((i_this->field_0x618 & 0xF) == 0) {
|
||||||
var_r28 = (u32)fpcM_Search((fopAcIt_JudgeFunc)s_a_sub, a_this);
|
var_r28 = (u32)fpcM_Search(s_a_sub, a_this);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (daPy_getPlayerActorClass()->checkHorseRide()) {
|
if (daPy_getPlayerActorClass()->checkHorseRide()) {
|
||||||
|
@ -186,7 +186,7 @@ static void pl_check(bd_class* i_this) {
|
||||||
}
|
}
|
||||||
|
|
||||||
var_f31 = l_HIO.mLinkDetectRange + 10.0f * fabsf(var_f30);
|
var_f31 = l_HIO.mLinkDetectRange + 10.0f * fabsf(var_f30);
|
||||||
if (player->getCutType() != 0) {
|
if (player->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
var_f31 += 300.0f;
|
var_f31 += 300.0f;
|
||||||
}
|
}
|
||||||
if (i_this->field_0x5DC < var_f31 || sp8.abs() < var_f31 || var_r28 != 0) {
|
if (i_this->field_0x5DC < var_f31 || sp8.abs() < var_f31 || var_r28 != 0) {
|
||||||
|
@ -392,7 +392,7 @@ static void bd_ground(bd_class* i_this) {
|
||||||
}
|
}
|
||||||
drop_check(i_this);
|
drop_check(i_this);
|
||||||
if (i_this->field_0x658 == 0) {
|
if (i_this->field_0x658 == 0) {
|
||||||
if (fopAcM_CheckCondition(a_this, fopAcCnd_NODRAW_e) != 0) {
|
if (fopAcM_CheckCondition(a_this, fopAcCnd_NODRAW_e)) {
|
||||||
if (i_this->field_0x64C[3] > 50) {
|
if (i_this->field_0x64C[3] > 50) {
|
||||||
i_this->field_0x64C[3] = 30.0f + cM_rndF(20.0f);
|
i_this->field_0x64C[3] = 30.0f + cM_rndF(20.0f);
|
||||||
}
|
}
|
||||||
|
@ -1115,3 +1115,5 @@ extern actor_process_profile_definition g_profile_BD = {
|
||||||
fopAc_ACTOR_e, // mActorType
|
fopAc_ACTOR_e, // mActorType
|
||||||
fopAc_CULLBOX_0_e, // cullType
|
fopAc_CULLBOX_0_e, // cullType
|
||||||
};
|
};
|
||||||
|
|
||||||
|
AUDIO_INSTANCES
|
||||||
|
|
|
@ -1045,7 +1045,7 @@ static int daE_HZELDA_Execute(e_hzelda_class* i_this) {
|
||||||
BOOL on_player_at_sph = FALSE;
|
BOOL on_player_at_sph = FALSE;
|
||||||
|
|
||||||
if (daPy_py_c::checkMasterSwordEquip()) {
|
if (daPy_py_c::checkMasterSwordEquip()) {
|
||||||
if (daPy_getPlayerActorClass()->getCutType() != 0) {
|
if (daPy_getPlayerActorClass()->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
i_this->mSwordAtTimer++;
|
i_this->mSwordAtTimer++;
|
||||||
if (i_this->mSwordAtTimer < 6) {
|
if (i_this->mSwordAtTimer < 6) {
|
||||||
on_player_at_sph = TRUE;
|
on_player_at_sph = TRUE;
|
||||||
|
|
|
@ -354,7 +354,7 @@ int daE_OC_c::searchPlayerShakeHead() {
|
||||||
int daE_OC_c::searchSound() {
|
int daE_OC_c::searchSound() {
|
||||||
if (field_0x6b4 == 2 && mpBridge && mpBridge->getPlayerRide())
|
if (field_0x6b4 == 2 && mpBridge && mpBridge->getPlayerRide())
|
||||||
return 0;
|
return 0;
|
||||||
if (daPy_getPlayerActorClass()->getCutType() != 0 && fopAcM_searchPlayerDistance(this) < mPlayerRange) {
|
if (daPy_getPlayerActorClass()->getCutType() != daPy_py_c::CUT_TYPE_NONE && fopAcM_searchPlayerDistance(this) < mPlayerRange) {
|
||||||
field_0x67c = dComIfGp_getPlayer(0)->current.pos;
|
field_0x67c = dComIfGp_getPlayer(0)->current.pos;
|
||||||
setActionMode(8, 0);
|
setActionMode(8, 0);
|
||||||
return 1;
|
return 1;
|
||||||
|
|
|
@ -147,7 +147,7 @@ static void e_tk_ball_move(e_tk_ball_class* i_this) {
|
||||||
if (i_this->mTgSph.ChkTgHit() || i_this->mAtSph.ChkAtShieldHit()) {
|
if (i_this->mTgSph.ChkTgHit() || i_this->mAtSph.ChkAtShieldHit()) {
|
||||||
impact_eff_set(i_this);
|
impact_eff_set(i_this);
|
||||||
actor->current.angle.x *= -1;
|
actor->current.angle.x *= -1;
|
||||||
if (actor_lockon && daPy_getPlayerActorClass()->getCutType() != 0x00) {
|
if (actor_lockon && daPy_getPlayerActorClass()->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
i_this->mAction = ACT_TK_BALL_RETURN;
|
i_this->mAction = ACT_TK_BALL_RETURN;
|
||||||
i_this->mMode = MODE_TK_BALL_INIT;
|
i_this->mMode = MODE_TK_BALL_INIT;
|
||||||
actor->current.angle.y -= 0x8000;
|
actor->current.angle.y -= 0x8000;
|
||||||
|
@ -168,7 +168,7 @@ static void e_tk_ball_move(e_tk_ball_class* i_this) {
|
||||||
i_this->mInitalDistance = direction_vec.abs();
|
i_this->mInitalDistance = direction_vec.abs();
|
||||||
speed_vec.x = 0.0;
|
speed_vec.x = 0.0;
|
||||||
speed_vec.y = 0.0;
|
speed_vec.y = 0.0;
|
||||||
if (daPy_getPlayerActorClass()->getCutType() != 0x00) {
|
if (daPy_getPlayerActorClass()->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
speed_vec.z = 60.0f;
|
speed_vec.z = 60.0f;
|
||||||
}
|
}
|
||||||
cMtx_YrotS(*calc_mtx, actor->current.angle.y);
|
cMtx_YrotS(*calc_mtx, actor->current.angle.y);
|
||||||
|
|
|
@ -134,7 +134,7 @@ static void damage_check(e_yd_class* i_this) {
|
||||||
j = i_this->field_0xff4.mpCollider->ChkAtType(AT_TYPE_BOMB | AT_TYPE_40);
|
j = i_this->field_0xff4.mpCollider->ChkAtType(AT_TYPE_BOMB | AT_TYPE_40);
|
||||||
if (j != 0 || i_this->field_0x66e == 6) {
|
if (j != 0 || i_this->field_0x66e == 6) {
|
||||||
at_power_check(&i_this->field_0xff4);
|
at_power_check(&i_this->field_0xff4);
|
||||||
if (daPy_getPlayerActorClass()->getCutType() != 0) {
|
if (daPy_getPlayerActorClass()->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
cVar6 = 1;
|
cVar6 = 1;
|
||||||
} else {
|
} else {
|
||||||
cVar6 = 2;
|
cVar6 = 2;
|
||||||
|
|
|
@ -50,7 +50,7 @@ static void daKytag12_light_swprd_proc(kytag12_class* i_this) {
|
||||||
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
|
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
|
||||||
|
|
||||||
if (dComIfGs_getSelectEquipSword() == fpcNm_ITEM_LIGHT_SWORD) {
|
if (dComIfGs_getSelectEquipSword() == fpcNm_ITEM_LIGHT_SWORD) {
|
||||||
if (player->getCutType() != 0) {
|
if (player->getCutType() != daPy_py_c::CUT_TYPE_NONE) {
|
||||||
if (i_this->field_0x576 == 0) {
|
if (i_this->field_0x576 == 0) {
|
||||||
cXyz sp28(player->current.pos);
|
cXyz sp28(player->current.pos);
|
||||||
sp28.y -= 100.0f;
|
sp28.y -= 100.0f;
|
||||||
|
@ -878,7 +878,7 @@ static int daKytag12_Execute_R00(kytag12_class* i_this) {
|
||||||
sp80.y = player->current.pos.y;
|
sp80.y = player->current.pos.y;
|
||||||
|
|
||||||
if (player->current.pos.abs(sp80) < 600.0f &&
|
if (player->current.pos.abs(sp80) < 600.0f &&
|
||||||
dComIfGs_getSelectEquipSword() == fpcNm_ITEM_LIGHT_SWORD && player->getCutType() != 0 &&
|
dComIfGs_getSelectEquipSword() == fpcNm_ITEM_LIGHT_SWORD && player->getCutType() != daPy_py_c::CUT_TYPE_NONE &&
|
||||||
d_kytag12_cut_turn_check())
|
d_kytag12_cut_turn_check())
|
||||||
{
|
{
|
||||||
i_this->field_0x575 = 1;
|
i_this->field_0x575 = 1;
|
||||||
|
|
Loading…
Reference in New Issue