Skip to content

MapRule beta ​

Interface of @v12-engine/engine

ts
export interface MapRule

A check of a map (checkMap): what it says is wrong (say), each problem with the rule it breaks (MapProblem.rule), which a map or a game silences. id names the check: the engine's by what they look at (objects, walking), a game's its own

Members ​

check ​

ts
check(map: GameMap, registry: Registry, say: (problem: MapProblem) => void, context: MapCheckContext): void;

Says what is wrong with the map (say, a problem at a time), the game's registry and the context to go by

id ​

ts
id: string;

What names the check (objects, walking, a game's own): each problem it says names the rule it breaks