Page 1 of 1
Presumed bug with distance tool (V key)
Posted: Tue Jan 27, 2026 4:18 pm
by KtoTam
My understanding is that hexes are 5 NM each. And it holds true when using pressing V key and checking distance between any 2 hexes. However when checking any further distances they tend to not be in multiple of 5.
What follows are the screenshots of distance measured to hexes two hexes away. The distance displayed when V is pressed is variously 8, 10 or 11 NM. Cardinal directions S,N,E,W appear to be always 10 NM. While SE,NE,NW,SW each have a pair of 8 NM and 11 NM.

- Zrzut ekranu 2026-01-27 170558.png (366.09 KiB) Viewed 130 times

- Zrzut ekranu 2026-01-27 170608.png (332.5 KiB) Viewed 130 times

- Zrzut ekranu 2026-01-27 170621.png (340.49 KiB) Viewed 130 times
Re: Presumed bug with distance tool (V key)
Posted: Fri Jan 30, 2026 8:51 pm
by Alessandro S.
Actually caused by hex geometry.
The hexes are 42 pixels in width, but each line of hexes is 38 pixels distant from the line below.
Or in other words, hexes are 42 pixels wide, but 38 high.
Changing the hexes height or width does cause a wrongly shaped hex.
The game map and math was aligned along the X and Y axis in a way 2 hexes to north/south equal 2 hexes to west/east.
This kind of projection distortion cannot be avoided due to the math of hexagons.
Re: Presumed bug with distance tool (V key)
Posted: Sat Jan 31, 2026 6:01 am
by KtoTam
Alessandro S. wrote: Fri Jan 30, 2026 8:51 pm
Actually caused by hex geometry.
The hexes are 42 pixels in width, but each line of hexes is 38 pixels distant from the line below.
Or in other words, hexes are 42 pixels wide, but 38 high.
Changing the hexes height or width does cause a wrongly shaped hex.
The game map and math was aligned along the X and Y axis in a way 2 hexes to north/south equal 2 hexes to west/east.
This kind of projection distortion cannot be avoided due to the math of hexagons.
I presume that under the hood there is some reason why you can't just grab the number of hexes (which is calculated correctly) and multiply it by 5, (or a distance between 2 neighboring hexes to avoid hard coding) instead of doing the pixel math?
Re: Presumed bug with distance tool (V key)
Posted: Sat Jan 31, 2026 3:28 pm
by Alessandro S.
Yes. The distance in hexes can differ depending on which hexes you use.
See example
Red and yellow are 3 hexes each. But the distance from A to B is different for both.
For many internal math the game thus uses the pixel coordinates for more precision.
Re: Presumed bug with distance tool (V key)
Posted: Sat Jan 31, 2026 5:25 pm
by KtoTam
Ah so for movement 'real Pythagorean' distance is used and not the go hex by hex distance. Very good to know.