← Back to Docs
  • index.html
  • Clayground
  • Clayground.Character3D
  • ActionCycleAnim
  • Clayground 2026.7
  • ActionCycleAnim QML Type

    A looping whole-body action - working at something, or boxing - replayed from the pure pose model in action.js. More...

    Import Statement: import Clayground.Character3D
    Inherited By:

    FightAnim and UseAnim

    Properties

    Methods

    Detailed Description

    UseAnim and FightAnim are this with action set. Every angle comes from action.js; nothing is authored here.

    See also UseAnim, FightAnim, and Character::actionPoseAt().

    Property Documentation

    action : string

    Which action: "use" or "fight".


    cycle : int [read-only]

    How many whole cycles have played since this started.

    The model reads it: a working loop that is the same every time is noticed as a loop within a minute and a half, so action.js makes every fourth cycle's settle a proper look up. Deterministic - the variation is a function of the count, never of a random draw - so a recording of the loop is the same recording twice.


    cycleMs : real [read-only]

    One full cycle in milliseconds.


    entity : var [required]

    The Character whose joints this writes.


    handPose : string [read-only]

    What the hands are shaped like while this runs, "" when it is not running - a fist for the fight, a loose hand for the work.

    Character reads it: an activity that closes the hands has to be able to say so, and before this existed a punch was thrown with an open hand.


    intensity : real

    0 is unhurried, 1 is hard at it. Changes the speed of the cycle and the size of the movement, never the shape of the pose.


    phase : real

    Where in the cycle it is, 0..1. Set it with the animation stopped to hold one frame of the action.


    table : var [read-only]

    The derived numbers the cycle is replayed from.


    workHeight : real

    Where the work is: 0 a table at the waist, 0.5 a counter at the chest, 1 a shelf at head height. Ignored by the fight.


    Method Documentation

    void apply(real t)

    Writes the pose at phase t onto the entity, running or not.

    What the sheet uses to freeze a figure mid-action.