Skip to content

EmitterShape beta ​

TypeAlias of @v12-engine/client

ts
export type EmitterShape = 'point' | 'sphere' | 'hemisphere' | 'box' | 'cone' | 'cylinder' | 'ring' | 'mesh' | 'ground' | {
    type: 'point';
} | {
    type: 'sphere' | 'hemisphere';
    radius?: number;
    rim?: boolean;
} | {
    type: 'box';
    size?: readonly [number, number, number];
} | {
    type: 'cone';
    radius?: number;
    angle?: number;
} | {
    type: 'cylinder';
    radius?: number;
    height?: number;
    rim?: boolean;
} | {
    type: 'ring';
    radius?: number;
} | {
    type: 'mesh';
} | {
    type: 'ground';
    radius?: number;
} | {
    type: 'custom';
    position: (out: {
        x: number;
        y: number;
        z: number;
    }) => void;
    direction?: (out: {
        x: number;
        y: number;
        z: number;
    }) => void;
    world?: boolean;
};

Where particles start, and which way they go from there. A word for its shape with what it is when left out, or the shape with its sizes, in world units (a cell is 1): - point: all from one point, along direction; - sphere, hemisphere: from inside one (rim: from its surface), outward; - box: from inside a box, along direction; - cone: from its tip outward, angle wide (radians), as a fountain or a torch's flame; - cylinder: from inside one standing up (rim: its side), outward, or along direction; - ring: from a circle on the ground, outward: a shockwave's dust; - mesh: from the surface of a mesh: the model of the entity the effect is on when mesh is left out; - ground: from the ground under a radius, following its rises and falls: a burning field, dust over an area; - custom: from where code says, each one (on the CPU): cells of a layer, a path, a shape of the game's