Skip to content

Instantly share code, notes, and snippets.

@bob-ross27
Created January 12, 2021 14:36
Show Gist options
  • Save bob-ross27/e9fb5f0fcd52b0da5ed498b3a2879522 to your computer and use it in GitHub Desktop.
Save bob-ross27/e9fb5f0fcd52b0da5ed498b3a2879522 to your computer and use it in GitHub Desktop.
Change the first selected node to 2's, presuming frame naming matches the default import values.
scene.beginUndoRedoAccum("Set Video on 2s");
var col = node.linkedColumn(selection.selectedNode(0), "drawing.element");
var keys = column.getDrawingTimings(col);
keys.forEach(function(key) {
if (parseInt(key) % 2 === 0) {
column.setEntry(col, 1, parseInt(key), parseInt(key) - 1);
}
});
scene.endUndoRedoAccum();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment