Skip to content

FoliagePlacing beta ​

Interface of @v12-engine/client

ts
export interface FoliagePlacing

Where grass and bushes grow in the cells of their layer (FoliageLook.placing), over their density

Members ​

clump ​

ts
clump?: FoliageNoise;

Thicker in places and thinner in others, by patches (FoliageNoise): none when left out

edge ​

ts
edge?: {
        cells: number;
        to: number;
    };

Thinner towards the edge of where it grows: over cells cells from the edge, down to the part to at it. None when left out

jitter ​

ts
jitter?: number;

How far from a grid they are scattered, 0 (rows) to 1 (anywhere in the cell): 0.8 when left out, 0.7 for models

keepOff ​

ts
keepOff?: {
        water?: boolean;
        cliffs?: boolean;
        buildings?: boolean;
        doodads?: boolean;
        roads?: boolean;
    };

What it keeps off: water, the walls of cliffs, the ground under buildings, and under scenery that blocks (and what is kept off by hand, GameMap.pathing): each of these when left out, false for each it grows through. And the game's road (the tile road) where roads is true: left out, grass grows where it is painted whatever the ground's tile, a road too (tiles and notTiles say otherwise). Laid again where they come and go. Models keep off nothing unless the look says keepOff, as they always grew where painted

notTiles ​

ts
notTiles?: readonly string[];

The tiles of the ground it never grows on, by id

slope ​

ts
slope?: readonly [number, number];

The slopes it grows on, the least and the steepest, in degrees: every slope when left out

tiles ​

ts
tiles?: readonly string[];

The tiles of the ground it grows on alone, by id: every tile when left out. Of models too