HazardShape
A value shape that methods take or return.
Fields
| Field | Type | Description |
|---|---|---|
kind | "tile" | "area" | "ray" | "sweep" | Which shape. |
tile | HazardPoint? | tile: the tile. |
min | HazardPoint? | area: south-west corner, inclusive. |
max | HazardPoint? | area: north-east corner, inclusive. |
origin | HazardPoint? | ray and sweep: where it starts. |
dx | number? | ray and sweep: x direction, one of -1, 0, 1. |
dy | number? | ray and sweep: y direction, one of -1, 0, 1. |
skip | number? | ray: tiles to skip before the first covered one, the emitter's own footprint. Defaults to 1. |
len | number? | ray: covered tiles along the direction. |
width | number? | ray: tiles across, centred on the axis. Defaults to 1. |
speed | number? | sweep: tiles travelled per tick. |
size | number? | sweep: footprint side length in tiles. Defaults to 1. |
lead | number? | sweep: steps already travelled at tick zero, for a telegraph that projects something forward from where it will appear. |
trailClear | number? | sweep: tiles at the rear of the sweep to leave clear, because you may step in behind something that has just vacated them. |