From 06ebff75181821e22ba83931a8494343a96d1e96 Mon Sep 17 00:00:00 2001 From: Serhii Snitsaruk Date: Tue, 12 Mar 2024 21:09:28 +0100 Subject: [PATCH] Fix includes and build errors --- blackboard/blackboard_plan.cpp | 5 +++-- bt/bt_state.cpp | 3 --- hsm/limbo_hsm.cpp | 10 ---------- hsm/limbo_state.cpp | 8 +------- hsm/limbo_state.h | 7 ------- 5 files changed, 4 insertions(+), 29 deletions(-) diff --git a/blackboard/blackboard_plan.cpp b/blackboard/blackboard_plan.cpp index 8bde5c9..6d8b723 100644 --- a/blackboard/blackboard_plan.cpp +++ b/blackboard/blackboard_plan.cpp @@ -276,13 +276,14 @@ void BlackboardPlan::sync_with_base_plan() { List>::Element *B = base->var_list.front(); for (List>::Element *E = var_list.front(); E; E = E->next()) { if (E->get().first != B->get().first) { - List>::Element *F = E; - while ((F = F->next())) { + List>::Element *F = E->next(); + while (F) { if (F->get().first == B->get().first) { var_list.move_before(F, E); E = F; break; } + F = F->next(); } } B = B->next(); diff --git a/bt/bt_state.cpp b/bt/bt_state.cpp index 84f1d7c..749762f 100644 --- a/bt/bt_state.cpp +++ b/bt/bt_state.cpp @@ -17,9 +17,6 @@ #ifdef LIMBOAI_MODULE #include "core/debugger/engine_debugger.h" -#include "core/error/error_macros.h" -#include "core/object/class_db.h" -#include "core/variant/variant.h" #endif // LIMBOAI_MODULE #ifdef LIMBOAI_GDEXTENSION diff --git a/hsm/limbo_hsm.cpp b/hsm/limbo_hsm.cpp index a33c2c6..e97bd56 100644 --- a/hsm/limbo_hsm.cpp +++ b/hsm/limbo_hsm.cpp @@ -11,16 +11,6 @@ #include "limbo_hsm.h" -#ifdef LIMBOAI_MODULE -#include "core/config/engine.h" -#include "core/error/error_macros.h" -#include "core/object/class_db.h" -#include "core/object/object.h" -#include "core/typedefs.h" -#include "core/variant/callable.h" -#include "core/variant/variant.h" -#endif // LIMBOAI_MODULE - VARIANT_ENUM_CAST(LimboHSM::UpdateMode); void LimboHSM::set_active(bool p_active) { diff --git a/hsm/limbo_state.cpp b/hsm/limbo_state.cpp index 4fa3df8..882530d 100644 --- a/hsm/limbo_state.cpp +++ b/hsm/limbo_state.cpp @@ -14,16 +14,10 @@ #include "../util/limbo_compat.h" #ifdef LIMBOAI_MODULE -#include "core/error/error_macros.h" -#include "core/object/class_db.h" -#include "core/object/object.h" -#include "core/typedefs.h" -#include "core/variant/array.h" -#include "core/variant/callable.h" -#include "core/variant/variant.h" #endif // LIMBOAI_MODULE #ifdef LIMBOAI_GDEXTENSION +#include #endif void LimboState::set_blackboard_plan(const Ref &p_plan) { diff --git a/hsm/limbo_state.h b/hsm/limbo_state.h index 79f68ec..706045e 100644 --- a/hsm/limbo_state.h +++ b/hsm/limbo_state.h @@ -19,13 +19,6 @@ #include "../util/limbo_string_names.h" #ifdef LIMBOAI_MODULE -#include "core/object/gdvirtual.gen.inc" -#include "core/object/object.h" -#include "core/string/string_name.h" -#include "core/string/ustring.h" -#include "core/templates/hash_map.h" -#include "core/variant/callable.h" -#include "core/variant/variant.h" #include "scene/main/node.h" #endif // LIMBOAI_MODULE