hex-world
    Preparing search index...

    Interface PrecipitationOptions

    interface PrecipitationOptions {
        type?: PrecipitationType;
        count?: number;
        area?: number;
        height?: number;
        fallSpeed?: number;
        wind?: Vector2;
        color?: ColorRepresentation;
        opacity?: number;
        streak?: number;
        sway?: number;
        size?: number;
        intensity?: number;
    }
    Index

    Properties

    'rain' (falling line streaks) or 'snow' (drifting soft points). Default 'rain'.

    count?: number

    Maximum particle count at intensity 1. Default: derived from area at a constant density (~0.65 drops/unit² rain, ~0.5 flakes/unit² snow), so resizing the volume keeps the same on-screen density.

    area?: number

    Side length of the particle volume in world units. Size it to cover the camera's ground footprint at max zoom — the volume rim (faded) should stay off screen. Default 140 (matches the default camera's 80-distance max zoom on a wide viewport).

    height?: number

    Height of the particle volume in world units. Default 30.

    fallSpeed?: number

    Fall speed in world units/sec. Default 26 (rain) / 3.2 (snow).

    wind?: Vector2

    Horizontal wind drift in world units/sec. Default (0, 0).

    color?: ColorRepresentation

    Particle color. Default 0xc4d4e8 (rain) / 0xffffff (snow).

    opacity?: number

    Particle opacity at intensity 1. Default 0.5 (rain) / 0.9 (snow).

    streak?: number

    Rain streak length in world units (ignored for snow). Default 0.7.

    sway?: number

    Snow sway amplitude in world units (ignored for rain). Default 1.1.

    size?: number

    Snow flake size (perspective-attenuated; ignored for rain). Default 3.

    intensity?: number

    Initial intensity 0–1 (see setIntensity). Default 1.