mwg API
    Preparing search index...

    Interface TerrainGraphicsLayerOptions

    interface TerrainGraphicsLayerOptions {
        placements: readonly TerrainPlacement[];
        project: (
            x: number,
            y: number,
            dx: number,
            dy: number,
        ) => { x: number; y: number };
        resolveImage?: (path: string) => Texture;
    }
    Index
    placements: readonly TerrainPlacement[]

    the placements resolveTerrainGraphics produced, or any list of the same shape

    project: (
        x: number,
        y: number,
        dx: number,
        dy: number,
    ) => { x: number; y: number }

    Where a placement lands, in pixels: its anchor cell (x, y) plus the rule image's own offset (dx, dy), both in the unit the rules were authored in. A square or isometric grid projects the sum of the two; a hex grid, whose offsets are axial, projects the cell and the offset separately - which is why the layer is handed the whole placement rather than only a cell, and why the projection belongs to the caller.

    resolveImage?: (path: string) => Texture

    how an image path becomes a texture; defaults to the asset resolver with a Texture.EMPTY fallback