Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

animate

Tweens or steps a property on something already on stage. Not the same as show/hide Transitions.

{
  "type": "animate",
  "target": "char:left",
  "property": "position_x",
  "to": 40,
  "duration": 0.4,
  "relative": true
}

Usually you need

FieldTypeDefaultEffect
targetstring—bg, char:slot, sprite:id, obj:id, panel, …
propertystring—opacity, position_x / y, scale, modulate, shader:u, …
toany—End value
duration≥ 00.5 (tween)Seconds
presetstring—shake / pulse / flash / bob or author preset

All fields

FieldTypeDefaultEffect
idstringautoFor stop_animate
presetstring—Built-in or animations/presets.json
mode"tween" | "keyframes" | "frames"inferredMode
targetstring—Target grammar
layerstring—Optional layer hint for some targets
propertystring—Property path
from / toanyfrom = currentEnds
duration≥ 00.5Seconds
easein | out | in_out | out_in"in_out"Ease
translinear | sine | …"linear"Curve
loopbool | "ping_pong"falseLoop
count≥ 00 (= ∞ when looping)Iterations
relativeboolfalseOffsets
keyframes / frames / fps / start_frame…fps min 0.001Advanced
intensity / decay / scale_from / scale_to / distance / color / opacitypreset extrasshake 5 / true; pulse 0.95–1.05; bob 10Preset knobs
whenexpression—Skip when falsy

Preset duration defaults: shake 0.4, pulse 0.6, flash 0.3, bob 2.0.

Do not animate opacity while a fade transition runs on the same node. Animations · presets · stop_animate.