Dist function taken from the original engine
WIP - vis keeping own "part" of the map

This would allow reasonable path tracing for visibility