Skip to content

Falling beta ​

Interface of @v12-engine/client

ts
export interface Falling

Weather as it is drawn: its kind's look with what the map says over it. Speed is in cells a second; the height it starts at is what its look's speed and lifetime reach (speed × lifetime × 0.85), at most MOST_HEIGHT, the same whatever the map's speed, which shortens its lifetime instead

Members ​

color ​

ts
color: readonly [number, number, number, number];

RGBA, 0 to 1 each

direction ​

ts
direction?: WeatherDirection;

Which way it falls: with the wind when left out

height ​

ts
height: number;

How high above the ground each starts, in cells

lifetime ​

ts
lifetime: number;

How long each lasts, in seconds; shortened where the map's speed would make it fall past its height

rate ​

ts
rate: number;

Particles a second at its most, with the map's amount over the look's

settle ​

ts
settle: number;

How much it tints the ground its colour as it falls, 0 to 1

size ​

ts
size: readonly [number, number];

The smallest and the largest size of a particle, in cells, with the map's size over the look's

sound ​

ts
sound?: string;

A sound that loops while it falls, by name

speed ​

ts
speed: number;

How fast each falls, in cells a second, with the map's speed over the look's

splashes ​

ts
splashes: number;

Splashes where it meets the ground, 0 to 1; 0 for none

streaks ​

ts
streaks: boolean;

Whether each is a streak along the way it falls

swing ​

ts
swing: number;

How much each swings side to side as it falls, 0 to 1

volume ​

ts
volume: number;

How loud the sound is at its most, 0 to 1