They don't use sqrt right now - as far as I can tell, they just functionally use the largest of the three distances, x, y, or z. Since diagonals are free, 3 spaces directly to the east and 3 spaces east and 3 spaces north are the same distance away, 3 spaces.
I thought I remembered someone verifying that diagonal movements were weighted correctly and took sqrt(2) times as long as straight moves.
My impression as well, from The Other Improved Pathfind Thread (TM). Yeah, I could search for it. No, I haven't been doing.
Not that this is the point, but while Manhattan distances mean a diamond shape of "equal distance", and diagonal=1 enhanced Manhattan means square-shaped "circles", diagonal=2^0.5 still won't give you a
circular 'circle'. It'll be correct (within a unit or so) at orthogonals and diagonals, but at all angles in-between you'd potentially be not getting as far as a 'true' radius for the same steps. Which leads onto the whole issue of paths from corner-tile-to-corner-tile across a 4x5 tile area are all 4 steps[1] but there's four different routes that can be taken that are exactly equivalent:
01... 0.... 0.... 0....
..2.. .12.. .1... .1...
...3. ...3. ..23. ..2..
....4 ....4 ....4 ...34
...and the larger the area, the more routes. Which is why I quite liked (in the previous thread) the idea of convex zones that can keep a track of a single measure from all access points[2] to all other access points. These convex zones would be defined as having at least one barrier-immune path available to cross from all relevant edge-points to all other relevant edge-points without being impeded. (A pillar in the middle of a 3x3 room would fully impede corner-to-corner diagonal travel (two unit steps with a root-2 step in-between), and impede centre-edge to centre-edge cardinal travel (two root-2 steps instead of two unit-steps), but wouldn't have bearing upon any other journey.
A very simple example says that a "corner-junction" 3x3 room with doors at (say) centre-West and centre-South would still allow the same journey (from one doorway, step onto SW corner, then to other doorway) regardless of any piller (central or side-connected)
except for having one in the SW corner on only point of contact that this 3x3 would otherwise have to be involved in. This is an absurdly simple example, of course, but shows us a convexity complication.
W-E travel from centre-west to centre-east doorways bounding the 3x3, having a central pillar, could be accomplished by entering from the doorway square either at a diagonal (NE,SE) or directly (E) then stepping to the side of the pillar (E and E for the "pre-diagonalled" step, NE
or SE if they first stepped on the horizontal) for a choice of four different routes, and then a further pair of route-choices (diagonal and horizontal or vice-versa) to get into the opposite doorway. Whichever of these eight routes is taken, the step-time = 2x(1+root(2)). It could be treated as a modified convex zone.
Everyone has to go that distance across it, regardless of how they accomplish it. And what if one had a string of such rooms? (Including corner-connector type rooms as already discussed.)
This is a fairly common type of dig-out construction for me (at least until I open the area out), closely followed by that of 5x5 rooms. (Later on, I may open out the doorways to make them more of corridors, which would change the dynamic, of course.) The rooms may have workshops in them (essentially representing a certain 'pillar' configuration for each workshop type, ignoring those that would actually block certain door exits in the first place). Each room would be an easy zone to map, and together they'd be a meta-zone where passing into the workshop-corridor at one end one should be able to know that, regardless of the exact pattern of side-steps[2], they've got a fixed distance. And that they don't need to worry about the middle bit for now, just use that information in their initial route-finding algorithm and if this turns out to be the favoured way (indeed, a possible one!) then when they get to the room, meta-room or, perhaps meta-meta-room, work out which of the many otherwise identical routes they are now going to take.
I'd relate this to the "Pinch-points" thread, except there's a bit of an exception to that rule.
A####
# #
1+ #
2+ +4
3+ +5
# +6
# #
####B
Depending on whereabouts in the room from the left you enter, and depending on the whereabouts in the room to your right you are going to depart, it's entirely possible that two different routes (door 2 to door 4, or door 3 to door 5) could be as easy to navigate. Being forced to make side-steps in an otherwise horizontal journey might encourage you along one particular of these. Or a journey from entrance A to entrance B could have you diagonally moving 1..4 or 2..6, for the exact same journey.
So in one, there's a pinch-point (not seen, but dictacted to by the outside) and in the other there are pinch-points two-tiles wide (you can easily find ones even wider, or even discontinuously distributed, say where a pillar-and-gap repetition occurs). Now. How to abstract those? If one could, it could be advantageous, but is the overhead in searching for that kind of feature too expensive?
[1] 5.24-and-a-bit. time-units under the root-2 schema, where a non-gridded distance would be 5.
[2] Important only, perhaps, in some future Additionall Improved Pathfinding technique which can say to itself, while working out the merits of different meta-paths with different on-route characteristics, "That area's busy, but there are plenty of opportunities to side-step and avoid crawling, unlike a single-tile tunnel". In fact, forced side-steps at the advantage of avoiding differently-sidestepping oncoming traffic might be better than straight-through single-tile tunnels where oncoming traffic slows you down to a (literal) crawl.