diff options
| author | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2026-07-24 11:25:35 -0400 |
|---|---|---|
| committer | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2026-07-24 11:25:35 -0400 |
| commit | 7efaae45c77dd3ce555e73970ae9182ec2dd4e76 (patch) | |
| tree | d0018f02deade08e66c9e834581e3cb61d1daf53 | |
| parent | af1c8e261e402c7ce879ea541c8dbe794f177483 (diff) | |
A couple demo matches
| -rwxr-xr-x | configure.py | 4 | ||||
| -rw-r--r-- | include/SSystem/SComponent/c_m3d_g_lin.h | 7 | ||||
| -rw-r--r-- | include/d/actor/d_a_windmill.h | 5 | ||||
| -rw-r--r-- | src/d/actor/d_a_daiocta.cpp | 16 | ||||
| -rw-r--r-- | src/d/actor/d_a_npc_bm1.cpp | 4 | ||||
| -rw-r--r-- | src/d/actor/d_a_obj_movebox.cpp | 123 | ||||
| -rw-r--r-- | src/d/actor/d_a_windmill.cpp | 23 | ||||
| -rw-r--r-- | src/d/d_camera.cpp | 2 |
8 files changed, 91 insertions, 93 deletions
diff --git a/configure.py b/configure.py index c2e3efe6..19440f2f 100755 --- a/configure.py +++ b/configure.py @@ -575,7 +575,7 @@ config.libs = [ Object(Matching, "d/d_cam_type2.cpp"), Object(NonMatching, "d/d_ev_camera.cpp"), Object(MatchingFor("GZLJ01", "GZLE01", "GZLP01"), "d/d_wood.cpp"), - Object(NonMatching, "d/d_flower.cpp"), + Object(MatchingFor("GZLJ01", "GZLE01", "GZLP01"), "d/d_flower.cpp"), Object(Matching, "d/d_item_data.cpp"), Object(Matching, "d/d_seafightgame.cpp"), Object(Matching, "d/d_spline_path.cpp"), @@ -1813,7 +1813,7 @@ config.libs = [ ActorRel(Matching, "d_a_tag_ret"), ActorRel(MatchingFor("GZLJ01", "GZLE01", "GZLP01"), "d_a_tag_volcano"), ActorRel(MatchingFor("GZLJ01", "GZLE01", "GZLP01"), "d_a_title"), - ActorRel(NonMatching, "d_a_tn"), + ActorRel(MatchingFor("D44J01"), "d_a_tn"), ActorRel(Matching, "d_a_toge"), ActorRel(Matching, "d_a_tori_flag"), ActorRel(MatchingFor("GZLJ01", "GZLE01", "GZLP01"), "d_a_wall"), diff --git a/include/SSystem/SComponent/c_m3d_g_lin.h b/include/SSystem/SComponent/c_m3d_g_lin.h index f0571acc..1f85cac8 100644 --- a/include/SSystem/SComponent/c_m3d_g_lin.h +++ b/include/SSystem/SComponent/c_m3d_g_lin.h @@ -20,12 +20,11 @@ public: mEnd = end; } void SetStartEnd(const Vec& start, const Vec& end) { - mStart = start; - mEnd = end; + mStart.set(start); + mEnd.set(end); } void set(const Vec& start, const Vec& end) { - mStart = start; - mEnd = end; + SetStartEnd(start, end); } void CalcPos(Vec* out, f32 scale) const { Vec tmp; diff --git a/include/d/actor/d_a_windmill.h b/include/d/actor/d_a_windmill.h index bbd4909d..59466b16 100644 --- a/include/d/actor/d_a_windmill.h +++ b/include/d/actor/d_a_windmill.h @@ -4,6 +4,7 @@ #include "f_op/f_op_actor.h" #include "d/d_cc_d.h" #include "SSystem/SComponent/c_phase.h" +#include "f_op/f_op_actor_mng.h" class dBgW; @@ -49,6 +50,8 @@ public: /* 0x1420 */ u32 mWindTagId; }; -STATIC_ASSERT(sizeof(daWindMill_c) == 0x1424); +namespace daWindMill_prm { + inline u8 getType(daWindMill_c* i_this) { return fopAcM_GetParam(i_this) & 0xF; } +}; #endif /* D_A_WINDMILL_H */ diff --git a/src/d/actor/d_a_daiocta.cpp b/src/d/actor/d_a_daiocta.cpp index 528443df..677328cf 100644 --- a/src/d/actor/d_a_daiocta.cpp +++ b/src/d/actor/d_a_daiocta.cpp @@ -838,36 +838,36 @@ void daDaiocta_c::setCollision() { break; } - mCps[i].set(mSphCenters[j], mSphCenters[k]); + mCps[i].SetStartEnd(mSphCenters[j], mSphCenters[k]); mCps[i].SetR(l_HIO.mCpsRadii[i]); dComIfG_Ccsp()->Set(&mCps[i]); } - mCps[10].set(mSphCenters[36], m21AC); + mCps[10].SetStartEnd(mSphCenters[36], m21AC); mCps[10].SetR(l_HIO.m05C); dComIfG_Ccsp()->Set(&mCps[10]); - mCps[11].set(mSphCenters[30], m21A0); + mCps[11].SetStartEnd(mSphCenters[30], m21A0); mCps[11].SetR(l_HIO.m060); dComIfG_Ccsp()->Set(&mCps[11]); - mCps[12].set(mSphCenters[6], m21B8); + mCps[12].SetStartEnd(mSphCenters[6], m21B8); mCps[12].SetR(l_HIO.m064); dComIfG_Ccsp()->Set(&mCps[12]); - mCps[13].set(mSphCenters[10], m21DC); + mCps[13].SetStartEnd(mSphCenters[10], m21DC); mCps[13].SetR(l_HIO.m068); dComIfG_Ccsp()->Set(&mCps[13]); - mCps[14].set(mSphCenters[8], m21E8); + mCps[14].SetStartEnd(mSphCenters[8], m21E8); mCps[14].SetR(l_HIO.m06C); dComIfG_Ccsp()->Set(&mCps[14]); - mCps[15].set(mSphCenters[9], m21C4); + mCps[15].SetStartEnd(mSphCenters[9], m21C4); mCps[15].SetR(l_HIO.m070); dComIfG_Ccsp()->Set(&mCps[15]); - mCps[16].set(mSphCenters[7], m21D0); + mCps[16].SetStartEnd(mSphCenters[7], m21D0); mCps[16].SetR(l_HIO.m074); dComIfG_Ccsp()->Set(&mCps[16]); } diff --git a/src/d/actor/d_a_npc_bm1.cpp b/src/d/actor/d_a_npc_bm1.cpp index 6cab1b04..eb257ca0 100644 --- a/src/d/actor/d_a_npc_bm1.cpp +++ b/src/d/actor/d_a_npc_bm1.cpp @@ -3285,11 +3285,11 @@ BOOL daNpc_Bm1_c::wait_6() { /* 000065B8-00006688 .text h_wait__11daNpc_Bm1_cFv */ BOOL daNpc_Bm1_c::h_wait() { - if ((m8FD == 1) || (m8FD >= '\x03')) { + if ((m8FD == 1) || (m8FD >= 3)) { return TRUE; } if (m895) { - if (chk_talk() != '\0') { + if (chk_talk()) { setStt(5); } return TRUE; diff --git a/src/d/actor/d_a_obj_movebox.cpp b/src/d/actor/d_a_obj_movebox.cpp index eac8b143..53bd9a16 100644 --- a/src/d/actor/d_a_obj_movebox.cpp +++ b/src/d/actor/d_a_obj_movebox.cpp @@ -25,6 +25,7 @@ #include "d/actor/d_a_obj_eff.h" namespace daObjMovebox { + dBgS_ObjGndChk Bgc_c::M_gnd_work[23]; dBgS_WtrChk Bgc_c::M_wrt_work; dBgS_ObjLinChk Bgc_c::M_wall_work[23]; @@ -1133,18 +1134,19 @@ namespace daObjMovebox { int swSave2 = prmZ_get_swSave2(); bool isMoved1 = is_switch1(); + u32 isMoved2 = false; if (swSave2 == 0xFF) { isMoved2 = false; } else { - isMoved2 = is_switch2(); - isMoved2 = !!isMoved2; + isMoved2 = is_switch2() ? true : false; } - isMoved2 = !!isMoved2; + // TODO: is this a fakematch? why the extra conversion to bool here? + isMoved2 = isMoved2 ? true : false; int pntIdx = 0; - if (isMoved1 != false) { - pntIdx = 1; + if (isMoved1) { + pntIdx += 1; } if (isMoved2) { pntIdx += 2; @@ -1255,45 +1257,41 @@ namespace daObjMovebox { } /* 00001C64-00001DD4 .text PPCallBack__Q212daObjMovebox5Act_cFP10fopAc_ac_cP10fopAc_ac_csQ24dBgW13PushPullLabel */ - fopAc_ac_c* Act_c::PPCallBack(fopAc_ac_c* actor, fopAc_ac_c*, s16 angle, dBgW::PushPullLabel orig_pp_label) { + fopAc_ac_c* Act_c::PPCallBack(fopAc_ac_c* actor, fopAc_ac_c*, s16 angle, dBgW::PushPullLabel i_pp_label) { Act_c* i_this = (Act_c*)actor; - dBgW::PushPullLabel pp_label = static_cast<dBgW::PushPullLabel>(orig_pp_label & (dBgW::PPLABEL_PUSH | dBgW::PPLABEL_PULL)); - if (pp_label) { - bool unk; - if (!i_this->attr()->m9A) { - unk = true; + dBgW::PushPullLabel pp_label = cLib_checkBit(i_pp_label, (dBgW::PushPullLabel)(dBgW::PPLABEL_PUSH | dBgW::PPLABEL_PULL)); + bool can_push = i_this->attr()->m9A ? + (cLib_checkBit(i_pp_label, dBgW::PPLABEL_HEAVY) ? true : false) : + true; + if (pp_label && can_push) { + s16 moveAng = cLib_checkBit(pp_label, dBgW::PPLABEL_PULL) ? angle - 0x8000 : angle; + s16 angleDiff = moveAng - actor->home.angle.y; + const int pp_field = dBgW::PPLABEL_PUSH | dBgW::PPLABEL_PULL; + JUT_ASSERT(1813, pp_label != pp_field); + + i_this->mPPLabel = i_pp_label; + + int whichSide; + if (angleDiff >= -0x2000 && angleDiff < 0x2000) { + whichSide = 0; + } else if (angleDiff >= 0x2000 && angleDiff < 0x6000) { + whichSide = 1; + } else if (angleDiff >= 0x6000 || angleDiff < -0x6000) { + whichSide = 2; } else { - unk = orig_pp_label & dBgW::PPLABEL_HEAVY; + whichSide = 3; } - if (unk) { - s16 angleDiff = (s16)(pp_label & dBgW::PPLABEL_PULL ? angle - 0x8000 : angle) - actor->home.angle.y; - int pp_field = dBgW::PPLABEL_PUSH | dBgW::PPLABEL_PULL; - JUT_ASSERT(1813, pp_label != pp_field); - - i_this->mPPLabel = orig_pp_label; - - int whichSide; - if (angleDiff >= -0x2000 && angleDiff < 0x2000) { - whichSide = 0; - } else if (angleDiff >= 0x2000 && angleDiff < 0x6000) { - whichSide = 1; - } else if (angleDiff >= 0x6000 || angleDiff < -0x6000) { - whichSide = 2; + + for (int i = 0; i < 4; i++) { + if (i == whichSide) { + i_this->mMomentCnt[i]++; } else { - whichSide = 3; + i_this->mMomentCnt[i] = 0; } - - for (int i = 0; i < 4; i++) { - if (i == whichSide) { - i_this->mMomentCnt[i]++; - } else { - i_this->mMomentCnt[i] = 0; - } - } - - i_this->m64A = true; } + + i_this->m64A = true; } return actor; @@ -1328,7 +1326,7 @@ namespace daObjMovebox { mCyl.SetStts(&mStts); mCyl.SetTgVec((cXyz&)cXyz::Zero); mCyl.OnTgNoHitMark(); - mCyl.OffCoSetBit(); + mCyl.OffCoSPrmBit(cCcD_CoSPrm_Set_e); fopAcM_SetMtx(this, mMtx); fopAcM_setCullSizeBox(this, @@ -1336,8 +1334,8 @@ namespace daObjMovebox { attr()->mCullMaxX, attr()->mCullMaxY, attr()->mCullMaxZ ); - speedF = 0.0f; - gravity = attr()->m14; + fopAcM_SetSpeedF(this, 0.0f); + fopAcM_SetGravity(this, attr()->m14); fopAcM_posMoveF(this, NULL); mBgc.proc_vertical(this); cLib_offBit(mBgc.mStateFlags, static_cast<Bgc_c::State_e>(Bgc_c::BgcState_JUST_LEFT_GROUND_e | Bgc_c::BgcState_JUST_HIT_GROUND_e | Bgc_c::BgcState_JUST_HIT_WATER_e)); @@ -1387,7 +1385,7 @@ namespace daObjMovebox { BgcSrc_c* bgcSrc; // fakematch? a cast here seems necessary to get the bgcSrc to temporarily be placed in r0 and then moved bgcSrc = const_cast<BgcSrc_c*>(attr()->m9A ? Bgc_c::M_lin20 : Bgc_c::M_lin5); - bgcSrcCount = attr()->m9A ? ARRAY_SIZE(Bgc_c::M_lin20)-2 : ARRAY_SIZE(Bgc_c::M_lin5); + bgcSrcCount = attr()->m9A ? ARRAY_SIZE(mBgc.M_lin20)-2 : ARRAY_SIZE(mBgc.M_lin5); bool touchedFrontBack = mBgc.chk_wall_touch2(this, bgcSrc, bgcSrcCount, M_dir_base[0]) || mBgc.chk_wall_touch2(this, bgcSrc, bgcSrcCount, M_dir_base[2]); @@ -1401,10 +1399,12 @@ namespace daObjMovebox { m610 *= temp; } - f32 f5 = -(m618 - m610) * attr()->m50; - f32 f6 = -m620 * attr()->m54; - f32 f1 = -(m614 - m60C) * attr()->m50; + f32 temp2 = m614 - m60C; + f32 temp1 = m618 - m610; + f32 f1 = -temp2 * attr()->m50; + f32 f5 = -temp1 * attr()->m50; f32 f0 = -m61C * attr()->m54; + f32 f6 = -m620 * attr()->m54; m61C += f1 + f0; m620 += f5 + f6; m614 += m61C; @@ -1447,7 +1447,7 @@ namespace daObjMovebox { for (int i = 0; i < (int)ARRAY_SIZE(mMomentCnt); i++) { if (mMomentCnt[i] >= r0) { const BgcSrc_c* bgcSrc = attr()->m9A ? Bgc_c::M_lin20 : Bgc_c::M_lin5; - int bgcSrcCount = attr()->m9A ? (mType == TYPE_MIRROR ? ARRAY_SIZE(Bgc_c::M_lin20) : ARRAY_SIZE(Bgc_c::M_lin20)-2) : ARRAY_SIZE(Bgc_c::M_lin5); + int bgcSrcCount = attr()->m9A ? (mType == TYPE_MIRROR ? ARRAY_SIZE(mBgc.M_lin20) : ARRAY_SIZE(mBgc.M_lin20)-2) : ARRAY_SIZE(mBgc.M_lin5); if (!mBgc.chk_wall_pre(this, bgcSrc, bgcSrcCount, M_dir_base[i])) { r30 = i; } @@ -1546,8 +1546,8 @@ namespace daObjMovebox { /* 00002AD4-00002B48 .text mode_wait_init__Q212daObjMovebox5Act_cFv */ void Act_c::mode_wait_init() { - speedF = 0.0f; - gravity = attr()->m14; + fopAcM_SetSpeedF(this, 0.0f); + fopAcM_SetGravity(this, attr()->m14); mpBgW->SetCrrFunc(dBgS_MoveBGProc_Trans); clr_moment_cnt(); m634 = -1; @@ -1595,7 +1595,7 @@ namespace daObjMovebox { /* 00002D84-00002DA4 .text mode_walk_init__Q212daObjMovebox5Act_cFv */ void Act_c::mode_walk_init() { - speedF = 0.0f; + fopAcM_SetSpeedF(this, 0.0f); m64F = false; mMode = MODE_WALK; } @@ -1627,7 +1627,7 @@ namespace daObjMovebox { if (r28) { const BgcSrc_c* bgcSrc = attr()->m9A ? Bgc_c::M_lin20 : Bgc_c::M_lin5; - int bgcSrcCount = attr()->m9A ? (mType == TYPE_MIRROR ? ARRAY_SIZE(Bgc_c::M_lin20) : ARRAY_SIZE(Bgc_c::M_lin20)-2) : ARRAY_SIZE(Bgc_c::M_lin5); + int bgcSrcCount = attr()->m9A ? (mType == TYPE_MIRROR ? ARRAY_SIZE(mBgc.M_lin20) : ARRAY_SIZE(mBgc.M_lin20)-2) : ARRAY_SIZE(mBgc.M_lin5); if (mBgc.chk_wall_pre(this, bgcSrc, bgcSrcCount, M_dir_base[m634])) { sound_limit(); } @@ -1657,7 +1657,7 @@ namespace daObjMovebox { /* 000031AC-000031D4 .text mode_afl_init__Q212daObjMovebox5Act_cFv */ void Act_c::mode_afl_init() { - speedF = 0.0f; + fopAcM_SetSpeedF(this, 0.0f); mpBgW->SetCrrFunc(dBgS_MoveBGProc_Typical); mMode = MODE_AFLOAT; } @@ -1679,7 +1679,7 @@ namespace daObjMovebox { s16 r3 = attr()->m38 * (1.0f + cM_rnd()); m604 += r3; - gravity = (f0 * attr()->m28) + attr()->m14 + attr()->m34 * cM_ssin(m604) + m608; + fopAcM_SetGravity(this, (f0 * attr()->m28) + attr()->m14 + attr()->m34 * cM_ssin(m604) + m608); m608 = 0.0f; afl_sway(); @@ -1744,7 +1744,7 @@ namespace daObjMovebox { void Act_c::sound_slip() { s32 mtrlSndId = 0; if (mBgc.mMaxGroundIdx >= 0) { - dBgS_ObjGndChk& gndChk = Bgc_c::M_gnd_work[mBgc.mMaxGroundIdx]; + dBgS_ObjGndChk& gndChk = mBgc.M_gnd_work[mBgc.mMaxGroundIdx]; if (gndChk.GetBgIndex() >= 0 && gndChk.GetBgIndex() < 0x100) { mtrlSndId = dComIfG_Bgsp()->GetMtrlSndId(gndChk); } @@ -1757,7 +1757,7 @@ namespace daObjMovebox { void Act_c::sound_limit() { s32 mtrlSndId = 0; if (mBgc.mWallIdx >= 0) { - dBgS_ObjLinChk& linChk = Bgc_c::M_wall_work[mBgc.mWallIdx]; + dBgS_ObjLinChk& linChk = mBgc.M_wall_work[mBgc.mWallIdx]; if (linChk.GetBgIndex() >= 0 && linChk.GetBgIndex() < 0x100) { mtrlSndId = dComIfG_Bgsp()->GetMtrlSndId(linChk); } @@ -1770,7 +1770,7 @@ namespace daObjMovebox { void Act_c::sound_land() { s32 mtrlSndId = 0; if (mBgc.mMaxGroundIdx >= 0) { - dBgS_ObjGndChk& gndChk = Bgc_c::M_gnd_work[mBgc.mMaxGroundIdx]; + dBgS_ObjGndChk& gndChk = mBgc.M_gnd_work[mBgc.mMaxGroundIdx]; if (gndChk.GetBgIndex() >= 0 && gndChk.GetBgIndex() < 0x100) { mtrlSndId = dComIfG_Bgsp()->GetMtrlSndId(gndChk); } @@ -1786,11 +1786,7 @@ namespace daObjMovebox { /* 00003D80-00003E04 .text eff_land_smoke__Q212daObjMovebox5Act_cFv */ void Act_c::eff_land_smoke() { - cXyz smokeScale; - smokeScale.setall(attr()->mLandSmokeScale); - smokeScale *= 5.0f/3.0f; - fopAcM_create(fpcNm_Obj_Eff_e, 0x3, ¤t.pos, -1, NULL, &smokeScale); - // TODO daObjEff::Act_c::make_land_smoke(cXyz*, float) + daObjEff::Act_c::make_land_smoke(¤t.pos, attr()->mLandSmokeScale); } /* 00003E04-000040D0 .text Execute__Q212daObjMovebox5Act_cFPPA3_A4_f */ @@ -1824,7 +1820,7 @@ namespace daObjMovebox { mBgc.proc_vertical(this); if (mBgc.mMaxGroundIdx >= 0) { tevStr.mRoomNo = current.roomNo; - tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(Bgc_c::M_gnd_work[mBgc.mMaxGroundIdx]); + tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(mBgc.M_gnd_work[mBgc.mMaxGroundIdx]); } if (m648 > 0) { @@ -1867,7 +1863,7 @@ namespace daObjMovebox { if (!attr()->mbCastsShadow && mBgc.mMaxGroundIdx >= 0) { int temp = mBgc.mMaxGroundIdx; f32 groundH = mBgc.mGroundY[temp]; - cM3dGPla* triPla = dComIfG_Bgsp()->GetTriPla(Bgc_c::M_gnd_work[temp]); + cM3dGPla* triPla = dComIfG_Bgsp()->GetTriPla(mBgc.M_gnd_work[temp]); cXyz* norm = triPla->GetNP(); if (norm && groundH != -G_CM3D_F_INF) { dComIfGd_setSimpleShadow(¤t.pos, groundH, attr()->m10, norm, shape_angle.y, 1.0f, NULL); @@ -1920,8 +1916,9 @@ namespace daObjMovebox { (process_method_func)Mthd_IsDelete, (process_method_func)Mthd_Draw, }; - } -} + }; // namespace + +}; // namespace daObjMovebox actor_process_profile_definition g_profile_Obj_Movebox = { /* Layer ID */ fpcLy_CURRENT_e, diff --git a/src/d/actor/d_a_windmill.cpp b/src/d/actor/d_a_windmill.cpp index 7a6a9361..05784498 100644 --- a/src/d/actor/d_a_windmill.cpp +++ b/src/d/actor/d_a_windmill.cpp @@ -220,7 +220,7 @@ void daWindMill_c::CreateInit() { if (mpBgW != NULL) { mDoMtx_stack_c::transS(current.pos); mDoMtx_stack_c::YrotM(current.angle.y); - cMtx_copy(mDoMtx_stack_c::get(), mMtx); + MTXCopy(mDoMtx_stack_c::get(), mMtx); dComIfG_Bgsp()->Regist(mpBgW, this); mpBgW->Move(); @@ -248,8 +248,8 @@ static BOOL nodeCallBack(J3DNode* node, int calcTiming) { break; } model->setAnmMtx(jntNo, mDoMtx_stack_c::get()); - cMtx_copy(mDoMtx_stack_c::get(), J3DSys::mCurrentMtx); - cMtx_copy(mDoMtx_stack_c::get(), i_this->mMtx); + MTXCopy(mDoMtx_stack_c::get(), J3DSys::mCurrentMtx); + MTXCopy(mDoMtx_stack_c::get(), i_this->mMtx); i_this->shape_angle.y = i_this->mAngle[0]; } @@ -270,7 +270,7 @@ void daWindMill_c::search_wind() { cPhs_State daWindMill_c::_create() { fopAcM_ct(this, daWindMill_c); - mType = fopAcM_GetParam(this) & 0xF; + mType = daWindMill_prm::getType(this); cPhs_State res = dComIfG_resLoad(&mPhs, m_arcname[mType]); if (res == cPhs_COMPLEATE_e) { if (!fopAcM_entrySolidHeap(this, CheckCreateHeap, m_heapsize[mType])) { @@ -284,8 +284,8 @@ cPhs_State daWindMill_c::_create() { /* 00000DC4-00000E4C .text set_mtx__12daWindMill_cFv */ void daWindMill_c::set_mtx() { mpModel->setBaseScale(scale); - mDoMtx_stack_c::transS(current.pos); - mDoMtx_stack_c::ZXYrotM(current.angle); + mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z); + mDoMtx_stack_c::ZXYrotM(current.angle.x, current.angle.y, current.angle.z); mpModel->setBaseTRMtx(mDoMtx_stack_c::get()); } @@ -357,7 +357,7 @@ void daWindMill_c::set_at() { case 1: r0 = 1000; if (mAngle[1] > r0) { - mDoMtx_stack_c::transS(current.pos); + mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z); mDoMtx_stack_c::ZXYrotM(current.angle.x, current.angle.y, mAngle[0] + mAngle[1]); mDoMtx_stack_c::multVec(&vec1, &vec1); @@ -369,8 +369,7 @@ void daWindMill_c::set_at() { m1244[i].mEnd = vec_array_0[i]; m1244[i].mRadius = 70.0f; - mCps[i].set(m1244[i].mStart, m1244[i].mEnd); - mCps[i].SetR(m1244[i].mRadius); + mCps[i].cM3dGCps::Set(m1244[i]); } for (i = 0; i < 4; i++) { @@ -381,7 +380,7 @@ void daWindMill_c::set_at() { case 0: r0 = 1000; if (mAngle[1] > r0) { - mDoMtx_stack_c::transS(current.pos); + mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z); mDoMtx_stack_c::ZXYrotM(current.angle.x, mAngle[0] + mAngle[1], current.angle.z); for (i = 0; i < 4; i++) { @@ -392,7 +391,7 @@ void daWindMill_c::set_at() { m1244[i].mEnd = vec_array_2[i]; m1244[i].mRadius = 170.0f; - mCps[i].set(m1244[i].mStart, m1244[i].mEnd); + mCps[i].SetStartEnd(m1244[i].mStart, m1244[i].mEnd); mCps[i].SetR(m1244[i].mRadius); mCps[i].SetAtSpl(dCcG_At_Spl_UNKA); } @@ -424,7 +423,7 @@ void daWindMill_c::set_co() { case 1: r0 = 1000; if (mAngle[1] <= r0) { - mDoMtx_stack_c::transS(current.pos); + mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z); mDoMtx_stack_c::ZXYrotM(current.angle.x, current.angle.y, mAngle[0] + mAngle[1]); int i; diff --git a/src/d/d_camera.cpp b/src/d/d_camera.cpp index 487eaaff..cbc9808c 100644 --- a/src/d/d_camera.cpp +++ b/src/d/d_camera.cpp @@ -4517,7 +4517,7 @@ bool dCamera_c::fixedFrameCamera(s32 param_1) { p->m39C = p->m3A8; cM3dGLin line; - line.set(p->m3A8, p->m378); + line.SetStartEnd(p->m3A8, p->m378); spF0 = attentionPos(mpPlayerActor); if (cM3d_Len3dSqPntAndSegLine(&line, &spF0, &spE4, &sp30)) { |
