Cell
A discrete cell in a GridProjection addressed by integer column / row coordinates.
Convention used throughout the agent layer: col is the x-direction (0 at the left, increasing right) and row is the y-direction (0 at the top or bottom — the projection treats them symmetrically). Distance helpers are provided for the three standard grid metrics; see GridMetric.
Functions
Chebyshev (king-move) distance — max(|Δcol|, |Δrow|). This is the radius used by the Moore neighborhood: cells within Chebyshev distance 1 form the 8-cell ring around this one.
Straight-line (Euclidean) distance, computed in cell units.
Manhattan (taxicab) distance — |Δcol| + |Δrow|. This is the radius used by the Von Neumann neighborhood: cells within Manhattan distance 1 form the 4-cell cross around this one.
Octile (king-move with √2 diagonals) distance: the exact minimum cost from this cell to other on a uniform-cost Moore-movement grid with orthogonal cost 1 and diagonal cost √2. The natural admissible heuristic for A* on such a grid.