I realise this is an ancient version of AStar, and I’m willing to update if it will fix this issue, but I’d rather not if possible.
I’m using a grid graph with the settings shown below. When I ask for paths to every node in the unit’s movement range (using a MultiTargetPath that gets passed a list of positions) some of the paths I get back don’t end on a node. For example if I ask for a path from (2.5,1,2.5) to (3.5,1,4.5), I might get back a path that ends at (3.5, 1, 4). It looks like those are paths where the last node was blocked by a collider but I haven’t fully checked that yet.
Yeah this is version is from eight years ago. I would highly recommend updating unless you have some specific for using such an old version?
That said, I looked through the patch notes and here are some relevant changes that were introduced in 4.0. This is only from a year after your version so it may be worth a look into in a duplicated project.
Implemented special case for paths on grid graphs so that if you request a path to an unwalkable node with several walkable nodes around it, it will now not pick the closest walkable node to the requested target point and find a path to that but it will find the shortest path which goes to any of the walkable nodes around the unwalkable node. Before, After . This is a special case of the MultiTargetPath, for more complicated configurations of targets the multi target path needs to be used to be able to handle it correctly.
This version of Unity has a bug which causes components in the A* Pathfinding Project to randomly stop working. Please update to unity 2022.3.21 or later.
That version is indeed ancient. I’m sorry, but I don’t even remember enough from that time to be able to help you. I would strongly recommend upgrading if possible.
Best of luck there, please let us know if you have any complications with the upgrade. As a note, here’s a guide for upgrading an older codebase to 5.0 that may be useful!