summaryrefslogtreecommitdiff
path: root/src/KingSystem/Resource/Actor/resResourceAIProgram.cpp
diff options
context:
space:
mode:
authorLéo Lam <leo@leolam.fr>2022-02-27 12:48:28 +0100
committerLéo Lam <leo@leolam.fr>2022-02-27 12:50:52 +0100
commitdf36d656650198b3cbf140e2982752a95b3f2c6d (patch)
tree1af53905980b13aa03ab2f78dd548407370eb98c /src/KingSystem/Resource/Actor/resResourceAIProgram.cpp
parenta5641860025aed373da045ef1ac43a6487529932 (diff)
Revert "Add #ifdef declarations for NON_MATCHING code"
This reverts commit 42807160cfb33af9f3cf2fa6b0ba98f232208cdb. It makes searching for NON_MATCHING comment descriptions much less convenient in most text editors or IDEs, and we want the function CSV to be the single source of truth for function statuses. Having a function marked as matching but not built because of a stray #ifdef would be bad.
Diffstat (limited to 'src/KingSystem/Resource/Actor/resResourceAIProgram.cpp')
-rw-r--r--src/KingSystem/Resource/Actor/resResourceAIProgram.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/KingSystem/Resource/Actor/resResourceAIProgram.cpp b/src/KingSystem/Resource/Actor/resResourceAIProgram.cpp
index 01dee2ab..4900aa20 100644
--- a/src/KingSystem/Resource/Actor/resResourceAIProgram.cpp
+++ b/src/KingSystem/Resource/Actor/resResourceAIProgram.cpp
@@ -68,8 +68,7 @@ static bool parseBehaviorIdx(agl::utl::ResParameterObj obj, sead::Buffer<u8>& bu
return true;
}
-// the parameter iteration loops in parseAIActionIdx and parseBehaviorIdx
-#ifdef NON_MATCHING
+// NON_MATCHING: the parameter iteration loops in parseAIActionIdx and parseBehaviorIdx
bool AIProgram::parse_(u8* data, size_t, sead::Heap* parent_heap) {
if (data) {
auto* heap = util::tryCreateDualHeap(parent_heap);
@@ -107,10 +106,8 @@ bool AIProgram::parse_(u8* data, size_t, sead::Heap* parent_heap) {
mHeap->adjust();
return true;
}
-#endif
-// the parameter iteration loops in parseAIActionIdx and parseBehaviorIdx
-#ifdef NON_MATCHING
+// NON_MATCHING: the parameter iteration loops in parseAIActionIdx and parseBehaviorIdx
bool AIProgram::parseAIActions(sead::Buffer<AIActionDef>& defs, sead::Heap* heap,
agl::utl::ParameterList& target_list,
const agl::utl::ResParameterList& root, const char* type_name) {
@@ -173,7 +170,6 @@ bool AIProgram::parseAIActions(sead::Buffer<AIActionDef>& defs, sead::Heap* heap
addList(&target_list, type_name);
return true;
}
-#endif
bool AIProgram::parseBehaviors(sead::Heap* heap, const agl::utl::ResParameterList& root) {
const auto list = agl::utl::getResParameterList(root, "Behavior");