FVisualScriptLinkedProgram
A program bound to the live classes: what the interpreter runs. Native names that carry their own class ("AActorStatics::Spawn") are resolved once here; anything resolved against the running instance's class stays a runtime lookup. The resolutions point into MClass tables that a module reload frees, so the program is relinked (a new object around the same bytes) whenever either class registry's revision moves.
- Module
- VisualScripting
- Header
#include "VisualScripting/VisualScriptProgram.h"- Namespace
Mowo
Properties
| Type | Name | Description |
|---|---|---|
std::shared_ptr<const FVisualScriptProgram> | program | |
uint64_t | revision | Default 0. |
std::vector<FNative> | natives | By link index; only Native links with a qualified name resolve here. |
std::unordered_map<std::string, uint32_t> | events | |
std::unordered_map<std::string, uint32_t> | functions | |
std::vector<std::string> | scopeNames | |
mutable std::vector<std::vector<uint64_t>> | nodeHits |
Public functions
| Returns | Name | Description |
|---|---|---|
std::shared_ptr<const FVisualScriptLinkedProgram> | Link | className names the profiler zones ("VS <Class>::<Function>"); previous, when the program is relinked, hands over the node heat so a registry revision does not zero it. |
bool | IsCurrent | False once a class registered, unregistered or was rebuilt since this was linked. |
const FVisualScriptFunctionCode* | FindCode | The code of the named event graph or function, null when the program has none. |
const char* | ScopeName | The profiler zone name of function code of this program. |
uint64_t* | NodeHits | The instruction count per source-map entry of code, sized on first use; counted only while vs.ProfileNodes is on. |
Function details
Link
static std::shared_ptr<const FVisualScriptLinkedProgram> Link(std::shared_ptr<const FVisualScriptProgram> program, const std::string& className = std::string(), const FVisualScriptLinkedProgram* previous = nullptr)className names the profiler zones ("VS <Class>::<Function>"); previous, when the program is relinked, hands over the node heat so a registry revision does not zero it.
IsCurrent
bool IsCurrent() constFalse once a class registered, unregistered or was rebuilt since this was linked.
FindCode
const FVisualScriptFunctionCode* FindCode(const std::string& name, bool isEvent) constThe code of the named event graph or function, null when the program has none.
ScopeName
const char* ScopeName(const FVisualScriptFunctionCode& code) constThe profiler zone name of function code of this program.
NodeHits
uint64_t* NodeHits(const FVisualScriptFunctionCode& code) constThe instruction count per source-map entry of code, sized on first use; counted only while vs.ProfileNodes is on. Mutable: counting is bookkeeping on a program that is otherwise shared and read-only.