AStar Integration Problem

deadneons

New member
In the screen shot below from the included demo scene the A* integration is having problems recognizing the pathfinder as AStar. Even when set to AStar, it's still looking for a nav mesh and throws a null reference. This happens in most of the movement pack trees but is not consistent. Sometimes trees work and sometimes they don't. If I set pathfinding to NavMesh and then back to AStar while in play mode and then restart the scene it will recognize AStar and work temporarily but on reloading the scene it goes back to looking for Nav Mesh even when set to AStar. Is there a global override setting I am missing that is set to NavMesh? Any help you could offer would be greatly appreciated. Huge fan of Behavior Designer and can't wait to be fully upgraded with Pro once I solve this issue. Using Unity 2022.3.38 AStar Issue.jpg
AStar Issue 2.jpg
I noticed that all 9 of my opsive assembly definition references have at least one or more missing Definition Assets. If this is the issue how do I go about finding the proper definitions for all 9?

AStar Issue 3.jpg
 
Last edited:
Hi, I am seeing the same issue as you on my side except for one thing - when setting the Pathfinder to NavMesh and then back to Astar in edit mode, the error doesn't happen in play mode. In case that changes anything I'm using Unity 6.0.50.
 
Hi, I am seeing the same issue as you on my side except for one thing - when setting the Pathfinder to NavMesh and then back to Astar in edit mode, the error doesn't happen in play mode. In case that changes anything I'm using Unity 6.0.50.
Thanks so much for the reply Cheo. Yea I can temporarily fix it this way but it eventually breaks again and starts searching for the NavMesh. I think its probably something wrong with my Assembly definitions. I am going to try a clean install to compare what those Assembly defs look like.

Update
Upon un-install and re-install of the Add Ons I still see the same missing assembly definitions. I had been using the previous Non Pro version and deleted them then re-installed the Pro Versions but no luck definitions are still missing on all 9 Assemblies. I also tried a clean install in a new project but found the same missing definitions on all the Assemblies.
 
Last edited:
Are you running the most recent version of the Movement Pack? In prior versions the pathfinder preference was saved with EditorPrefs and that caused some issues at runtime. In the latest versions the pathfinder is now set within the runtime code so is a lot more reliable.

If I set pathfinding to NavMesh and then back to AStar while in play mode and then restart the scene it will recognize AStar
You should set in edit mode, not play mode.

I also tried a clean install in a new project but found the same missing definitions on all the Assemblies.
The missing assembly definitions aren't an issue. You'd be receiving compiler errors if something is missing. If you aren't using the source version of Behavior Designer all of the compiled assemblies are pulled in automatically.
 
Are you running the most recent version of the Movement Pack? In prior versions the pathfinder preference was saved with EditorPrefs and that caused some issues at runtime. In the latest versions the pathfinder is now set within the runtime code so is a lot more reliable.


You should set in edit mode, not play mode.


The missing assembly definitions aren't an issue. You'd be receiving compiler errors if something is missing. If you aren't using the source version of Behavior Designer all of the compiled assemblies are pulled in automatically.
Thanks so much for the fast reply Justin. Again huge fan of your work. I am running the most recent version of the Movement Pack for Behavior Designer Pro, same with Senses Pack and Tactical Pack. I did have an outdated version of the original Behavior Designer in the project but deleted those packs (Movement and Tactical).

Even in a new clean project with only Behavior Designer and Astar Pathfinding Pro, I'm getting the issue where its calling for Nav Mesh instead of Astar. Even when I'm running a single command like Evade in the project demo. Evade is set to Astar but gets null reference for NavMesh. The only way I could get it to default to Astar was doing the switch at runtime. Not a solution, just an observation. I feel like I must be missing something in the setup but I don't know what it is. Astar is properly integrated because AStar is a choice. I am using the latest version of BD Pro and all 3 packs are for pro.

Thanks for the note about the missing assemblies. And sorry for the image spam I was just trying to be proactive and trouble shoot.
 
Thanks for all of the details, it definitely does help :) I was able to reproduce it - the issue was that I didn't update all of the demo samples after switching to the new way of setting the pathfinder. I just updated the A* integration so if you give that another download the scene should now work.
 
Thanks so much Justin. This seems to have fixed the issue. I have a custom AI script I'm working on and I had to remove and re-add any nodes that has AStar integration. After that it worked. I did have one final question. I had been using condition aborts in Parallel Selector Nodes in my old trees and I notice that this is no longer available. Are you by any chance going to include those in a future update or should I consider those outdated? Thanks again for all your help. I greatly appreciate it.
 
Great to hear.

I had been using condition aborts in Parallel Selector Nodes in my old trees and I notice that this is no longer available. Are you by any chance going to include those in a future update or should I consider those outdated?
In version 1 conditional aborts on a parallel task was undefined since it really wasn't needed. The parallel tasks reevaluate the tasks every tick anyway. With the version 2 restructure conditional aborts are now added via an interface so not ever composite task exposes the functionality.
 
Back
Top