Reelify Motion Kit 0.1 preview
Docs/Guide

Expressions

The four ways a value can be computed instead of written: "$name", "=expr", "{expr}" in text, and signals, plus $each, $if and colour mixes.

Most values in a scene are written out: "size": 96. Four forms let a value be read or computed instead. All four are strings or small objects, so the scene stays plain JSON. Expressions are parsed by the kit. They are never evaluated as program code.

FormExampleMeaning
"$name""text": "$tagline"The value of a token, a prop or a loop name, whole.
"=expr""w": "=size*2.1"Arithmetic that comes to a number.
"{expr}""text": "{round(82*up)}%"An expression filled into a longer text.
signal"signals": { "up": { "at": 0.6 } }A named value over time that any expression can read.

"$name"#

At the scene level, "$name" reads a token from the scene's tokens. The token can be a word, a number, a list or a record, and it replaces the string whole: "items": "$checks" hands a list to a component.

Inside a component's tree, "$name" reads one of the component's props first, then a loop name, then a token. A dotted path reaches into a record: "$item.text".

Inside a component or a loop, a name that is not defined is a problem. The message lists the props and loop names that exist at that place. A declared prop that was left out is simply absent.

At the scene level, a "$name" with no matching token is not a problem. It is left as written, so a text shows $name. Check that every token a scene reads is defined.

"=expr"#

A string that starts with = is arithmetic. It can use numbers, names, + - * / %, comparisons (< > <= >= == !=), a ? b : c, parentheses, the constants pi and tau, and the functions listed below. Angles in sin and cos are radians. Pose rotations are degrees.

Static or live#

If every name in the expression is fixed, it is worked out once at compile time. If it reads something that changes, it is kept as a live value and recomputed on every frame.

NameKindMeaning
a numeric prop, a numeric tokenfixedInside a component: its props. Anywhere: the scene's tokens. frameW and frameH are always defined.
index, count, the loop namefixedInside $each.
tliveScene seconds.
ltliveSeconds since this node started.
durliveThe scene's duration. It does not change, but it is read at play time.
a cue nameliveThat cue's time in seconds, also read at play time: "=bell((t-hit)*4)".
a signal nameliveThat signal's value now.
selfW, selfH, parentW, parentHliveMeasured sizes in pixels, from the renderer.

Where a live value is allowed#

  • These props: w, h, radius, opacity, rotate, scale, progress, size, gap, frame, aperture, spotX, spotY, spotR, and text.
  • Every channel of the drive behavior's pose. Position, depth, blur and clip move through drive, not through props.
  • A number prop of a component. The live value then moves whatever inside the component reads that prop.

Anywhere else a live value is a problem: "fill" can't change over time, followed by the list above. Options of most behaviors need fixed numbers.

min max abs round floor ceil sign sin cos tan atan2 sqrt pow exp clamp mix smooth step mod wave bell noise rand spring linear in out inOut inQuart outQuart inExpo outExpo inOutExpo inBack outBack inOutBack outCirc

Some shapes that come up often:

text
=cos(index/count*tau)*300       a ring of items
=0.3+0.7*wave(t-index*0.1)      a wave travelling along a row
=bell((t-hit)*4)                something that happens as t passes the cue "hit"
=mod(t,2)/2                     a loop every 2 seconds, 0 to 1
=spring(lt-0.4,0.3,0.6)         a spring that starts 0.4 s after the node does

"{expr}" in text#

Braces inside a text are filled in. A plain name that holds a word is inserted as it is: "by {name}". Anything else is computed and shown as a number, rounded to two decimals at most. If the expression reads time or a signal, the text is refilled every frame.

A text that changes every frame cannot also be split into words or letters. The check reports this as a note.

Signals#

A signal is a named value over time. One signal can drive many things, which keeps them in step.

DefinitionMeaning
{ "at": 0.6, "curve": "bouncy" }Goes from 0 to 1 at that time along that curve. from and to change the range. delay adds to at.
[{ "at": 0.6, "to": 1 }, { "at": 3.6, "to": 0 }]Several moves. Each starts from wherever the value is.
"=max(a/1080, b/1920)"Derived from other signals. Declare it after the ones it reads.
One signal, up, drives a number, a bar's width and a ring's progress. The spring's overshoot shows in all three at once.

A component can declare its own signals as state. Each use of the component gets its own copy, and its clock starts when that instance does. See Custom components.

A signal's name cannot be t, lt, dur, selfW, selfH, parentW, parentH, or the name of a cue.

$each#

In a children list, $each repeats a node. It takes a list, a count, or a "$name" that holds one.

json
{ "$each": "$items", "as": "item", "node": { "el": "text", "text": "$item" } }

Inside the node, the loop name (default item), index (from 0) and count exist. A count is capped at 600. A node inside $each that has an id gets the index in front of it.

Twelve circles from one node. index/count spaces them round a ring, t turns the ring, and wave sends a swell round it. The text in the middle is refilled every frame.

$if#

$if picks one of two values. It is decided once, at compile time, so its condition cannot read time or a signal. This node sits inside a component that has a bool prop called block:

json
{ "el": "shape", "kind": "rect", "h": 90, "fill": "accent",
  "w": { "$if": "$block", "then": 48, "else": 6 } }

For a value that switches while the scene plays, write a ternary in an expression: "opacity": "=t > hit ? 1 : 0.3".

Colour mixes#

A fill or a color can blend between two colours as a value moves. The third entry is a number from 0 to 1, usually a signal.

The pill's fill goes from muted to good as the signal done goes from 0 to 1. The tick's opacity reads the same signal.

What an expression cannot do#

  • It cannot produce text. It comes to a number. A value that is not a finite number is a problem.
  • It cannot call anything outside the function list, and it cannot loop.
  • It cannot read another node's position. A camera focus can point at a node by "#id", and that is resolved by the renderer.
Reelify Motion Kit 0.1 preview. Built 2026-11-21.llms.txt · SKILL.md · 109 pages