11#include "../NodeGraphCore/GlobalTemplateBlackboard.h"
33 default:
return "None";
47 for (
size_t i = 0;
i <
tmpl.Blackboard.size(); ++
i)
50 if (
entry.Key.empty())
63 const std::vector<GlobalEntryDefinition>&
globalVars =
gtb.GetAllVariables();
92 return a.name < b.name;
103 std::vector<VarSpec> result;
104 for (
size_t i = 0;
i <
m_vars.size(); ++
i)
114 std::vector<VarSpec> result;
115 for (
size_t i = 0;
i <
m_vars.size(); ++
i)
125 std::vector<VarSpec> result;
126 for (
size_t i = 0;
i <
m_vars.size(); ++
i)
140 (isGlobal ?
"global" :
"local") +
")";
145 for (
size_t i = 0;
i <
m_vars.size(); ++
i)
Wrapper around the graph blackboard entries for dropdown editors.
ComponentTypeID GetComponentTypeID_Static()
std::vector< VarSpec > GetVariablesByType(VariableType type) const
Returns variables whose type matches type, sorted by name.
std::vector< VarSpec > m_vars
std::vector< VarSpec > GetGlobalVariables() const
Returns only global-scope variables.
void LoadFromTemplate(const TaskGraphTemplate &tmpl)
Rebuilds the registry from the blackboard entries of a template.
static std::string FormatDisplayLabel(const std::string &name, VariableType type, bool isGlobal)
Formats a display label for a variable.
const std::vector< VarSpec > & GetAllVariables() const
Returns all variables (local and global), sorted by name.
size_t GetCount() const
Returns the number of registered variables.
bool HasVariable(const std::string &name) const
Returns true if a variable with the given name is registered.
std::vector< VarSpec > GetLocalVariables() const
Returns only local-scope variables.
static GlobalTemplateBlackboard & Get()
Immutable, shareable task graph asset.
< Provides AssetID and INVALID_ASSET_ID
VariableType
Type tags used by TaskValue to identify stored data.
@ Int
32-bit signed integer
@ Float
Single-precision float.
@ GlobalRef
Reference to a global blackboard key (scope "global:")
@ List
std::vector<TaskValue> (used by ForEach node)
@ Vector
3-component vector (Vector from vector.h)
@ EntityID
Entity identifier (uint64_t)
static const char * VariableTypeName(VariableType t)
Single entry in the graph's declared blackboard schema (local or global).
Metadata for a single blackboard variable entry.
std::string name
Variable key (e.g. "health", "target")