OptionalviewDistance: numberReadonlyheightReadonlyshapeReadonlyterrainterrain id per cell, indexing into kinds
Optionalviewdefault sight radius for observers that do not provide one explicitly
ReadonlywidthThe same neighbourhood as neighbors, but calling visit(nx, ny) per cell instead
of building an array of them - the flood fills in Pathfinder call this per popped
cell, where the array plus one object per neighbour was the hottest GC churn in the
module (tens of thousands of short-lived objects per map). Anything that keeps a
neighbour past the call still wants neighbors; this is for visit-and-forget loops.
ignored on a hex Level - it only has the one neighbourhood shape
True only for cells with a full ring of neighbours.
Anything that inspects a cell's surroundings should use this rather than inside,
because a cell on the very edge has no neighbour on one side and every such check
then needs its own bounds test. Generators keep the border solid for the same reason.
The cells adjacent to (x, y) - six of them on a hex Level, four or eight on a
square one, regardless of which. This is the seam that lets Pathfinder and
FieldOfView work over either shape unchanged: they walk neighbours, and only this
method knows what a neighbour is.
ignored on a hex Level - it only has the one neighbourhood shape
every passable cell, as indices: the pool to place things in
StaticfromRebuilds a level from save data - the kinds table is supplied fresh (it holds a
game's own terrain meanings, the same way QuestLog takes its definitions fresh),
so only the terrain ids and rooms are ever save data.
rooms the generator carved, for placing stairs, monsters and treasure