mirror of
https://github.com/encounter/tp.git
synced 2026-07-11 06:18:46 -07:00
fix functions not returning values (#2942)
* fix functions not returning values * implement functions that should return values
This commit is contained in:
@@ -45,7 +45,7 @@ public:
|
||||
void setCollision();
|
||||
int drawDbgInfo();
|
||||
void drawOtherMdl();
|
||||
int setCupAnm(int, int, f32);
|
||||
bool setCupAnm(int, int, f32);
|
||||
bool afterSetMotionAnm(int, int, f32, int);
|
||||
daNpcT_faceMotionAnmData_c getFaceMotionAnm(daNpcT_faceMotionAnmData_c);
|
||||
void changeAnm(int*, int*);
|
||||
|
||||
@@ -17,6 +17,7 @@ struct daNpc_Pachi_Besu_HIOParam {
|
||||
};
|
||||
|
||||
class daNpc_Pachi_Besu_HIO_c : public mDoHIO_entry_c {
|
||||
public:
|
||||
/* 0x8 */ daNpc_Pachi_Besu_HIOParam param;
|
||||
};
|
||||
|
||||
|
||||
@@ -107,7 +107,7 @@ public:
|
||||
void setCollision();
|
||||
int drawDbgInfo();
|
||||
void drawOtherMdl();
|
||||
BOOL setFlagAnm(int, int, f32);
|
||||
bool setFlagAnm(int, int, f32);
|
||||
bool afterSetMotionAnm(int, int, f32, int);
|
||||
BOOL selectAction();
|
||||
BOOL chkAction(actionFunc);
|
||||
|
||||
@@ -96,7 +96,7 @@ public:
|
||||
|
||||
virtual ~daObj_KBacket_c();
|
||||
int create();
|
||||
int setLaunchParam(float param_0, float param_1, short param_2) {
|
||||
void setLaunchParam(float param_0, float param_1, short param_2) {
|
||||
float fVar2;
|
||||
|
||||
s16 iVar1 = cM_deg2s(param_1);
|
||||
|
||||
@@ -14,8 +14,8 @@ public:
|
||||
virtual ~daObjIsuChild_c();
|
||||
int createHeap();
|
||||
void create(daObjNagaisu_c*, dCcD_Stts*);
|
||||
int execute();
|
||||
int draw(dMdl_c*);
|
||||
void execute();
|
||||
void draw(dMdl_c*);
|
||||
void Delete();
|
||||
bool chkHit();
|
||||
void callEmt();
|
||||
|
||||
@@ -202,7 +202,7 @@ public:
|
||||
u8 getCptoNum(u8);
|
||||
void copyToSelBack();
|
||||
void copyToSelPaneMove();
|
||||
bool yesnoMenuMoveAnmInitSet(int, int);
|
||||
void yesnoMenuMoveAnmInitSet(int, int);
|
||||
bool yesnoMenuMoveAnm();
|
||||
bool yesnoSelectMoveAnm();
|
||||
void yesnoCursorShow();
|
||||
|
||||
@@ -654,7 +654,7 @@ f64 TFunctionValue_list::update_INTERPOLATE_BSPLINE_dataMore3_(
|
||||
dVar8 = rThis._44[param_2._10 + 2];
|
||||
}
|
||||
}
|
||||
functionvalue::interpolateValue_BSpline_uniform(param_2._0 - param_2._8, dVar9, dVar11, dVar10, dVar8);
|
||||
return functionvalue::interpolateValue_BSpline_uniform(param_2._0 - param_2._8, dVar9, dVar11, dVar10, dVar8);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -4902,7 +4902,7 @@ int daB_TN_c::execute() {
|
||||
}
|
||||
|
||||
static int daB_TN_Execute(daB_TN_c* i_this) {
|
||||
i_this->execute();
|
||||
return i_this->execute();
|
||||
}
|
||||
|
||||
static int daB_TN_IsDelete(daB_TN_c* i_this) {
|
||||
@@ -4924,7 +4924,7 @@ int daB_TN_c::_delete() {
|
||||
}
|
||||
|
||||
static int daB_TN_Delete(daB_TN_c* i_this) {
|
||||
i_this->_delete();
|
||||
return i_this->_delete();
|
||||
}
|
||||
|
||||
int daB_TN_c::CreateHeap() {
|
||||
@@ -5024,7 +5024,7 @@ int daB_TN_c::CreateHeap() {
|
||||
}
|
||||
|
||||
static int useHeapInit(fopAc_ac_c* actor) {
|
||||
((daB_TN_c*)actor)->CreateHeap();
|
||||
return ((daB_TN_c*)actor)->CreateHeap();
|
||||
}
|
||||
|
||||
int daB_TN_c::create() {
|
||||
|
||||
@@ -436,7 +436,7 @@ void daCstaF_c::setAnime() {
|
||||
|
||||
BOOL daCstaF_c::initBrk(u16 i_brkIdx) {
|
||||
void* pbrk = dComIfG_getObjectRes(m_arcName, i_brkIdx);
|
||||
m_brk.init(mp_model->getModelData(), (J3DAnmTevRegKey*)pbrk, 1, -1, 1.0f, 0, -1);
|
||||
return m_brk.init(mp_model->getModelData(), (J3DAnmTevRegKey*)pbrk, 1, -1, 1.0f, 0, -1);
|
||||
}
|
||||
|
||||
void daCstaF_c::initStopBrkBtk() {
|
||||
|
||||
@@ -51,7 +51,7 @@ int daE_DF_c::CreateHeap() {
|
||||
|
||||
static int useHeapInit(fopAc_ac_c* i_this) {
|
||||
daE_DF_c* actor = static_cast<daE_DF_c*>(i_this);
|
||||
actor->CreateHeap();
|
||||
return actor->CreateHeap();
|
||||
}
|
||||
|
||||
void daE_DF_c::initCcCylinder() {
|
||||
|
||||
@@ -189,7 +189,7 @@ static f32 dummyFloat3(int _) {
|
||||
switch (_) {
|
||||
case 0:
|
||||
return 30.0f;
|
||||
case 1:
|
||||
default:
|
||||
return 300.0f;
|
||||
}
|
||||
}
|
||||
@@ -266,7 +266,7 @@ static f32 dummyFloat4(int _) {
|
||||
return 2000.0f;
|
||||
case 1:
|
||||
return 1000.0f;
|
||||
case 2:
|
||||
default:
|
||||
return -4000.0f;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -183,7 +183,7 @@ static BOOL pl_check(daE_SM_c* i_this, f32 param_2) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
static BOOL move_check(daE_SM_c* i_this, int* param_2) {
|
||||
static void move_check(daE_SM_c* i_this, int* param_2) {
|
||||
*param_2 = -1;
|
||||
|
||||
if (pl_check(i_this, i_this->field_0x970)) {
|
||||
|
||||
@@ -422,7 +422,7 @@ int daNpc_Aru_c::Draw() {
|
||||
mdlData_p->getMaterialNodePointer(getEyeballMaterialNo())->setMaterialAnm(mpMatAnm[0]);
|
||||
}
|
||||
|
||||
draw(
|
||||
return draw(
|
||||
#if DEBUG
|
||||
chkAction(&daNpc_Aru_c::test),
|
||||
#else
|
||||
@@ -2019,6 +2019,23 @@ int daNpc_Aru_c::talk(void* param_1) {
|
||||
}
|
||||
|
||||
int daNpc_Aru_c::test(void* param_1) {
|
||||
switch(mMode) {
|
||||
case 0:
|
||||
case 1:
|
||||
speedF = 0.0f;
|
||||
speed.setall(0.0f);
|
||||
mMode = 2;
|
||||
// fallthrough
|
||||
case 2:
|
||||
mFaceMotionSeqMngr.setNo(mHIO->param.common.face_expression, -1.0f, 0, 0);
|
||||
mMotionSeqMngr.setNo(mHIO->param.common.motion, -1.0f, 0, 0);
|
||||
mJntAnm.lookNone(0);
|
||||
attention_info.flags = 0;
|
||||
break;
|
||||
case 3:
|
||||
break;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
static int daNpc_Aru_Create(void* a_this) {
|
||||
|
||||
@@ -1488,7 +1488,7 @@ void daNpc_Besu_c::drawOtherMdl() {
|
||||
}
|
||||
}
|
||||
|
||||
int daNpc_Besu_c::setCupAnm(int arg0, int i_attr, f32 i_morf) {
|
||||
bool daNpc_Besu_c::setCupAnm(int arg0, int i_attr, f32 i_morf) {
|
||||
static int cupAnmData[33][2] = {
|
||||
{-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0},
|
||||
{-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0}, {-1, 0},
|
||||
@@ -1508,12 +1508,12 @@ int daNpc_Besu_c::setCupAnm(int arg0, int i_attr, f32 i_morf) {
|
||||
}
|
||||
}
|
||||
|
||||
return 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool daNpc_Besu_c::afterSetMotionAnm(int arg0, int arg1, f32 arg2, int param_3) {
|
||||
f32 var_f30 = (mCreating == 1) ? 0.0f : arg2;
|
||||
setCupAnm(arg0, arg1, var_f30);
|
||||
return setCupAnm(arg0, arg1, var_f30);
|
||||
}
|
||||
|
||||
daNpcT_faceMotionAnmData_c daNpc_Besu_c::getFaceMotionAnm(daNpcT_faceMotionAnmData_c arg0) {
|
||||
|
||||
@@ -439,7 +439,7 @@ int daNpcChin_c::ctrlJoint(J3DJoint* i_joint, J3DModel* i_model) {
|
||||
|
||||
int daNpcChin_c::createHeapCallBack(fopAc_ac_c* i_this) {
|
||||
daNpcChin_c* chin = (daNpcChin_c*)i_this;
|
||||
chin->CreateHeap();
|
||||
return chin->CreateHeap();
|
||||
}
|
||||
|
||||
int daNpcChin_c::ctrlJointCallBack(J3DJoint* i_joint, int param_1) {
|
||||
|
||||
@@ -831,7 +831,24 @@ int daNpc_Doc_c::talk(void* param_0) {
|
||||
}
|
||||
|
||||
int daNpc_Doc_c::test(void* i_this) {
|
||||
// DEBUG NONMATCHING
|
||||
int ret = 0;
|
||||
switch(mMode) {
|
||||
case 0:
|
||||
case 1:
|
||||
speedF = 0.0f;
|
||||
speed.setall(0.0f);
|
||||
mMode = 2;
|
||||
// fallthrough
|
||||
case 2:
|
||||
mFaceMotionSeqMngr.setNo(mpHIO->m.common.face_expression, -1.0f, 0, 0);
|
||||
mMotionSeqMngr.setNo(mpHIO->m.common.motion, -1.0f, 0, 0);
|
||||
mJntAnm.lookNone(0);
|
||||
attention_info.flags = 0;
|
||||
break;
|
||||
case 3:
|
||||
break;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int daNpc_Doc_Create(void* i_this) {
|
||||
|
||||
@@ -265,13 +265,13 @@ int daNpc_grS_c::Delete() {
|
||||
}
|
||||
|
||||
int daNpc_grS_c::Execute() {
|
||||
execute();
|
||||
return execute();
|
||||
}
|
||||
|
||||
int daNpc_grS_c::Draw() {
|
||||
J3DModelData* modelData = mAnm_p->getModel()->getModelData();
|
||||
modelData->getMaterialNodePointer(2)->setMaterialAnm(mpMatAnm);
|
||||
draw(chkAction(&daNpc_grS_c::test),0, mpHIO->m.common.real_shadow_size,NULL,0);
|
||||
return draw(chkAction(&daNpc_grS_c::test),0, mpHIO->m.common.real_shadow_size,NULL,0);
|
||||
}
|
||||
|
||||
int daNpc_grS_c::ctrlJoint(J3DJoint* i_joint, J3DModel* i_model) {
|
||||
@@ -318,7 +318,7 @@ int daNpc_grS_c::ctrlJoint(J3DJoint* i_joint, J3DModel* i_model) {
|
||||
|
||||
int daNpc_grS_c::createHeapCallBack(fopAc_ac_c* i_this) {
|
||||
daNpc_grS_c* grS = (daNpc_grS_c*)i_this;
|
||||
grS->CreateHeap();
|
||||
return grS->CreateHeap();
|
||||
}
|
||||
|
||||
int daNpc_grS_c::ctrlJointCallBack(J3DJoint* i_joint, int param_1) {
|
||||
|
||||
@@ -333,7 +333,7 @@ static f32 dummyFloat(int _) {
|
||||
switch (_) {
|
||||
case 0: return 0.0f;
|
||||
case 1: return 65536.0f;
|
||||
case 2: return 0.2f;
|
||||
default: return 0.2f;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1023,11 +1023,11 @@ u32 daNpc_Kn_c::setParamTeach05() {
|
||||
}
|
||||
|
||||
u32 daNpc_Kn_c::setParamTeach06() {
|
||||
setParamTeach05();
|
||||
return setParamTeach05();
|
||||
}
|
||||
|
||||
u32 daNpc_Kn_c::setParamTeach07() {
|
||||
setParamTeach05();
|
||||
return setParamTeach05();
|
||||
}
|
||||
|
||||
void daNpc_Kn_c::setAfterTalkMotion() {
|
||||
|
||||
@@ -381,7 +381,7 @@ int daNpc_Kolinb_c::Draw() {
|
||||
modelData->getMaterialNodePointer(getEyeballMaterialNo())->setMaterialAnm(mpMatAnm[0]);
|
||||
}
|
||||
|
||||
draw(FALSE, FALSE, mRealShadowSize, NULL, 100.0f, FALSE, FALSE, FALSE);
|
||||
return draw(FALSE, FALSE, mRealShadowSize, NULL, 100.0f, FALSE, FALSE, FALSE);
|
||||
}
|
||||
|
||||
int daNpc_Kolinb_c::createHeapCallBack(fopAc_ac_c* a_this) {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user