refactor(component): movement AI reads its attached path in LoadConfigData

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aaron Kimbrell
2026-10-01 08:12:32 -05:00
parent 3d1f7cecb8
commit 14a11ac6ce
2 changed files with 5 additions and 0 deletions

View File

@@ -70,7 +70,10 @@ MovementAIComponent::MovementAIComponent(Entity* parent, const int32_t component
m_IsBounced = false;
RegisterMsg(&MovementAIComponent::OnGetObjectReportInfo);
}
// The level config: the attached path
void MovementAIComponent::LoadConfigData() {
SetPath(m_Parent->GetVarAsString(u"attached_path"));
}

View File

@@ -66,6 +66,8 @@ public:
MovementAIComponent(Entity* parentEntity, const int32_t componentID, MovementAIInfo info);
void LoadConfigData() override;
void SetPath(const std::string pathName);
void Run(float deltaTime) override;