Skip to content

five-on-it / packages/world/src/nav-grid / NavGrid

Interface: NavGrid ​

Defined in: packages/world/src/nav-grid.ts:43

The ground of a level as square cells with flags.

Properties ​

cells ​

cells: Uint8Array

Defined in: packages/world/src/nav-grid.ts:51

The flags of every cell, row by row: index = row * size + column, columns along x, rows along z.


cellSize ​

cellSize: number

Defined in: packages/world/src/nav-grid.ts:45

Side of a cell (m).


heights ​

heights: Float32Array

Defined in: packages/world/src/nav-grid.ts:53

The height of the ground at every cell's centre (m).


origin ​

origin: number

Defined in: packages/world/src/nav-grid.ts:47

World x and z of the grid's first column and row (m): minus the ground's half-size.


size ​

size: number

Defined in: packages/world/src/nav-grid.ts:49

Cells per side.