Component · twoD
Flipbook
Tick-driven flipbook state, wholly contained in an ECS component.
Fields
frames
list<FlipbookFrame>Ordered clip frames.
default []
startTick
u64Clip's start tick, preserved through snapshots.
default 0
looping
boolRepeat rather than hold the final frame.
default false
Usage
Every edit is an undoable command: from the CLI as below, or the same JSON from an agent over MCP. See component.add and property.set.
Add it
ara do component.add -p entity=name:Crate -p component=Flipbook --why "Add Flipbook"Set a field
ara do property.set -p entity=name:Crate -p path=Flipbook.frames -p value=[] --why "Tune Flipbook"In a scene document
{
"Flipbook": {
"frames": []
}
}From C#
/// <summary>Loop a campfire flipbook while the fire is burning.</summary>
public static void UseFlipbook(Entity entity, in Tick tick)
{
ref var component = ref World.Get<Flipbook>(entity);
component.Looping = true;
}From C#
Scripts read and write it with Get<Flipbook>(); see the Flipbook struct.