Skip to content

Documentation / scene / AnimationPlaybackSyncOptions

Type Alias: AnimationPlaybackSyncOptions

AnimationPlaybackSyncOptions = object

Defined in: libs/scene/src/animation/animationset.ts:43

Options for starting a playback at the same phase as another active playback.

Use this when switching between matching locomotion clips, upper/lower body clips, or a layered setup and a full-body clip that must stay phase-aligned.

Properties

target

target: string

Defined in: libs/scene/src/animation/animationset.ts:51

Active playback to synchronize with.

The value is resolved as an active clip name first, then as an active playback id. Timeline play steps also resolve local id references before forwarding the options to AnimationSet.


mode?

optional mode?: AnimationPlaybackSyncMode

Defined in: libs/scene/src/animation/animationset.ts:55

Synchronization mode. Defaults to 'normalized'.


offset?

optional offset?: number

Defined in: libs/scene/src/animation/animationset.ts:62

Optional phase offset.

In 'normalized' mode this is a normalized phase offset where 1 is one full cycle. In 'time' mode this is an offset in seconds.


wrap?

optional wrap?: boolean

Defined in: libs/scene/src/animation/animationset.ts:68

Whether the synchronized time wraps into the destination clip or range. Defaults to true.

Set to false to clamp the initial time to the destination clip or range.

Released under the MIT License.