Skip to content

five-on-it / packages/world/src/nav-layers / NavLayers

Interface: NavLayers ​

Defined in: packages/world/src/nav-layers.ts:74

The navigation grid and every floor over its ground (see the module documentation).

Properties ​

cell ​

cell: Uint32Array

Defined in: packages/world/src/nav-layers.ts:84

The cell of every upper node.


edges ​

edges: Float32Array

Defined in: packages/world/src/nav-layers.ts:86

The edge heights of every node, four per node in the order +x, −x, +z, −z (m; NaN: its floor stops short of that edge).


first ​

first: Uint32Array

Defined in: packages/world/src/nav-layers.ts:78

Where each cell's upper nodes start: those of cell c are first[c] to first[c + 1] (exclusive), counted from 0.


flags ​

flags: Uint8Array

Defined in: packages/world/src/nav-layers.ts:82

The flags of every upper node (the grid's NAV_* bits).


grid ​

grid: NavGrid

Defined in: packages/world/src/nav-layers.ts:76

The ground: node i of a cell i is its ground, flags and height as the grid has them.


height ​

height: Float32Array

Defined in: packages/world/src/nav-layers.ts:80

The height of every upper node (m).


jumps ​

jumps: Map<number, number[]>

Defined in: packages/world/src/nav-layers.ts:94

The ways between floors that are no walk (forEachJump): a ladder from the node at its foot to the node where it is stepped off at the top, and back; a lift between the floors at its stops. By node, in the level's order.


nodes ​

nodes: number

Defined in: packages/world/src/nav-layers.ts:88

How many nodes there are: the grid's cells and the upper nodes after them.