Updated A* and got a bunch of errors

Thanks, must have missed that -

I’ve tried contacting the DunGen creator, but haven’t heard anything back.

After changing it from PathFinder.ScanLoop(ProgressCallback); to PathFinder.ScanAsync(ProgressCallback), I get the following error:

Assets/DunGen/Integration/AStarPathfindingProjectPro/AStarNavMeshAdapter.cs(55,21): error CS1502: The best overloaded method match for AstarPath.ScanAsync(Pathfinding.NavGraph)' has some invalid arguments Assets/DunGen/Integration/AStarPathfindingProjectPro/AStarNavMeshAdapter.cs(55,31): error CS1503: Argument#1’ cannot convert method group' expression to typePathfinding.NavGraph’

ProgressCallback is:
protected virtual void ProgressCallback(Progress astarProgress)
{
progress.Percentage = astarProgress.progress;
progress.Description = astarProgress.description;

        if (OnProgress != null)
            OnProgress(progress);
    }

Apologies if this is beyond the scope of the A* update. Thought you may have a quicker insight into what’s going on.

Right. It’s slightly different than the previous one. You can create a wrapper like this:

public void ScanLoop (OnScanStatus statusCallback) {
     foreach (var p in AstarPath.active.ScanAsync()) {
         statusCallback(p);
     }
 }

and call it just like it was originally called.

That worked great, thanks!

You could, yeah. Depending on which package you want to modify.

1 Like