Key Nodes
The nodes you will actually use, grouped by what you are trying to do. There are hundreds of nodes in the palette; these are the two dozen that appear in almost every script.
Node titles in the palette often contain {...} placeholders — these are filled in
from the node's own settings. Get {Name} shows as Get pushforce once you set its
Name property.
React to something
Every script starts at an entry point. These have an outgoing execution pin but no incoming one. See Entry Points and Events for the full set.
| Node | Fires |
|---|---|
OnSimulationStarted | Once, when the scene starts simulating |
Update | Once per frame |
On<Message> | When that message reaches this object — e.g. OnMsgTriggerTriggered |
Store and read values
Add variables in the script's properties panel first (deselect all nodes to see them). Tick Expose to make a variable editable per-instance in the editor.
| Node | Title | What it does |
|---|---|---|
GetVariable | Get {Name} | Reads a variable. No execution pin — evaluated when needed |
SetVariable | Set {Name} = {Value} | Writes a variable |
IncVariable | ++ {Name} | Adds one |
DecVariable | -- {Name} | Subtracts one |
Make a decision
| Node | Title | What it does |
|---|---|---|
Branch | — | The if node. One Condition input, True and False execution outputs |
Compare | {A} {Operator} {B} | Compares two values, outputs a bool. Operator is equal, not equal, less, less-equal, greater, greater-equal |
CompareExec | {A} {Operator} {B} | Compare and branch in one node — True / False execution outputs |
Select | {Condition} ? {A} : {B} | Picks one of two values without branching execution |
IsValid | — | True if the incoming object or component still exists. Use before acting on anything you looked up |
SwitchString | Switch | Multi-way branch on text. One execution output per case, plus Default |
SwitchInt64 | Switch | Same, on whole numbers |
And / Or / Not | {A} AND {B} etc. | Boolean logic |
Branch needs a separate Compare feeding it. If you are only
comparing two values and branching, CompareExec does both in one node.
Repeat something
All loop nodes have two execution outputs: LoopBody, which runs once per iteration, and Completed, which runs once at the end.
| Node | Title | Inputs / outputs |
|---|---|---|
ForLoop | ForLoop [{FirstIndex}..{LastIndex}] | Counts between two numbers. Outputs the current Index |
WhileLoop | — | Repeats while Condition is true |
ForEachLoop | — | Walks an array. Outputs Element and Index |
ReverseForEachLoop | — | The same, backwards |
Break | — | Leaves the loop early |
A While loop with a condition that never becomes false will hang the frame. If a
loop might run long, put a Yield in its body so it spreads across frames.
Wait, and do things over time
| Node | What it does |
|---|---|
Yield | Pauses here, resumes next frame |
StartCoroutine | Starts a separate execution path that can outlive this frame |
StopCoroutine | Stops one, by ID or by name |
StopAllCoroutines | Stops all of this script's coroutines |
WaitForAny | Waits until any one of up to 16 coroutines finishes |
WaitForAll | Waits until all of them finish |
Anything that waits turns its execution path into a coroutine. The entry point node shows a crossed-arrows icon when that happens.
Work with objects and components
| Node | Title | What it does |
|---|---|---|
TryGetComponentOfBaseType | TryGet {TypeName} | Finds a component on an object. Returns nothing if there isn't one — pair with IsValid |
GetProperty | Get {Property} | Reads a property from a component |
SetProperty | Set {Property} = {Value} | Writes a property on a component |
GetGlobalPosition | — | Where an object is in the world |
FindChildByName | — | Finds a child object by name |
GetProperty and SetProperty pick their type and property in the property grid,
not through pins, so the node knows what kind of value to expect.
Tell something else to do something
Message nodes are generated from every message type in the project, so the exact list depends on what your project loads.
| Pattern | Example | What it does |
|---|---|---|
Send<Message> | SendMsgPhysicsAddForce | Sends a message. Set the target with the GameObject or Component input |
On<Message> | OnMsgTriggerTriggered | Entry point — runs when that message arrives |
Every Send node has a Send Mode setting:
- Direct — deliver to the target object's components only.
- Recursive — also deliver to all of its children.
- Event — deliver upwards, to the nearest parent that handles this message.
It also has a Delay, so you can send something a second from now without a coroutine.
Maths
| Node | Title |
|---|---|
Add | {A} + {B} |
Subtract | {A} - {B} |
Multiply | {A} * {B} |
Divide | {A} / {B} |
Expression | {Expression} — a written formula with as many inputs and outputs as you define |
These work on numbers and on vectors. Leave an input pin unconnected to type a constant into the property grid instead — that is how the jump pad scales its force.
Text, logging and seeing what happened
| Node | What it does |
|---|---|
String_Format | Format {Text} — builds text from a pattern like Hit: {0} with as many parameters as you add |
Draw3DText | Prints text in the world |
DrawLine | Draws a line between two points |
DrawCross | Marks a point in space |
Info / Warning / Error | Writes to the log |
Debug drawing is the fastest way to find out why a script is not doing what you expect. See the raycast recipe for the pattern.
Convert between types
Most number types convert automatically, and almost anything converts to text. You need explicit conversion mainly when handling a Variant — a value whose type is not known ahead of time.
| Node | What it does |
|---|---|
ToFloat, ToInt, ToBool, ToString, … | Convert to a specific type |
Variant_ConvertTo | ConvertTo {Type} — converts a Variant, with Succeeded and Failed execution outputs |
Variant_ConvertTo is the only conversion node that can fail visibly, which
is why it branches. The rest convert silently.
Working with arrays
Thirteen array nodes exist. The ones worth knowing:
| Node | What it does |
|---|---|
MakeArray | Builds an array from a list of values |
GetCount | How many elements |
IsEmpty | True if empty |
Array_GetElement | GetElement[{Index}] |
PushBack | Appends an element |
Array_Contains | Contains {Element} |
Pair them with ForEachLoop to walk the contents.
See Also
- Entry Points and Events — how scripts start
- Reading the Palette — why your node list differs from someone else's
- Recipes — these nodes in working scripts