3 ms·
A tiny nitpick: roguelikes in general don't really use Manhattan distance (but it's not Euclidean either). For instance, for getting to a tile that's 5 east a
by philsnow 4y ago
A tiny nitpick: roguelikes in general don't really use Manhattan distance (but it's not Euclidean either). For instance, for getting to a tile that's 5 east and 3 north from where you are,
.....x^3
......|
......|
@.....|
----->5
In Manhattan distance, that's 5+3 = 8, in Euclidean distance that's the length of the hypotenuse or about 5.83, but roguelike distance is max(5,3) = 5.
(I have just learned that this is also called chessboard distance or Chebyshev distance https://en.wikipedia.org/wiki/Chebyshev_distance https://en.wikipedia.org/wiki/Chebyshev_distance , yes the same Chebyshev as in Chebyshev's inequality https://en.wikipedia.org/wiki/Chebyshev%27s_inequality https://en.wikipedia.org/wiki/Chebyshev%27s_inequality .)