refactor(behavior-tree)!: 迁移到 Runtime 执行器架构 (#196)

* refactor(behavior-tree)!: 迁移到 Runtime 执行器架构

* fix(behavior-tree): 修复LogAction中的ReDoS安全漏洞

* feat(behavior-tree): 完善行为树核心功能并修复类型错误
This commit is contained in:
YHH
2025-10-31 17:27:38 +08:00
committed by GitHub
parent c58e3411fd
commit 61813e67b6
113 changed files with 7795 additions and 10564 deletions

View File

@@ -1,92 +1,29 @@
/**
* @esengine/behavior-tree
*
* 完全ECS化的行为树系统
* 行为树系统
*
* @packageDocumentation
*/
// 注册所有内置节点
import './RegisterAllNodes';
// 类型定义
export * from './Types/TaskStatus';
// 基础组件
export * from './Components/BehaviorTreeNode';
export * from './Components/BlackboardComponent';
export * from './Components/CompositeNodeComponent';
export * from './Components/DecoratorNodeComponent';
export * from './Components/ActiveNode';
export * from './Components/PropertyBindings';
export * from './Components/LogOutput';
export * from './Components/AssetMetadata';
// 动作组件
export * from './Components/Actions/WaitAction';
export * from './Components/Actions/LogAction';
export * from './Components/Actions/SetBlackboardValueAction';
export * from './Components/Actions/ModifyBlackboardValueAction';
export * from './Components/Actions/ExecuteAction';
// 条件组件
export * from './Components/Conditions/BlackboardCompareCondition';
export * from './Components/Conditions/BlackboardExistsCondition';
export * from './Components/Conditions/RandomProbabilityCondition';
export * from './Components/Conditions/ExecuteCondition';
// 组合节点
export * from './Components/Composites/RootNode';
export * from './Components/Composites/SequenceNode';
export * from './Components/Composites/SelectorNode';
export * from './Components/Composites/ParallelNode';
export * from './Components/Composites/ParallelSelectorNode';
export * from './Components/Composites/RandomSequenceNode';
export * from './Components/Composites/RandomSelectorNode';
export * from './Components/Composites/SubTreeNode';
// 装饰器节点
export * from './Components/Decorators/InverterNode';
export * from './Components/Decorators/RepeaterNode';
export * from './Components/Decorators/UntilSuccessNode';
export * from './Components/Decorators/UntilFailNode';
export * from './Components/Decorators/AlwaysSucceedNode';
export * from './Components/Decorators/AlwaysFailNode';
export * from './Components/Decorators/ConditionalNode';
export * from './Components/Decorators/CooldownNode';
export * from './Components/Decorators/TimeoutNode';
// 系统
export * from './Systems/RootExecutionSystem';
export * from './Systems/LeafExecutionSystem';
export * from './Systems/DecoratorExecutionSystem';
export * from './Systems/CompositeExecutionSystem';
export * from './Systems/SubTreeExecutionSystem';
// 服务
export * from './Services/GlobalBlackboardService';
export * from './Services/WorkspaceService';
export * from './Services/IAssetLoader';
export * from './Services/FileSystemAssetLoader';
export * from './Services/AssetLoadingManager';
export * from './Services/AssetLoadingTypes';
// 插件
export * from './BehaviorTreePlugin';
// Runtime
export * from './Runtime';
// 辅助工具
export * from './BehaviorTreeStarter';
export * from './BehaviorTreeBuilder';
// 序列化(编辑器支持)
export * from './Serialization/BehaviorTreePersistence';
// 序列化
export * from './Serialization/NodeTemplates';
// 资产系统(运行时)
export * from './Serialization/BehaviorTreeAsset';
export * from './Serialization/BehaviorTreeAssetSerializer';
export * from './Serialization/BehaviorTreeAssetLoader';
export * from './Serialization/EditorFormatConverter';
export * from './Serialization/BehaviorTreeAssetSerializer';
// 装饰器(扩展支持)
export * from './Decorators/BehaviorNodeDecorator';
// 服务
export * from './Services/GlobalBlackboardService';
// 插件
export * from './BehaviorTreePlugin';