Ashes Founders: Pathing battles

My retreating Prometheus

 

I can see the path it thinks I should take but...

Once I make my destination over here, it decides that the best path for it is over that hill instead of under it. 

A lot of time is spent on this because if we mess it up, units can get stuck or bounce around or clip in ways we don't want.  On the other hand, if we mess it up the other way, units won't go the way we expect them to go.  I expect it'll be something we endlessly play around with.

229 views 3 replies
Reply #1 Top

I love when the ground units get stuck to the point that they start going airborne and fly across the map X) 

Reply #2 Top

I love that Prometheus!

And I like what you have about Unit Path, I think the best way is to take the fastest way to get to the location that you choose without getting stuck. 

 

BTW those 2 empty weapons slot in Prometheus, it means we can upgrade them? :D

Reply #3 Top

From my own pathfinding experiments I devised the following way of doing things right:

  1. Implement goal-based vector field pathfinding algorithm. Take into consideration a special value for impassable terrain cells of the grid that are avoided always. That should prevent wrong decision-making.
  2. In the movement algorithm, set impassable cells to emit large radial push-out force. The key here is to never allow a unit's collision circle to travel 1/2 of the impassable terrain cell.
  3. To avoid crazy unit movement after an attempt to travel into impassable area, set high viscosity for the movement physical environment. That is most likely done already - without it units tend to have wrong deceleration behavior.