16#include <unordered_set>
87 std::pair<entt::registry*, entt::entity>
getEntityFromJS(FCT::NodeEnvironment& env);
A header file containing third party libraries and macros for platform
#define ENGINE_API
定义 EnginePCH.h:14
void registerEntityFunctions()
定义 ScriptSystem.cpp:333
v8::Local< v8::Value > convertComponentValueToJS(const ComponentValue &value)
定义 ScriptSystem.cpp:308
void start()
执行所有OnStart类型的脚本
定义 ScriptSystem.cpp:204
void cleanUp()
清理已启动的实体记录
定义 ScriptSystem.cpp:234
DataManager * m_dataManager
定义 ScriptSystem.h:59
std::unique_ptr< ComponentReflection > m_componentReflection
定义 ScriptSystem.h:61
void setLogicDeltaTime(float deltaTime)
设置逻辑帧时间间隔
定义 ScriptSystem.cpp:147
ScriptSystem()
定义 ScriptSystem.cpp:11
std::vector< std::string > getFunctionNames() const
获取当前JavaScript环境中的所有函数名
定义 ScriptSystem.cpp:134
std::pair< entt::registry *, entt::entity > getEntityFromJS(FCT::NodeEnvironment &env)
定义 ScriptSystem.cpp:287
std::vector< std::string > loadJSFilesFromDirectory(const std::string &directory)
定义 ScriptSystem.cpp:79
float m_logicDeltaTime
定义 ScriptSystem.h:62
std::unordered_set< entt::entity > m_startedEntities
定义 ScriptSystem.h:63
std::unique_ptr< FCT::NodeEnvironment > m_nodeEnv
定义 ScriptSystem.h:60
ComponentValue convertJSObjectToComponentValue(const std::string &fieldType, FCT::JSAny &jsAny, const std::string &fieldName)
通用类型转换函数:从JSObject转换为ComponentValue
定义 ScriptSystem.cpp:239
void update()
更新系统,执行所有Ticker类型的脚本
定义 ScriptSystem.cpp:161
std::string readFileContent(const std::string &filePath)
读取文件内容
定义 ScriptSystem.cpp:106
void loadScripts()
加载并执行JavaScript脚本文件
定义 ScriptSystem.cpp:29
Entrypoint for the program.
定义 application.h:5
std::variant< bool, int, float, double, std::string, FCT::Vec3 > ComponentValue
定义 ComponentReflection.h:18