Motion
Get Motion

ReferenceScript nodesUtilities › Flow Control

For Each Layer

Does body once for each layer of the scene, with its name.

Inputs

PinTypeStarts atNotes
inwhat happens next––

Outputs

PinType
Loop Bodybodywhat happens next
Layer Namenametext
Indexindexnumber
Completeddonewhat happens next

The code it becomes

The graph below written as a script would write it.

let s2_name = "";let s2_index = 0;// On Scene StartL2: for (let i = 0, L = scene.layers; i < L.length; i++) {    s2_name = String(L[i].name || L[i].id); s2_index = i;    scene.log(s2_name);}

In a graph

The node with what starts it and Print to show what it gives, as Studio draws them.