PathFinding.js
PathFinding.js copied to clipboard
Padding around unwalkables
Is there any way to create a sort of padding around unwalkables? So that the path will be the quickest route while keeping an x amount of distance from unwalkables at all times?
Cost is what you want, and it's currently not supported by the main branch. There's a fork that supports it though https://github.com/johnste/PathFinding.js
Excellant! Is there a readme which explains the costs option or is it just as simple as adding it like this: var finder = new PF.AStarFinder({ allowDiagonal: true, dontCrossCorners: true, cost: 5 });
I don't see anything different in the docs on that fork but maybe I'm missing something.
The link doesn't work anymore, has anyone found a way of doing this?