Seeker demand and large map question

Hi @aron_granberg,

I have a question and a request :

Request : I use ITraversalProvider in a gridgraph in my game. but I want to be able to give once the provider to the seeker for auto assign it to each path and before path construction call.
Can you mark “void StartPathInternal (Path p, OnPathDelegate callback)” virtual or create a variable provider in seeker which will automaticly assign to new path ?
I know I can use preProcessPath, but it’s better for performance to not override delegate each time I change the provider

Question : What do you think in performance POV of grid graph vs a point graph of 800K cells ? Today, I have a gridgraph but for futur features, it will be better to have point graph for update and freely add new points.



You don’t have to override the delegate each time, just make sure the delegate references some member variable that you can change.

class MyClass : MonoBehaviour {
    ITraversalProvider traversalProvider;
    void Start () {
         seeker.preProcessPath = (Path path) => path.traversalProvider = traversalProvider;

Performance of a grid graph will be higher I am pretty sure of. Or at least it will use a lot less memory.
Note that you can have multiple graphs in the scene and connect them together (for simplicity it is usually best to go with a single graph unless you really have to though).

Indeed,I did not think about using it like that.

Oh ! Have you a link to the doc or a exemple of how link 2 graph ? Because I cannot use layeredgrid because of the limitation of 4 connections so it can be perfect



From code you can do it using the GraphNode.AddConnection method.

I would however recommend using a single graph, things easily get complicated when trying to deal with multiple graphs.