babylon.quarks - v1.0.0
    Preparing search index...

    Class ColorOverLength

    Colors a trail along its length: Unity's Trail Renderer Color and the Trails module's Color over Trail.

    The gradient runs from the head (0) to the tail (1), the trail's oldest sample, and multiplies the color each sample was recorded with (the particle's color at that moment): a gradient from opaque to transparent fades the trail out toward its tail, however the particle is colored. The head itself gets the gradient's value at 0. Like WidthOverLength, the gradient spans the samples the trail holds now. A trail drawn in its particle's current color (TrailSettings.colorFromParticle) does not draw the recorded colors, so this changes nothing there. Applies to trails only.

    Implements

    Index
    type: string

    The name the behavior is registered under in BehaviorTypes.

    • A copy with the same settings that shares nothing mutable with this one.

      Returns Behavior

    • Called once per step before this behavior updates the particles, with the step's length in seconds.

      Parameters

      • delta: number

      Returns void

    • Called once per particle when it is emitted; see the interface's description for when.

      Parameters

      Returns void

    • Called when the system restarts (not when a looping system starts its next loop): forget state accumulated across steps, so the replay starts as the first play did.

      Returns void

    • Called once per live particle per step, with the step's length in seconds.

      Parameters

      Returns void