I have also run into the 1024 hard coded grid size limit, and have read the posts where you point out that it can be removed, if desired. The use case is that I would like some very basic seeker movement outside of the 1024x1024 area, and more finely defined pathfinding inside it. The seekers outside the main grid only need to go from waypoint to waypoint I define, and not care about tags, physics and penalties.
The main thing I would need from Astar, is to keep moving the seeker in the same fashion outside the grid, as inside it, so that it doesn’t look funny when transitioning from one to another. So essentially, the ability to call seeker.StartPath, and pass it a list of waypoints that don’t sit on a grid. Is something like this possible?
It is possible when using the AIPath/AILerp script, it’s not that well supported though.
Essentially you need to create an ABPath instance and set the relevant parameters:
var path = ABPath.Construct(start, end, null);
path.vectorPath = listOfPointsHere; // make sure that vectorPath = start, vectorPath[last] = end
// Disable the built-in path recalculation
ai.canSearch = false;
// Mark the path as calculated
I think this will work.
I shall give it a whirl, thank you!
1024 seems to be quite large though, when you come down to it, so I will also try my best to just fit my entire game in that already large space Nevertheless, I feel like I will need this code sooner or later, regardless.