Welcome to the Visual Programming Nodes tutorial. This guide will walk you through the functionality and usage of each node available in the system. Each section includes a description, step-by-step instructions to help you understand the node's purpose and implementation.
List of Nodes (details found after)
- Utils
- Bypass
- Watch
- Basic
- Boolean
- Number
- String
- Data Store
- Time
- Events
- Branch
- Counter
- Delay
- Sequence
- Stepper
- Trigger
- Animation Frame
- History Log Event
- Milestone Change
- Scenario Start
- Slide Change
- Timer
- Logic
- AND
- Branch
- Boolean Compare
- Gate
- NOT
- OR
- Selector
- String Compare
- Math3D
- Vec3 Add
- Vec3 Scale
- Vec3 Length
- Vec3 Normalize
- Vec3 Lerp
- Vec3 Dot
- Vec3 Cross
- Vec2 to XY
- XY to Vec2
- Vec3 to XYZ
- XYZ to Vec3
- Vec4 to XYZW
- XYZW to Vec4
- Math
- Abs
- Accumulate
- Average
- Bitwise
- Branch
- Clamp
- Compare
- Condition
- Frac
- Floor
- Lerp
- Noise
- Operation
- Random
- Range
- Round
- Scale
- Smoothstep
- Spikes
- Tend to
- Trigonometry
- UI
- Button
- Combo
- Knob
- Number
- Progress
- Toggle
- Slider
- Switch
- Tutorial Modal
- Animation
- Animate Bone
- Move Camera
- Reframe Camera
- Timeline
- Value Transition
- Camera Unlock/Lock
- Color
- HSL Color
- Random Color
- RGB Color
- Inputs
- Number Input
- Section
- Section Cut
- Material
- Set Material Values
- Resource
- Get Scene Curves
- Get Scene Curves Rear Node
- Get Scene Curves Successive Node
- Bone Nodes
- Get Bone Values
- Play Animation Clip
- Select AnimationClip
- Select Bone
- Set Bone Values
- Object Nodes
- Get Object Values
- Select Object
- Set Object Values
- Material Nodes
- Select Material
- Others
- SIN()
- COS()
- TAN()
- MIN()
- MAX()
- ==
- !=
- >
- <
- >=
- <=
Utils
Bypass
Purpose: Pass any incoming value directly to the output without modification. Use it to simplify wiring or to temporarily skip a transformation node while keeping graph connections intact.
Inputs: in (any type)
Outputs: out (same value and type received on in)
Usage: Drop a Bypass node between two nodes when you want to preserve a connection but disable an intermediate processing step. This is helpful during troubleshooting—replace a complex node with Bypass to verify upstream values.
Example Steps:
- Connect a data-producing node (e.g., Time) to in.
- Connect out to the downstream consumer.
- Observe identical values before and after the Bypass to confirm integrity.
Watch
Purpose: Inspect and live-display the current value passing through a connection for debugging or monitoring.
Input: value (any type)
Display Logic: Numbers are formatted to 3 decimals; arrays are recursively expanded and comma-separated; dates are serialized to ISO string; null shows as null.
Usage: Insert a Watch node anywhere you need to confirm runtime values—especially before conditional logic or vector math.
Steps:
- Connect a data-producing node to value.
- Run the graph: the port label updates continuously.
- Collapse the node to show just the formatted value as the title for space efficiency.
Basic
Boolean
Purpose: Emit a constant boolean value you can toggle in the editor interface.
Outputs: value (true/false)
Properties: value (click to toggle). Collapsed title shows current state for quick scanning.
Usage: Use as a manual switch for enabling branches, triggering events, or gating numeric flows via Gate or Condition nodes.
Number
Purpose: Provide a constant numeric value adjustable via a numeric widget.
Outputs: value (number)
Properties: value (editable; widget stays synced). Collapsed: displays raw number.
Usage: Use for static parameters (scale factors, thresholds) or as a temporary stand‑in while prototyping dynamic inputs.
Tip: Pair with a Watch node downstream to verify transformations.
String
Purpose: Emit a constant string literal for labels, IDs, or matching operations.
Outputs: value (string)
Properties: value text field. Collapsed title shows current string.
Usage: Feed into String Compare or UI nodes that expect message/context values.
Data Store
Purpose: Persist a snapshot of incoming data until explicitly updated by an event. Ideal for holding configuration or last-known state.
Inputs: data (any), assign (event)
Outputs: data (stored value)
Properties: data (initial value), serialize (whether to include value when saving/exporting). Button widget triggers assign.
Behavior: Value only updates when an assign action fires (button press or incoming event). During graph execution data output remains stable.
Usage Pattern:
- Connect a dynamic source (e.g., Time or Random) to data.
- Trigger assign (button or external event) when you want to freeze the current value.
- Downstream nodes receive the stored snapshot rather than continuous changes.
Tutorial – Capturing a Timed Value:
- Add a Time node and a Data Store node.
- Connect Time.sec to Data Store.data.
- Run the graph. Seconds increase, but Data Store output stays at initial value.
- Press the Data Store’s store button to capture the current second.
- Observe downstream Watch node: value updates only on capture.
Time
Purpose: Provide elapsed graph execution time in milliseconds and seconds for driving animations, periodic sampling, or temporal logic.
Outputs: ms (milliseconds), sec (seconds)
Behavior: Reads graph.globaltime each execute cycle and scales appropriately.
Usage Examples:
- Feed sec into Trigonometry for smooth sine-based oscillations.
- Use ms with a Range node to map time to a 0–1 progression.
- Combine with Data Store to capture a timestamp event.
Events
Branch
Purpose: Route an incoming action (event) to one of two outputs based on a boolean condition sampled at trigger time.
Inputs: in (event), condition (boolean)
Outputs: true (event), false (event)
Behavior: On receiving in, Branch reads the latest condition value and triggers exactly one output. If condition is undefined it defaults to false.
Usage: Use to split an event flow (e.g., camera actions vs logging) based on user toggle or comparison result.
Counter
Purpose: Maintain and expose a running integer count updated by increment, decrement, or reset events.
Inputs (events): inc, dec, reset
Outputs: change (event fired when count changes), num (number, current count)
Behavior: Each incoming event mutates internal counter then emits change if the value changed. Collapsed title displays current value.
Usage Examples: Drive a Stepper index, throttle actions, or accumulate user interactions.
Tutorial – Building a Pulse Divider:
- Add Animation Frame (tick every frame) feeding Counter.inc.
- Connect Counter.num to a Modulo Operation (or Math Operation with %) to detect every Nth frame.
- Branch on result == 0 to fire a periodic event.
Delay
Purpose: Defer firing of an event for a specified milliseconds interval; supports cancellation.
Inputs (events): trigger, cancel
Properties: time(ms) delay duration (default 1000).
Outputs: finished (event fired after delay), cancelled (event when cancelled)
Behavior: Each trigger schedules a pending execution; elapsed time is accumulated each frame. Cancel clears all pending tasks.
Usage Tips: Chain multiple Delay nodes for staged sequences; pair with Timer to build repeating offset events.
Tutorial – Creating a Staggered Action Chain:
- Add a Trigger node controlling start.
- Connect Trigger.true to first Delay (time=500).
- Connect first Delay.finished to second Delay (time=1000).
- Second Delay.finished fires final action (e.g., Move Camera).
Sequence
Purpose: Fan out a single incoming event to a set of numbered outputs (0..N-1) in the same frame.
Inputs: Dynamically created numbered action inputs (initially 0..5).
Outputs: Matching numbered event outputs triggered sequentially.
Behavior: When any input receives an event, Sequence triggers all outputs in index order. Plus (+) / minus (-) buttons add or remove paired input/output slots.
Usage: Use to broadcast a single start signal to multiple independent chains or to guarantee deterministic ordering.
Tutorial – Coordinated Multi-Start:
- Connect a Scenario Start event to Sequence input 0.
- Use output 0 for camera initialization, 1 for material setup, 2 for color randomization.
- Add outputs (+) as new initialization subsystems grow.
Stepper
Purpose: Emit events one slot at a time in cyclic order, tracking current index; also exposes numeric index output.
Inputs: index (number to jump directly), step (advance one), reset (return to 0)
Outputs: index (current index number), numbered event outputs (0..N-1) plus highlighted arrow showing active slot.
Behavior: On step, triggers current slot then increments. If an index input changes, Stepper jumps and fires that slot immediately. Dynamic (+/-) buttons add/remove event outputs; internal index is clamped.
Usage: Drive staged animations, slide progression, or timed resource loading.
Tutorial – Driving a Timeline:
- Add a Timer node (interval 2000ms) feeding step.
- Connect each Stepper output (0,1,2,3...) to different camera positions or material transitions.
- Use a Toggle gating the Timer.enabled input to pause progression.
- Connect a Button to reset for manual restart.
Trigger
Purpose: Observe a boolean input and emit events on the transition or state, providing separate outputs for true, false, and change.
Input: if (boolean)
Outputs: true (fires when value is true and resend rules allow), false, change (fires only when value flips)
Property: only_on_change (default true) – if enabled, suppress repeated firing unless value changed.
Behavior: First evaluation initializes without emitting state outputs; subsequent changes drive events.
Usage: Convert continuous boolean signals into discrete event triggers for downstream sequencing or delays.
Animation Frame
Purpose: Emit a tick event every graph execution frame (i.e., every animation frame) for continuous updates.
Output: tick (event)
Usage: Drive per-frame calculations (e.g., updating camera easing, sampling Noise) or feeding a Counter for accumulation.
Performance Note: Use sparingly; prefer Timer if you only need periodic updates.
History Log Event
Purpose: React to history log entries (object changes/actions) with a delayed trigger ensuring downstream reads see updated data.
Outputs: trigger (event), objectCategory (string), objectName (string), action (string)
Behavior: Captures event data first frame; fires trigger on next frame to avoid stale reads in dependent nodes.
Usage: Filter or branch workflows based on object category or action type (e.g., resource added vs removed).
Tutorial – Logging-Based Material Update:
- Connect objectCategory to a String Compare node checking for Material.
- Branch on equality to trigger a Set Material Values node.
- Use action to differentiate create vs update flows.
Milestone Change
Purpose: Emit a change event when the active milestone changes and expose milestone metadata.
Outputs: change (event), id, name, order, date (ms timestamp)
Behavior: Defers the change event until the subsequent execution frame to guarantee updated data availability.
Usage: Trigger timeline adjustments, camera reframing, or progress recalculations when project phase advances.
Scenario Start
Purpose: Fire a one-time event when the scenario initializes (graph start) for setup routines.
Output: event (init event)
Usage: Initialize Data Store defaults, set camera baseline, pre-load resources, or trigger a Sequence.
Slide Change
Purpose: Emit change event whenever a presentation slide changes, enabling synchronized visual transitions.
Output: change (event)
Usage: Drive camera movement, show/hide UI overlays, or advance Stepper index to match slide progression.
Timer
Purpose: Emit periodic tick events at a configurable interval while enabled.
Inputs: enabled (boolean; optional), interval (number input or property)
Outputs: on_tick (event) – property event can carry a message identifier.
Behavior: Accumulates elapsed time; fires when accumulated ≥ interval. Box color flashes on firing. Interval coerced to ≥1 ms.
Usage: Drive Stepper step, poll resource states, trigger recurring value transitions.
Tutorial – Timed Material Pulse:
- Create Timer (interval 1500ms).
- Connect on_tick to a Random Color node feeding material color property.
- Add a Toggle gating Timer.enabled for pause/resume.
Logic
AND
Purpose: Output true only when both boolean inputs a and b are true. Provides a strict logical conjunction.
Inputs: a (boolean), b (boolean)
Output: value (boolean)
Behavior: If either input is missing (null/undefined) the node outputs false. Otherwise returns a && b.
Usage: Gate actions or numeric flows that must satisfy two conditions (e.g., milestone reached AND user toggle enabled).
Branch
Purpose: Route a trigger event to either true or false output based on a sampled boolean condition.
Inputs: trigger (event), condition (boolean)
Outputs: true (event), false (event)
Behavior: Executes only when trigger fires (mode: ON_TRIGGER). Reads condition at that moment and fires exactly one output.
Usage: Use for event-level branching (contrast with Math Branch which routes data). Combine with Boolean Compare or Condition to build complex decision trees.
Boolean Compare
Purpose: Output true when inputs a and b are strictly equal, else false.
Inputs: a (boolean), b (boolean)
Output: value (boolean equality result)
Behavior: Null/undefined inputs produce false. Uses strict equality (===).
Usage: Detect state transitions by comparing a live signal with a latched snapshot (via Data Store).
Gate
Purpose: Forward the value of input a or b based on boolean value. Functions like a ternary selector.
Inputs: value (boolean), a (any), b (any)
Output: value (the chosen data)
Behavior: Reads value; if truthy outputs input a, else b. No implicit cloning—objects pass by reference.
Usage: Switch between two parameter sets (e.g., day vs night camera position) or choose active curve stream.
NOT
Purpose: Output the logical negation of the boolean input.
Input: in (boolean)
Output: out (boolean)
Behavior: If input is falsy or undefined, result is true; explicit true becomes false.
Usage: Invert a condition for branching without adding an extra Boolean node.
OR
Purpose: Output true if either a or b is true. Logical disjunction.
Inputs: a, b (boolean)
Output: value (boolean)
Behavior: Missing inputs produce false. Returns a || b.
Usage: Combine multiple enabling signals (e.g., manual override OR milestone trigger).
Selector
Purpose: Dynamically choose one among multiple value inputs (0,1,2,3, …) based on numeric index and output its current value.
Inputs: index (number), numbered value inputs starting at 0.
Output: value (the selected input’s data)
Behavior: Rounds index. Positive indices wrap via modulo. Negative indices wrap backward (cyclic). Highlights active slot with an arrow. Emits an internal onIndexChanged event (for editor renderer).
Usage: Centralize variant selection (e.g., choosing among predefined camera targets or material color presets). Pair with Stepper.index or a Counter.
Tutorial – Cyclic Camera Preset Selector:
- Create three Vec3 position providers (e.g., Const vectors) and connect to Selector inputs 0,1,2.
- Add a Counter feeding its num into Selector.index.
- Each frame (Animation Frame → Counter.inc) the selection cycles through 0→1→2→0…
- Connect Selector.value to Move Camera.position to jump between presets.
- Optionally add a Gate to enable cycling only when a Toggle is true.
String Compare
Purpose: Output true when two string inputs match exactly.
Inputs: a (string), b (string)
Output: equal (boolean)
Behavior: Null/undefined inputs produce false. Comparison is strict (===).
Usage: Combine with Branch or Gate to react to resource names, categories, or animation clip identifiers.
Math3D
Vec3 Add
Purpose: Sum two 3D vectors component‑wise.
Inputs: vec3Input1 (vec3), vec3Input2 (vec3)
Output: vec3Output (vec3)
Behavior: If either input is missing or not length 3, node outputs nothing that frame. Result = [x1+x2, y1+y2, z1+z2].
Usage: Combine a base position with an offset; aggregate multiple movement deltas before applying to camera/object.
Vec3 Scale
Purpose: Multiply a 3D vector by a scalar factor.
Inputs: vec3 (vec3), factor (number; optional)
Property: f (number; used when factor input unconnected)
Output: scaled (vec3)
Behavior: Produces [x*f,y*f,z*f]. Internally reuses a preallocated buffer for efficiency (avoid mutating it downstream).
Usage: Adjust magnitude of direction vectors (e.g., scale normalized tangent to desired step distance).
Vec3 Length
Purpose: Compute Euclidean length (magnitude) of a 3D vector.
Input: vec3 (vec3)
Output: length (number)
Behavior: sqrt(x² + y² + z²). Unconnected input produces no output.
Usage: Derive speed from displacement per frame; feed into Range or Clamp for normalization.
Vec3 Normalize
Purpose: Convert a vector to unit length (direction only).
Input: vec3 (vec3)
Output: normalized (vec3)
Behavior: Divides components by length; zero-length vectors yield NaN components (avoid passing [0,0,0]).
Usage: Prepare direction vectors for scaling (Scale node) or dot product comparisons.
Vec3 Lerp
Purpose: Linearly interpolate between vectors A and B by factor f.
Inputs: a (vec3), b (vec3), factor (number via f property or input)
Property: f (default 0.5)
Output: lerp (vec3)
Behavior: Computes A*(1-f)+B*f. If factor input absent uses property. Keep f in [0,1] for between endpoints; outside extrapolates.
Usage: Smooth camera or object transitions; pair with Range mapping time to [0,1].
Tutorial – Timed Camera Blend:
- Provide start and target camera positions as two vec3 sources.
- Use Time.ms → Range (0..duration) → Clamp 0..duration then divide by duration to get factor.
- Feed factor into Vec3 Lerp; output to Move Camera position each frame.
- Stop updating once factor ≥ 1 to finalize position.
Vec3 Dot
Purpose: Compute dot product of two vectors (measure alignment / projection).
Inputs: a (vec3), b (vec3)
Output: dot (number)
Behavior: Returns Ax*Bx + Ay*By + Az*Bz. Requires both inputs length 3.
Usage: Determine angle similarity (normalize both first; dot ≈ 1 means same direction). Use with Trigger thresholds (dot > 0.9).
Vec3 Cross
Purpose: Produce a vector perpendicular to both inputs (right‑hand cross product).
Inputs: vec3Input1 (vec3), vec3Input2 (vec3)
Output: vec3Output (vec3)
Behavior: Computes standard cross; input order affects direction sign. Length equals product of magnitudes times sine of angle.
Usage: Build orthonormal basis from tangent & normal (normalize both, cross to get binormal). Then derive orientation euler externally.
Tutorial – Constructing a Local Frame:
- Get curve tangent (e.g., from Get Scene Curves node).
- Provide an approximate up vector (e.g., [0,1,0]) and Normalize both.
- Cross tangent × up → binormal.
- Cross binormal × tangent → corrected normal (ensures orthogonality).
- Use these three vectors to assemble orientation elsewhere (e.g., custom node).
Vec2 to XY
Purpose: Decompose a 2D vector into scalar components.
Input: vec2 (vec2)
Outputs: x (number), y (number)
Usage: Extract single axis values for independent scaling or conditional checks.
XY to Vec2
Purpose: Compose two scalar inputs (or property defaults) into a vec2.
Inputs: x (number; optional), y (number; optional)
Properties: x, y used when inputs unconnected.
Output: vec2
Usage: Build adjustment vectors; feed into downstream math without needing a dedicated Constant Vec2 node.
Vec3 to XYZ
Purpose: Split a vec3 into individual scalar components.
Input: vec3
Outputs: x, y, z (numbers)
Usage: Feed one axis into Range or Clamp; build conditional logic from altitude (y).
XYZ to Vec3
Purpose: Assemble three scalar inputs (or property fallback values) into a vec3.
Inputs: x, y, z (numbers; optional)
Properties: Defaults for x,y,z when inputs unconnected.
Output: vec3
Usage: Form positions, directions or scaling vectors programmatically from separate computations.
Vec4 to XYZW
Purpose: Decompose a 4D vector into four scalar components.
Input: vec4
Outputs: x, y, z, w
Usage: Extract rotation quaternion components or color RGBA channels (if stored as vec4).
XYZW to Vec4
Purpose: Combine four numeric inputs (or property defaults) into a vec4.
Inputs: x, y, z, w (numbers; optional)
Properties: Fallback values for each component.
Output: vec4
Usage: Construct quaternions, parameter packs, or RGBA color vectors for downstream custom nodes.
Math
Abs
Purpose: Output the absolute (non‑negative) value of the input number.
Input: in (number)
Output: out (number)
Behavior: If input unconnected no output. Internally Math.abs(v).
Usage: Remove sign before feeding into Range or Clamp; convert oscillating sine to pulse magnitude.
Accumulate
Purpose: Maintain a running total, incremented each frame or by incoming increment value.
Input: increment (number; optional)
Outputs: total (number)
Properties: increment (default per tick), value (internal total start).
Behavior: Adds provided increment if connected else adds property increment. Stores running sum in value.
Usage: Frame counter, distance accumulator from per‑step displacement, or progress timer.
Average
Purpose: Smooth noisy input by averaging last N samples.
Input: in (number)
Output: out (number filtered)
Property: samples (# of stored samples; dynamically resizes buffer)
Behavior: Circular buffer collects values, outputs arithmetic mean. Changing samples reallocates preserving existing subset.
Usage: Stabilize camera speed, smooth terrain height readings, dampen sine for UI gauges.
Tutorial – Smoothing Random Noise:
- Random node → Average.in (samples=30).
- Watch both Random.value and Average.out.
- Observe slower, smoothed fluctuations.
Bitwise
Purpose: Perform bitwise XOR between two integers (provided via Operation node using OP=^).
Implementation Note: No dedicated Bitwise node; use Operation with OP set to ^.
Usage: Toggle packed flags or produce pseudo‑random binary pattern combining counters.
Branch
Purpose: Route a data value to one of two data outputs based on boolean condition.
Inputs: in (any), condition (boolean)
Outputs: true (data), false (data)
Behavior: Evaluates both inputs each frame; outputs value on matching branch, null on the other.
Usage: Select processed vs raw numeric stream; choose interpolation result only when active.
Clamp
Purpose: Constrain a number within [min,max].
Inputs: in (number)
Properties: min, max
Output: out (number clamped)
Behavior: Applies lower then upper bound sequentially.
Usage: Prevent factor overflow for Lerp; bound scaled velocities.
Compare
Purpose: Provide six parallel boolean outputs comparing A and B (==, !=, >, <, >=, <=).
Inputs: a, b (numbers)
Outputs: A == B, A != B, A > B, A < B, A >= B, A <= B
Behavior: Only computes outputs that have active links (micro‑optimization). Unconnected inputs fall back to properties A/B.
Usage: Drive Branch.condition directly from chosen comparison output; feed equality to Trigger.if.
Condition
Purpose: Evaluate a selected operator between A and B, outputting complementary true/false booleans.
Inputs: a, b (numbers)
Outputs: true, false
Properties: A, B, OP (enum: >,<,==,!=,<=,>=,||,&&)
Behavior: If inputs absent uses property fallbacks then evaluates chosen operator.
Usage: Simplify branch logic when you need both result and inverse simultaneously (e.g., show/hide UI).
Frac
Purpose: Output fractional part (value mod 1).
Input: in (number)
Output: out (number in [0,1))
Usage: Create looping progress from ever‑increasing Time.sec; feed into Lerp factor.
Floor
Purpose: Remove fractional component by rounding down.
Input: in
Output: out
Usage: Convert continuous counters into discrete levels or indices.
Lerp
Purpose: Interpolate between scalars A and B using factor f.
Inputs: a, b, f (numbers; each optional with property fallback)
Output: out (number)
Behavior: Computes A*(1-f)+B*f. Factor outside [0,1] extrapolates.
Usage: Create smooth transitions for opacity, scale, or camera distance driven by Range mapped time.
Noise
Purpose: Generate smooth pseudo‑random number sequence with adjustable amplitude, seed, octaves, persistence, and speed.
Input: in (number position/time)
Output: out (number)
Properties: min, max (range remap), smooth (cubic interpolation), seed, octaves, persistence (amplitude falloff), speed.
Behavior: Samples internal static table (length 1024), layering octave contributions; final value scaled to [min,max].
Usage: Procedural variation—camera subtle drift, material color shimmer. Combine Time.sec * speed for animated noise.
Tutorial – Creating Animated Terrain Height Bias:
- Time.sec → Scale (factor=0.2) → Noise.in.
- Set octaves=4, persistence=0.6 for detail.
- Range output to [0,1] for blending with base height.
- Feed result into Gate to enable/disable effect with Toggle.
Operation
Purpose: Perform configurable binary operation between A and B: +, -, *, /, %, ^, max, min.
Inputs: a, b (numbers; optional)
Properties: A, B (fallback values), OP (enum)
Output: out (number)
Behavior: Updates internal function when OP changes; draws operator symbol large on background when expanded.
Usage: Rapid arithmetic without multiple nodes; use max/min for clamping alternative.
Random
Purpose: Produce a new uniform random number each execution frame within [min,max].
Output: value (number)
Properties: min, max
Behavior: Updates output label with formatted value (3 decimals).
Usage: Feed into HSL Color hue, choose random offsets for camera, or seed Value Transition targets.
Range
Purpose: Remap an input value from input range [in_min,in_max] to output range [out_min,out_max], also providing clamped result.
Input: in (number)
Outputs: out (remapped), clamped (remapped then limited to output bounds)
Properties: in, in_min, in_max, out_min, out_max
Behavior: Performs linear mapping; collapses title to current value when node is collapsed. Updates first output label with current numeric display.
Usage: Convert Time.ms to normalized progress, scale distances into opacity, map altitude to color index.
Tutorial – Normalized Animation Factor:
- Time.ms → Range.in (in_min=0, in_max=5000, out_min=0, out_max=1).
- Use clamped output as factor for Lerp after 5s prevents overshoot.
- Trigger reset by Data Store storing new start time and subtracting from Time.ms upstream.
Round
Purpose: Provide rounded, floored, and ceiled versions of input with adjustable decimal precision.
Inputs: in, decimalPlaces (number; optional)
Outputs: round, floor, ceil
Behavior: Non‑integer decimalPlaces is coerced to integer; applies scaling factor 10^dec then respective operation.
Usage: Generate formatted display values, bucket continuous metrics (round) or ensure non‑overflow layout indices (floor).
Scale
Purpose: Multiply input by a constant factor.
Input: in
Property: factor (default 1)
Output: out
Usage: Convert time seconds to faster progression (factor>1) or slow down (factor<1) before feeding Range.
Smoothstep
Purpose: Map input across interval [A,B] using cubic smoothing for gentle start/stop (0→1).
Input: in
Properties: A (edge0), B (edge1)
Output: out (smoothed value)
Behavior: Normalizes then applies x*x*(3 - 2*x). Values outside range get clamped.
Usage: Ease camera or value transitions without separate easing node; feed factor into Lerp or Vec3 Lerp.
Spikes
Purpose: Generate intermittent spike pulses at random time intervals with smooth decay curve.
Outputs: out (number pulse)
Properties: min_time, max_time (interval randomization), duration (pulse length seconds)
Behavior: Counts down remaining_time; when <0 schedules new spike and sets blink_time. Pulse shape defined by 1/( (f*8 -4)^4 +1 ).
Usage: Trigger sporadic visual emphasis (material emission) or camera shake amplitude gating.
Tend to
Purpose: Gradually move output toward input creating exponential smoothing (low‑pass filter).
Input: in
Property: factor (blend ratio per frame; small=slow)
Output: out
Behavior: out = out*(1-factor) + in*factor. First frame initializes to input.
Usage: Smooth camera target changes, dampen noisy measurement stream before scaling.
Trigonometry
Purpose: Provide multiple trigonometric function outputs (sin, cos, tan, asin, acos, atan) from a single input.
Input: v (number; typically radians)
Outputs: Connected ones among sin, cos, tan, asin, acos, atan; each scaled by amplitude then offset.
Properties: amplitude, offset
Behavior: Iterates outputs and computes requested trig function; disconnected outputs skipped. Inverse functions expect domain constraints.
Usage: Create oscillations (sin/cos), compute angles (atan) from normalized values, drive color cycles.
Tutorial – Dual Axis Oscillation:
- Time.sec → Scale (factor=0.5) → Trigonometry.v.
- Use sin for X offset, cos for Z offset (amplitude=10).
- Compose XYZ to Vec3 and feed Move Camera.
- Offset property lifts oscillation by adding constant to sin/cos outputs if needed (use Range separately for Y).
UI
Button
Purpose: Emit an event when clicked and expose a transient clicked boolean during the press frame.
Outputs: event (event carrying optional message), clicked (boolean)
Properties: text (label), font_size, message (payload passed with event).
Behavior: Mouse press sets internal clicked state, fires event immediately, resets on mouse up. Programmatic click() simulates the cycle.
Usage: Manual trigger for sequences (Scenario init overrides), toggling tutorial steps, capturing user confirmation.
Combo
Purpose: Select one string value from a delimited list and emit change events.
Outputs: value (current selection), change (event fired on selection change)
Properties: values (semicolon list e.g., "Low;Med;High"), value (current).
Behavior: Updates internal widget options when values changes; selecting triggers change.
Usage: Drive discrete presets (camera mode, material theme). Feed value into String Compare or Selector index mapping.
Knob
Purpose: Interactive radial control to adjust numeric value within [min,max] with visual arc feedback.
Output: value (number)
Properties: min, max, value, color, precision.
Behavior: Drag vertically inside knob area to adjust; small increments without modifiers, faster with Shift, finer with Alt/Meta.
Usage: Real‑time parameter tuning (animation speed, noise amplitude). Chain to Range then Lerp factor.
Number
Purpose: Adjustable numeric widget supporting drag for continuous changes and click for step adjustments.
Output: value (number)
Properties: value, min, max, step.
Behavior: Vertical drag alters value in multiples of step; Shift accelerates ×10, Alt/Meta slows ×0.1. Enforces clamping.
Usage: Precise manual factor entry (e.g., Scale.factor) or threshold tuning for Condition comparisons.
Progress
Purpose: Visual linear bar representing normalized progress between min and max.
Input: value (number)
Properties: min, max, value, color.
Behavior: Normalizes value then clamps to [0,1]; redraws filled portion each execute.
Usage: Display interpolation factor, timeline elapsed ratio, or smoothstep output. Pair with Lerp factor for UI feedback.
Toggle
Purpose: Boolean UI control with optional external input override and emitted event on state changes.
Inputs: value (boolean; overrides), toggle (event to flip)
Outputs: value (current), toggle (event fired when changed)
Property: value default state.
Behavior: External value input sets state; user click or toggle action flips and emits event.
Usage: Pause timers, enable gating (Gate.value), activate camera lock logic.
Slider
Purpose: Linear adjustable numeric control with external override capability and change event.
Inputs: value (number optional external control), min, max
Outputs: value (number), changed (event)
Properties: value, min, max, text (label), defaultValue (fallback when loaded out‑of‑range).
Behavior: If value input is linked the node becomes externally controlled (user changes ignored). Clamps to [min,max]. Emits changed when internal value or bounds mutate.
Usage: Real‑time scrub through interpolation factor, adjust curve sampling resolution, tune noise speed.
Switch
Purpose: Simple enabled/disabled boolean output with an event when toggled.
Outputs: enabled (boolean), changed (event)
Property: enabled initial state.
Behavior: UI toggle updates property and fires changed. Programmatic property changes also emit.
Usage: Master enable for camera movement chain or Section Cut visibility gating.
Tutorial Modal
Purpose: Display a guided tutorial modal with dynamic content and navigation events (next/done/back/close).
Inputs: open (event), header, body, image (string sources), nextIsDone (boolean), useBack (boolean)
Outputs: next, done, back, close (events)
Properties: width, minHeight, header, body, image, nextIsDone, useBack.
Behavior: open event sets internal open state. Content inputs override properties each frame; toggles update internal widgets. Navigation triggers corresponding output and closes modal (except close which is explicit). When nextIsDone true the next button emits done instead of next.
Usage: Build multi‑step onboarding: chain next into another Tutorial Modal.open or scenario setup actions. Gate progression on external condition by ignoring next until ready.
Tutorial – Multi-Step Onboarding Flow:
- Create three Tutorial Modal nodes (Intro, Features, Finish).
- Scenario Start → first.open.
- First.next → second.open; second.next → third.open.
- Set third.nextIsDone=true to emit done event; connect done → camera reframe + close overlays.
- Enable back on second and third (useBack=true) to allow return: back → previous.open.
Animation
Animate Bone
Purpose: Interpolate a bone’s numeric value (e.g., rotation channel or custom scalar) from A to B over a specified duration, emitting lifecycle events.
Inputs: trigger (event start), cancel (event), bones (array/bone resource list)
Outputs: executing (event each active frame), finished (event on completion), cancelled (event if cancelled), bones (passthrough list)
Properties / Widgets: A, B (numeric endpoints), duration (seconds), bone (combo selection populated from incoming bones). Widgets keep properties synced.
Behavior: On trigger sets internal progress to start (_f = B initialization pattern) and fires executing. Each frame advances elapsed ms; value computed as A + (B - A) * clamp(t/duration,0,1). When interpolation reaches end fires finished. cancel stops and fires cancelled. Scene change notification emitted when bone value updates.
Usage: Drive bone articulation for objects (crane boom, vehicle suspension) during scenario steps. Combine with Selector to choose different bones dynamically.
Tutorial – Sequential Bone Animations:
- Select target bone from incoming bones array using combo.
- Set A=0, B=45, duration=2 for rotation channel (internal setter implemented by integration).
- Scenario Start → Animate Bone.trigger.
- Delay.finished (2.5s) → second Animate Bone (A=45,B=0,duration=1) for return motion.
- Branch on a Toggle to optionally cancel mid‑animation via Animate Bone.cancel.
Move Camera
Purpose: Immediately reposition (and optionally reorient) the active camera to provided position and Euler rotation on trigger.
Inputs: trigger (event), position (vec3), euler (vec3 rotation XYZ radians)
Output: out (event fired after move)
Behavior: Reads inputs only when triggered. If values differ from current camera, updates position via cameraControls.setPosition and target via setTarget (using Euler components). Emits scene change event if mutated. No smoothing—instant jump.
Usage: Hard cuts between viewpoints; pre‑position before a smooth Reframe sequence; relocate for Section Cut reveal.
Reframe Camera
Purpose: Smoothly (or instantly) move camera to frame the current resource object with positional offsets relative to its orientation.
Inputs: trigger (event)
Properties / Widgets: posOffsetX, posOffsetY, posOffsetZ (offset vector applied in object’s local space), smoothMove (boolean; enables eased movement).
Outputs: executing (event while camera handler updates), finished (event after completion or interruption)
Behavior: On trigger computes front vector from offsets (small epsilon added), transforms by target object world quaternion, adds to world position to form final camera position, then calls setCameraPosition({finalPosition,target,smooth}). Subscribes to camera handler events (interrupted, willUpdate, sleep, controlStart) to emit executing/finished appropriately.
Usage: Auto focus on selected model or milestone object; pair with Timeline tick to reframe on project progression.
Tutorial – Dynamic Focus on Moving Object:
- Feed resource object selection upstream (Select Object → resource graph).
- Toggle changes desired offset values (e.g., X=10,Y=5,Z=10).
- Timer (5000ms) → Reframe Camera.trigger for periodic updates.
- If user manually controls camera (controlStart) node emits finished; re-trigger on next Timer tick.
Timeline
Purpose: Expose presentation timeline metrics (start date, current date, elapsed seconds, total duration, milestone elapsed ratio) and emit tick events from external driver.
Outputs: tick (event), startDate (ms), currentDate (ms), presentationTime (seconds elapsed), presentationDuration (seconds total), milestoneElapsedRatio (0..1)
Behavior: Data set through external integration calling setStartMilestoneDate and setPresentationTimelineData; node simply re-emits updated outputs each execute. onTick() may be invoked by outside timeline driver to fire tick.
Usage: Drive progress bars, trigger milestone-based camera reframes, feed elapsed ratio into Lerp or Smoothstep for synchronized value transitions.
Value Transition
Purpose: Interpolate a scalar from A to B over a duration while emitting started/executing/finished events and current value output.
Inputs (ordered): trigger (event), a, b, duration (seconds)
Outputs: started, executing (per frame), finished, out (current interpolated value)
Properties: a, b, duration used if inputs unconnected.
Behavior: On trigger captures A, initializes progress (_f = a sentinel), emits started. Each frame accumulates elapsed ms; output = A + (B - A)*clamp(t/dur,0,1). After reaching end emits finished and stops.
Usage: Drive camera distance, opacity, numeric UI values; chain multiple for staged easing (use Delay between triggers).
Tutorial – Cascaded Value Transitions:
- Trigger → First Value Transition (A=0,B=1,duration=2) → executing feeds Progress.
- First.finished → Second Value Transition (A=1,B=0.5,duration=1).
- Second.out → Scale factor for material emission.
- Cancel branch (Toggle) gating first trigger prevents both sequences.
Camera Unlock/Lock
Purpose: Enable or disable user camera controls (lock/unlock) on trigger, emitting an acknowledgement event.
Input: trigger (event)
Output: triggered (event)
Property / Widget: locked (boolean) shown inverted by UI toggle ("Locked?").
Behavior: On trigger calls cameraHandler.enableControl(locked); if locked=true grants control, if false disables (naming inverted due to widget semantics). Then fires triggered.
Usage: Temporarily freeze user interaction during automated framing or tutorial steps; re‑enable after Value Transition finished.
Color
HSL Color
Purpose: Construct a color from Hue (0–360), Saturation (0–100%), and Lightness (0–100%) then output normalized RGB components (each 0–1) suitable for material updates or further blending.
Inputs: h (number – hue degrees), s (number – saturation %), l (number – lightness %). If any input is unconnected its property value is used.
Properties: h, s, l editable numeric fields (defaults: 0, 100, 50).
Output: color (array [r,g,b] each in 0–1).
Behavior: Values are rounded to integers before conversion. Conversion pipeline: HSL → RGB (0–255) → normalized division by 255. No alpha channel included.
Usage: Drive dynamic palette shifts by animating hue over time (Time.sec * speed). Combine with Range to clamp hue cycling. Saturation/lightness can be gated by a Toggle or smoothed via Tend To for gradual changes.
Tutorial – Animated Hue Sweep:
- Feed Time.sec → Scale (factor=40) → Frac → Range (0..1 to 0..360) → HSL Color.h.
- Set s=80, l=50 properties (or connect Number nodes).
- Connect color to Set Material Values.color (after selecting a material).
- Add a Toggle gating the Scale input (multiply by 0 when off) to pause hue rotation.
Random Color
Purpose: Generate a random RGB color (components 0–255) normalized to 0–1 each time an action triggers, and emit an accompanying event.
Input (event): trigger.
Outputs: color (array [r,g,b] normalized), event (fires after color generation).
Behavior: Uses uniform integer sampling for each channel independently. No seeding control—non deterministic across runs.
Usage: Attach to Timer.on_tick for periodic palette shifts, or Sequence outputs for multi‑phase color assignments. Chain into Average if you want smoother transitions (convert discrete jumps into blended values).
Tutorial – Pulsing Random Emission:
- Timer (interval=2000ms) → Random Color.trigger.
- Random Color.color → Set Material Values.color.
- Use Value Transition to interpolate between previous and new color: store old color in Data Store before triggering transition; lerp each channel (optional advanced pattern).
- Add a Switch to enable/disable the Timer for manual control.
RGB Color
Purpose: Compose an RGB color from individual 0–255 channel values (inputs or properties) and output normalized components (0–1) for downstream material usage.
Inputs: r, g, b (numbers; optional).
Properties: r, g, b (fallback channel values; each clamped and rounded).
Output: color (array [r,g,b] /255).
Behavior: Channels are coerced: round → clamp 0..255 → divide 255. Absence of inputs uses property values allowing manual slider control.
Usage: Combine with Operation, Clamp, or Range to generate channel ramps (e.g., fade red from 0→255 while keeping green/blue constant). Feed from Random (scaled) for constrained palette (e.g., only vary blue component).
Tutorial – Gradient Build via Range:
- Time.sec → Range (0..10 to 0..255) → Round.round → RGB Color.r.
- Set g=40, b=90 properties.
- Clamp Range.out to 0..255 and use Frac+Scale if you want looping ramp.
- Output color → Set Material Values.color for live gradient shift.
Inputs
Number Input
Purpose: Provide a user‑editable numeric value intended as a data entry point (form‑like input), distinct from the UI Number node which is optimized for inline parameter tuning.
Output: value (number).
Differences vs UI Number: Number Input is semantically treated as external data capture (e.g., user enters a target distance) whereas UI Number emphasizes interactive dragging with min/max/step. Use Number Input when you want deliberate entry rather than continuous tweaking.
Behavior: Emits its current numeric value each frame. Validation (clamping, stepping) may be lighter than UI Number depending on integration; treat as raw user input for processing (add Clamp downstream if needed).
Usage: Feed into Range bounds, set bone target angles (captured then fed to Animate Bone), or define axleRatio/wheelBase parameters for curve nodes without exposing drag behavior.
Tutorial – User Defined Transition Duration:
- User edits Number Input (e.g., enters 3.5).
- Connect value → Value Transition.duration input.
- Trigger Value Transition; interpolation now respects user‑entered time.
- Add Clamp after Number Input if you want to enforce min/max (e.g., 0.5–10 seconds).
Section
Section Cut
Purpose: Create and manage a clipping plane (section view) for the current resource/imported model, exposing controls for position, rotation, visibility, activation (stencil integration), inversion, and size, while emitting a change event when plane updates.
Inputs: trigger (action to apply updated property/input state), position (vec3 local), rotation (vec3 euler local), visible (boolean), invert (boolean flips normal), active (boolean adds/removes clipping plane from stencil instance), size (number square dimension).
Properties (defaults): visible=true, invert=false, active=true, size=100.
Output: changed (event fired after plane state applied and render cycle acknowledges).
Behavior: On trigger or property change flags _waitingForRender. During onExecute updates SectionViewPlane position by transforming local position through object world matrix; builds rotation basis, adjusts plane normal sign if invert. Activation toggles clipping plane registration with stencil instance only when active changes. Event fires after render synchronization to ensure scene observers see final state.
Usage: Interactive model slicing for presentations, isolating internal geometry, or showing progress overlays (combine with Camera Lock to control reveal). Use Gate on visible to tie plane display to milestone triggers.
Tutorial – Animated Progressive Cut Reveal:
- Value Transition (A=0,B=80,duration=5) → XYZ to Vec3 (Y drives vertical section plane position).
- Scenario Start → Section Cut.trigger to initialize plane.
- Each frame Section Cut updates as Value Transition executes (connect transition.executing → Section Cut.trigger for continuous updates).
- At finish, Trigger finished event → Camera Reframe to focus inside exposed region.
- Use Toggle to invert plane (invert) for an alternate slicing direction.
Material
Set Material Values
Purpose: Apply a new RGB color to a selected material upon trigger, emitting an event and notifying the scene of material changes.
Inputs: trigger (event), material (material reference), color (color array [r,g,b] normalized 0–1).
Output: event (fires after applying update).
Behavior: On action retrieves inputs; if color differs from current, sets material.color (using RGB components), flags change, and dispatches scene change (affectedTargetType: "material"). Always fires output event even if color unchanged (use Boolean Compare upstream if you need to suppress).
Usage: Drive real‑time color transitions (HSL Color hue sweep) or random pulses (Random Color). Chain after Selector to change palettes based on scenario stage.
Tutorial – Timed Palette Cycle:
- Create three RGB Color nodes with preset palettes.
- Stepper.index → Selector.index selecting one RGB output.
- Timer (interval=3000ms) → Stepper.step advancing palette.
- Selector.value (color) + selected material → Set Material Values.trigger.
Resource
Get Scene Curves
Purpose: Sample a composite Catmull–Rom curve built from geometry driver domains, exposing position, tangent, normal, rotation (Euler), and total length for a normalized sample factor plus optional terrain‑aware vertical adjustment.
Inputs: trigger (event to sample), sample (number 0–1 normalized path factor), forwardDirBool (boolean direction flag – flips final yaw 180° when false).
Outputs: finished (event), position (vec3), euler (vec3), normal (vec3), tangent (vec3), length (number).
Properties: curve (enum driver name), raycastPointsEnabled (boolean – if true raycasts each generated sample point to terrain adjusting Z+ε).
Behavior: Builds dense point lists between driver domain points (distance‑based divisions), constructs CatmullRomCurve3 segments, caches CompositeCurve. On trigger, clamps sample → factor, computes tangent, normal (tangent × up), binormal (tangent × normal), builds rotation from basis, applies forward inversion if needed, and outputs basis vectors & length.
Usage: Drive camera movement along infrastructure path, align object orientation to route, feed tangent into Vec3 Normalize → Scale for motion steps.
Tutorial – Camera Follow Along Curve:
- Accumulate or Value Transition → sample factor (0→1).
- Trigger sampling each frame (Animation Frame → Get Scene Curves.trigger).
- Use position to Move Camera.position and euler to orientation OR reconstruct quaternion if needed.
- Toggle forwardDirBool to reverse facing direction for reverse playback.
Get Scene Curves Rear Node
Purpose: Generate front and rear axle point arrays, rear curve, rotations, and mixed (axle ratio) positions for articulated vehicle/trailer simulations along a geometry path.
Inputs: trigger, sample (integer index), wheelBase (distance between axles), axleRatio (blend between front/rear points), curveDivisionFactor (refinement density), forwardDirBool.
Outputs: finished, position (vec3 at sample), euler, length (front curve length), rearLength, frontList, rearList, finalList (mixed), rotationList, numberOfPoints.
Behavior: Samples original curve points (similar to Get Scene Curves) then derives rear points by projecting backward along tangents by wheelBase, iteratively solving subsequent rear positions using ratio = (extendedLength - wheelBase)/extendedLength. Rotation basis built per segment. AxleRatio mixes each matched front/rear pair. Direction flag flips yaw.
Usage: Visualize truck + trailer articulation or compute intermediate hitch path. Feed arrays to Successive Node for further angle derivation.
Tutorial – Mixed Position Playback:
- Range (time 0..T → index 0..numberOfPoints) → sample.
- Slider controls axleRatio to visualize interpolation between front/rear tracks.
- Trigger each frame; Move Camera to position.
Get Scene Curves Successive Node
Purpose: Compute successive trailer joint rotations given front/rear axle point arrays for multi‑segment articulation, outputting rotation list and current sampled rotation.
Inputs: sample (index), wheelBase, rearExtension (trailer front overhang), frontListInput, rearListInput (arrays from Rear Node), forwardDirBool.
Outputs: rotation (degrees at sample), frontList (computed joint fronts), rearList (computed joint rears), rotationList (degrees sequence).
Behavior: If inputs unchanged (wheelBase, rearExtension, arrays) skips recomputation and just samples rotation (performance optimization). Builds front overhang points, derives successive rear points via ratio solving, computes angle between front & rear vectors with cross product sign (Z >=0 inverts sign), optionally flips sign if direction false.
Usage: Animate multi‑trailer steering, feed rotation into Set Bone Values for steering joints, or monitoring articulation limits.
Tutorial – Steering Angle Monitoring:
- Pipe front/rear arrays from Rear Node.
- Range/time → sample index.
- Successive Node.rotation → Watch & Condition (check |rotation| > threshold) → Trigger alert.
Bone Nodes
Get Bone Values
Purpose: Read current bone value plus constraint min/max limits for use in clamping, UI display, or driving interpolation nodes.
Input: bone.
Outputs: value (number), min, max.
Behavior: If bone available, extracts live value and computes constraint range via utility; missing bone outputs nothing. Values update each frame (pull model).
Usage: Feed min/max into Range to normalize bone value (progress visualization) or into Animate Bone to ensure targets respect bounds.
Tutorial – Constraint-Safe Animation:
- Select Bone → Get Bone Values.
- Value Transition outputs factor 0..1.
- Range (in=factor, out_min=min, out_max=max) → Animate Bone.B target.
- Trigger Animate Bone to move within limits automatically.
Play Animation Clip
Purpose: Control playback of a selected animation clip on a target object (play, stop, reset) using an internal instanced mixer; updates scene each frame while playing.
Inputs: object (instanced resource object), animation (clip index), play (event), stop (event), reset (event).
Behavior: Detects changes in object or clip index to (re)initialize mixer/action. play starts action (if stopped), stop halts, reset sets time=0. While state=play each execute advances mixer by frame delta and emits scene change (object affected).
Usage: Trigger clip on milestone, chain multiple clips by listening for Value Transition or Delay events before issuing next play.
Tutorial – Conditional Clip Playback:
- Select Object & Select Animation Clip provide object + clip index.
- Trigger Branch (condition from Boolean Compare) → play or stop events.
- Timer resets clip every 10s via reset input.
Select AnimationClip
Purpose: Choose an animation clip by name from an incoming array and output its numeric index for downstream playback.
Inputs: animations (array of names).
Output: animationIndex (number).
Behavior: Property enum populated from array; combo widget syncs on selection. During execute resolves current name to index; if name invalid outputs nothing.
Usage: Feed index directly to Play Animation Clip.animation input; pair with Combo or Selector to cycle clips.
Tutorial – Cycling Through Clips:
- Provide animations list from resource loader.
- Counter.num → Selector.index mapping indices to clip names (via intermediary array node or custom).
- Selector.value (clip name) → Select Animation Clip.animation property.
- Timer → Play Animation Clip.play with index output connected.
Select Bone
Purpose: Select a bone from an incoming array by name and output its reference for value reading or animation.
Input: bones (array/bone).
Output: bone (bone instance).
Behavior: Builds enum list from bones each execute; property change updates widget; selected bone forwarded.
Usage: Precede Get Bone Values / Animate Bone with selection; chain multiple Select Bone nodes for parallel bone animations.
Set Bone Values
Purpose: Assign a numeric value to a selected bone on trigger and emit an event plus scene change notification.
Inputs: trigger, value (number), bone.
Output: event.
Behavior: On action retrieves bone + value; if provided invokes bone setter (integration) marking change. Always fires event; scene notified (affectedTargetType: "bone") when change occurred.
Usage: Direct control from UI Number or Slider; combine with Compare to enforce constraint range (use Get Bone Values to fetch min/max then Clamp before triggering).
Tutorial – Slider Driven Bone Control:
- Select Bone → Get Bone Values for min/max.
- Slider.value → Range (in_min=0,in_max=1,out_min=min,out_max=max) → Set Bone Values.value.
- Slider.changed → Set Bone Values.trigger.
Object Nodes
Get Object Values
Purpose: Read transformation components (position, Euler rotation, quaternion, scale) from an object every frame for monitoring or derived calculations.
Input: object (object3d).
Outputs: position (vec3), euler (vec3), quaternion (vec4), scale (vec3).
Behavior: If object present copies arrays; no mutation. Euler from rotation; quaternion raw components; scale raw.
Usage: Feed position differences into Vec3 Normalize for movement direction; broadcast object state to UI Watch nodes; store snapshot in Data Store for delta computations.
Select Object
Purpose: Choose one object from an incoming array, ensuring unique display names even when duplicates exist, and output its reference.
Input: objects (array/object3d).
Output: object.
Behavior: Builds mapping of names to unique keys: duplicates get suffix (Name (1), Name (2)). Empty names replaced with (empty). Property syncs with combo widget each execute.
Usage: Precede Get/Set Object Values; chain multiple selection nodes for multi‑target setups (e.g., lead vehicle vs follower).
Set Object Values
Purpose: Mutate object transform components on trigger (position, Euler rotation, quaternion, scale) then emit event & scene change when any value changed.
Inputs: trigger, object, optional position (vec3), euler (vec3), quaternion (vec4), scale (vec3).
Output: event.
Behavior: Compares incoming values against current object; sets only provided components. If any component differs sets hadChanges true and emits scene change (affectedTargetType: "object"). Quaternion and Euler both accepted—supplying both applies both sequentially (watch for conflicts).
Usage: Apply procedural animation results (Vec3 Lerp) or user edits (Slider controlling scale). Use Delay + multiple triggers for staged transformation.
Tutorial – Position & Scale Pulse:
- Value Transition (A=0,B=1) → Range (0..1 to 0..10) → XYZ to Vec3 → Set Object Values.position.
- Second Value Transition drives uniform scale (compose [s,s,s]).
- Sequence triggers both transitions then each executing event → Set Object Values.trigger for live updates.
Material Nodes
Select Material
Purpose: Select a material (with color capability) from an incoming array, ensuring unique names and filter to color‑supported materials for subsequent color updates.
Input: materials (array/material).
Output: material.
Behavior: Filters only materials with a valid color property (isColor). Deduplicates names similarly to Select Object. Property enum updated each execute; selection forwarded.
Usage: Feed into Set Material Values; pair multiple Select Material nodes to batch update different material groups (e.g., base vs accent colors).
Others
SIN()
Purpose: Shortcut node emitting Math.sin(value) for a single input without needing full Trigonometry node.
Input: in (number radians).
Output: out (number).
Usage: Prefer when only sine is required (micro optimization & visual clarity) instead of adding Trigonometry with unused outputs.
COS()
Purpose: Emit cosine of input angle for phase‑shifted oscillations or perpendicular motion when paired with SIN.
Input: in.
Output: out.
Usage: Combine SIN and COS for circular camera paths (feed both into XYZ to Vec3 with scaling). Use Range + Scale to adjust amplitude.
TAN()
Purpose: Emit tangent of input; useful for slope derivations or exaggerated oscillations (careful near π/2 + kπ singularities).
Input: in.
Output: out.
Usage: Gate with Clamp or Scale to avoid runaway values; consider using Trigonometry for combined sin/cos context when computing tan = sin/cos manually if you need stability checks.
MIN()
Purpose: Output the lesser of inputs A and B directly (wrapper for Math.min).
Usage: Quick clamp upper bound: MIN(value, limit). For multiple comparisons consider Operation node with OP=min for consistency.
MAX()
Purpose: Output the greater of A and B (wrapper for Math.max).
Usage: Enforce lower bounds: MAX(value, threshold). Combine with MIN for manual clamp logic when Clamp node not used.
==
Purpose: Emit boolean true when A strictly equals B (number equality). Dedicated shortcut for readability vs Compare/Condition when only equality needed.
!=
Purpose: Emit true when A and B differ. Use to detect change or mismatch quickly without reading multiple Compare outputs.
>
Purpose: Emit true when A > B. Useful as direct Branch.condition input (readability over Condition with operator dropdown).
<
Purpose: Emit true when A < B. Commonly paired with its inverse in separate branches for early vs late stage logic.
>=
Purpose: Emit true when A ≥ B inclusive threshold test.
<=
Purpose: Emit true when A ≤ B. Use for shutting down transitions after exceeding max allowed value.
Comments
Please sign in to leave a comment.