ParticleParams
Since 0.6
Signature
export type ParticleParams = {
/** Particles per second for a continuous emitter. */
rate: number
/** Particles released immediately when the emitter starts; 0 for a steady emitter. */
burst: number
/** Seconds each particle lives: `[min, max]`. */
lifetime: [number, number]
/** Metres per second at spawn: `[min, max]`. */
speed: [number, number]
/** Metres across, over a particle's life: `[start, end]`. */
size: [number, number]
/** Hex colour at spawn. */
color: string
/** Hex colour at death. */
colorEnd: string
/** Alpha over a particle's life: `[start, end]`. */
opacity: [number, number]
/** Metres per second squared along -Y; negative makes a plume rise. */
gravity: number
/** Velocity lost per second, 0..1; wind resistance for light particles. */
drag: number
/** Half-angle of the emission cone, in degrees. 180 is a full sphere. */
spreadDeg: number
/** Cone axis in the emitter's space. */
direction: Vec3
/** How the sprite is composited; `additive` for anything that glows. */
blend: "alpha" | "additive"
/** Radians per second of sprite rotation. */
spin: number
/** Cap on live particles for one emitter, which bounds the buffer the sim allocates. */
maxParticles: number
}
Import: import type { ParticleParams } from "@argus/gameplay"