Support Forum

Erosion is causing some odd pathiong choices


Is there some way I can avoid them doing these weird de-tours when using tags?


it looks like you are using a modifier like simple smooth, and the original path would be like this
you likely have the penalty for the blue tag set higher than the green tag and normal ground, causing it to go out of its way to avoid pathing across even one tile of blue

1 Like

this might also happen if both penalties are equal and too high
remember that a penalty of 100 makes a tile type 2x as costly to traverse since the basic cost to cross a tile is 100

Hmm, no penalty seems correct. And you are sure default is 100? I havent notice any significant change in pathing until I reached at least 5000+ in penalty.



I guess I misremembered

you’re right with the penalty being 1000
since path cost scales based on world units traversed, not nodes. In my project for which I learned about penalties my nodes were smaller than 1 unit so it still worked

Indeed, any ideas here @aron_granberg ?


I think you have your erosion tags in the wrong order. They go from innermost to outermost.
So you should have tags in this order

  • No erosion at all
  • Distance 1 from wall
  • Distance 2 from wall
  • Distance erosionIterations from wall.

So instead of

  1. Easy
  2. Medium
  3. Hard

My tags should be

  1. Hard
  2. Medium
  3. Easy?

No, more like:

  • Easy (default tag)
  • Hard (first erosion tag, closest to the wall)
  • Medium (second erosion tag)

Ah okay, so in my scenario above with 2 erosion iterations (see screenshot), it will skip the Easy tag, set Medium as distance 1 erosion, and Hard as distance 2 erosion?

Yes, if you set ‘Hard’ as the first erosion tag in the grid graph settings.

Hmm, surely you mean if I set “Medium” as the first erosion tag? The first erosion tag is distance 1 surely? Making “Hard” distance 2, which is causing my issue.

Its really confusing to me, super hard to wrap my head around tbh.

My tags are setup like this:

  1. Easy
  2. Medium
  3. Hard

I need to reverse them so its like this:

  1. Hard
  2. Medium
  3. Easy

Then set first erosion tag to “Hard” with an erosion iteration set to 2. This will lead to “Hard” being distance 1, and “Medium” being distance 2, right?

Sorry for the confusion cant get my hear around it for some reason.


Might be easier if I reformulate it with different tag names:

Assume you tag names are as follows:

  • Default ground ← Lowest penalty
  • Erosion 1 ← Closest to wall, highest penalty
  • Erosion 2 ← Further from wall, medium penalty
  • Erosion 3 (if necessary)

In this case you should set the “first erosion tag” to “Erosion 1”. This will be the nodes closest to the wall (i.e. they should have the highest cost). The Default Ground tag will be used for all nodes that are too far away for the erosion to touch them.

1 Like

thanks, that made sense!

1 Like