Skip to content

Animation

Sektor plays skeletal animation through ozz-animation (a data-oriented runtime used in shipped titles) behind the engine's SektorAnimation adapter. Sektor owns the components, assets, Events, and workflows; ozz handles the specialist pose math. Poses sample deterministically on the fixed tick and skin on the GPU.

From file to moving character

  1. Import a glTF / GLB with a skin and clips. Clips become stable, referenceable assets.
  2. Add an Animator component to the placed model: a controller or a single clip, playOnStart, loop, playbackSpeed, and a blendDurationSeconds for switches.
  3. For anything beyond one clip, create an Animation Controller asset.

Animation Controllers

A controller is a versioned state-machine document: states bound to clips, transitions between them, and typed parameters that gameplay drives.

Concept Details
Parameters Typed Boolean, Number, and Trigger values
States Name, clip, playback speed, loop
Transitions Stable IDs, AND/OR conditions on parameters, optional exit time
Entry and Any-State Where the machine starts, and transitions that fire from anywhere
Cross-fades Real two-pose GPU blends over the authored duration

Studio has a full-page controller editor; edits update every character referencing the controller.

Locomotion in four states

States: Idle, Walk, Run, Jump. Parameters: Speed (number), Grounded (boolean), Jump (trigger).

Transitions: Idle → Walk when Speed > 0.1; Walk → Run when Speed > 4; any state → Jump on the Jump trigger while Grounded; Jump → Idle when Grounded becomes true, with a 0.2 second cross-fade on each.

Driven by gameplay, saved with the player

Animation Controllers are ordinary Event targets, not a separate scripting island. Picked Animator instances can play, pause, and seek clips or set parameters:

  • Event 1: every tick, set Speed from the Character Controller's velocity.
  • Event 2: on input.action_pressed "Jump" while grounded, fire the Jump trigger.

Parameter values, active states, and even partial cross-fades are authoritative state: they participate in replay hashes and restore exactly from player saves. Runtime telemetry exposes the active state per character to Studio and AI.

Automate it

{"op":"component.add","id":1,"type":"animator"}
{"op":"component.animator.set","id":1,"controllerAsset":"asset_controller_...","clip":"Walk",
 "playOnStart":true,"loop":true,"playbackSpeed":1,"blendDurationSeconds":0.2,"enabled":true}
{"op":"animation_controller.create","controller":{"format":"sektor.animation-controller/v1",
 "name":"Hero Locomotion","nextId":3,"entryStateId":2,"parameters":[],
 "states":[{"id":2,"name":"Idle","clip":"Idle","playbackSpeed":1,"loop":true}],"transitions":[]}}
{"op":"runtime.animation.parameter.set","id":1,"name":"Moving","type":"boolean","value":true}

An AI collaborator can build a complete locomotion controller, wire its parameters through Events, and verify the active state from runtime telemetry.

Still ahead

Broader glTF ingestion (morph targets, multiple skins per model, cubic interpolation), a visual node canvas over the structured editor, blend trees, masked and additive layers, root motion, and IK all build on this same foundation.