652 B
652 B
ScriptFieldStorage::SetFieldValue
命名空间: XCEngine::Scripting
类型: method
头文件: XCEngine/Scripting/ScriptFieldStorage.h
签名
template<typename T>
bool SetFieldValue(const std::string& fieldName, const T& value);
bool SetFieldValue(
const std::string& fieldName,
ScriptFieldType type,
const ScriptFieldValue& value);
当前实现行为
- 模板重载会先通过
ScriptFieldTypeResolver<T>推导类型。 - 显式重载会拒绝空字段名或类型/值不兼容的输入。
- 成功时覆盖或写入对应字段。