Skip to content

MapSeeThrough beta ​

Interface of @v12-engine/client

ts
export interface MapSeeThrough

Trees and scenery seen through where they stand between the camera and units: faded (a pattern of their pixels left out, so nothing has to be sorted) or a hole cut through them around each unit, eased in and out. The game says so (GameView.world.seeThrough, where its code may decide which units and which things); this is the map's, over the game's

Members ​

buildings ​

ts
buildings?: boolean;

Buildings are seen through: no when left out

doodads ​

ts
doodads?: boolean;

Scenery (MapDoodad) is seen through: yes when left out

fade ​

ts
fade?: number;

Seconds it takes to fade out, and back in once nothing is behind it: 0.25 when left out

on ​

ts
on?: boolean;

Whether anything is seen through: yes once the game or the map says anything of it, no when neither does

opacity ​

ts
opacity?: number;

How much of what is in the way is still drawn, 0 (none of it) to 1 (all of it, as if not seen through): 0.3 when left out

radius ​

ts
radius?: number;

How far around a unit the hole is cut (cutout), in cells: 1.6 when left out

style ​

ts
style?: 'fade' | 'cutout' | 'none';

How: fade (when left out) fades all of what stands in the way, cutout cuts a round hole through it around each unit, none draws nothing (code reads what is in the way, client.seeThrough.occluders, and shows it its own way)

trees ​

ts
trees?: boolean;

What is seen through: trees and mines (and every resource drawn that way; yes), scenery (MapDoodad; yes), buildings (no)

who ​

ts
who?: 'own' | 'selected' | 'allies' | 'all';

Whose units it is done for: the player's own (when left out), those selected, the player's and allies', every unit seen