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

    Class ConeEmitter

    Emits from a disc in the xy plane into a cone along +z (Unity's Cone shape): a particle at the disc's rim heads out at the cone's angle, one at the centre straight along z, and one between them along the cone's side lines, tilted by atan(r · tan(angle)) at the fraction r of the radius. With ConeEmitFrom.Volume, particles start anywhere on those lines up to ConeEmitter.length along z.

    Implements

    Index
    angle: number

    Angle in radians between z and the direction of a particle that starts at the rim, from 0 to π/2.

    arc: number

    Arc of the disc, in radians, that particles start in; 2π for the whole disc.

    emitFrom: ConeEmitFrom

    Which part of the cone particles start from, see ConeEmitFrom.

    length: number

    Height along +z of the volume ConeEmitFrom.Volume fills; read as 0 when negative or not finite. Side lines steeper than 89° from the axis are followed as if at 89°, so a cone opened to 90° fills out to about 57 times the length past the rim, not infinitely far.

    State the ConeEmitter.speed generator keeps.

    How the start point moves along the arc, see EmitterMode.

    radius: number

    Radius of the disc particles start on.

    Speed of the arc sweep in arcs per second, for the Loop and PingPong modes; sampled over the system's cycle.

    spread: number

    Snaps the start point along the arc to multiples of this fraction (Unity's Spread); 0 for none.

    thickness: number

    How far in from the rim particles may start, as a fraction of the radius (Unity's Radius Thickness): 0 on the rim, 1 anywhere on the disc, spread evenly over the area; clamped to [0, 1].

    transform?: ShapeTransform

    Optional local transform of the shape inside its particle system, applied by the shape itself at the end of initialize.

    type: string

    Always 'cone'.

    • Forgets the state the shape built up while emitting (the arc sweep position of Loop/PingPong shapes, generator memory), so a restarted system emits from the start of the arc again. Called by the particle system's restart().

      Returns void

    • Advances the arc sweep by delta seconds in the Loop and PingPong modes.

      Parameters

      Returns void