summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhev7 <143887945+hev7@users.noreply.github.com>2025-11-24 23:30:01 +0000
committerGitHub <noreply@github.com>2025-11-24 15:30:01 -0800
commitcd3d634133040864768d9cc7364b02ce1f22e99b (patch)
tree82b2f302127be3480e2829063ae60aa8cd2b8a1f
parentc4df6a577121f3bc0c8c63a4194a55a107def255 (diff)
Link npc_guard (#2859)
-rwxr-xr-xconfigure.py2
-rw-r--r--include/d/actor/d_a_npc_guard.h10
-rw-r--r--src/d/actor/d_a_npc_guard.cpp40
3 files changed, 26 insertions, 26 deletions
diff --git a/configure.py b/configure.py
index 66ad71a133..9fe046ae89 100755
--- a/configure.py
+++ b/configure.py
@@ -1885,7 +1885,7 @@ config.libs = [
ActorRel(MatchingFor(ALL_GCN), "d_a_npc_grr"),
ActorRel(MatchingFor(ALL_GCN), "d_a_npc_grs"),
ActorRel(MatchingFor(ALL_GCN), "d_a_npc_grz"),
- ActorRel(NonMatching, "d_a_npc_guard"),
+ ActorRel(MatchingFor(ALL_GCN), "d_a_npc_guard"),
ActorRel(MatchingFor(ALL_GCN), "d_a_npc_gwolf"),
ActorRel(MatchingFor(ALL_GCN), "d_a_npc_hanjo"),
ActorRel(MatchingFor(ALL_GCN, "Shield"), "d_a_npc_henna0"),
diff --git a/include/d/actor/d_a_npc_guard.h b/include/d/actor/d_a_npc_guard.h
index 14f497f99a..9996215be2 100644
--- a/include/d/actor/d_a_npc_guard.h
+++ b/include/d/actor/d_a_npc_guard.h
@@ -44,13 +44,13 @@ public:
/* 809F0A50 */ void initEscape();
/* 809F0B20 */ void executeEscape();
/* 809F0DD4 */ void setAngle();
- /* 809F0DE0 */ void setSpeed(f32, f32, f32*, int);
+ /* 809F0DE0 */ inline void setSpeed(f32, f32, f32*, int);
/* 809F0ED4 */ void pathMoveF();
/* 809F12F0 */ int create();
- /* 809F14CC */ void create_init();
- /* 809F17D0 */ void setMtx();
- /* 809F1878 */ void lookat();
- /* 809F1F74 */ virtual ~daNpcGuard_c();
+ /* 809F14CC */ inline void create_init();
+ /* 809F17D0 */ inline void setMtx();
+ /* 809F1878 */ inline void lookat();
+ /* 809F1F74 */ inline virtual ~daNpcGuard_c();
/* 809F2044 */ int execute();
inline int createHeap();
diff --git a/src/d/actor/d_a_npc_guard.cpp b/src/d/actor/d_a_npc_guard.cpp
index c781941ade..dc5ff601c7 100644
--- a/src/d/actor/d_a_npc_guard.cpp
+++ b/src/d/actor/d_a_npc_guard.cpp
@@ -336,7 +336,7 @@ void daNpcGuard_c::setAngle() {
}
/* 809F0DE0-809F0ED4 001100 00F4+00 1/1 0/0 0/0 .text setSpeed__12daNpcGuard_cFffPfi */
-inline void daNpcGuard_c::setSpeed(f32 param_1, f32 param_2, f32* i_speed, int param_4) {
+void daNpcGuard_c::setSpeed(f32 param_1, f32 param_2, f32* i_speed, int param_4) {
f32 target = field_0xd8c * (param_2 * field_0xd8c);
f32 step = field_0xd8c * (param_1 * field_0xd8c);
@@ -410,25 +410,6 @@ static int daNpcGuard_Create(void* i_this) {
return static_cast<daNpcGuard_c*>(i_this)->create();
}
-/* 809F12F0-809F14CC 001610 01DC+00 1/1 0/0 0/0 .text create__12daNpcGuard_cFv */
-int daNpcGuard_c::create() {
- fopAcM_ct(this, daNpcGuard_c);
-
- m_type = cLib_getRndValue(0, 2);
- mObjNum = 2;
- int phase = loadResrc(m_type, mObjNum);
- if (phase == cPhs_COMPLEATE_e) {
- if (!fopAcM_entrySolidHeap(this, createHeapCallBack, 0x2220)) {
- // Failed to create actor!
- OS_REPORT("アクター生成失敗しました!\n");
- return cPhs_ERROR_e;
- }
- create_init();
- }
-
- return phase;
-}
-
void daNpcGuard_c::initCollision() {
dCcD_SrcSph sph = {
{
@@ -543,6 +524,25 @@ void daNpcGuard_c::lookat() {
mLookat.action(cStack_80, eyePos, this, afStack_38, NULL != mActorMngr.getActorP());
}
+/* 809F12F0-809F14CC 001610 01DC+00 1/1 0/0 0/0 .text create__12daNpcGuard_cFv */
+int daNpcGuard_c::create() {
+ fopAcM_ct(this, daNpcGuard_c);
+
+ m_type = cLib_getRndValue(0, 2);
+ mObjNum = 2;
+ int phase = loadResrc(m_type, mObjNum);
+ if (phase == cPhs_COMPLEATE_e) {
+ if (!fopAcM_entrySolidHeap(this, createHeapCallBack, 0x2220)) {
+ // Failed to create actor!
+ OS_REPORT("アクター生成失敗しました!\n");
+ return cPhs_ERROR_e;
+ }
+ create_init();
+ }
+
+ return phase;
+}
+
/* 809F1F40-809F1F74 002260 0034+00 1/0 0/0 0/0 .text daNpcGuard_Delete__FPv */
static int daNpcGuard_Delete(void* i_this) {
static_cast<daNpcGuard_c*>(i_this)->~daNpcGuard_c();