Best practice, newbie question

JasonT

Member
Just getting started with behaviour trees and I've settled into a type of logic that makes sense to me (it's like a several nested while loops) but I'm wondering if this is going not an efficient way to do things. As this AI gets more complex I can see that I will have many nested conditional aborts that are continually evaluated. Am I hacking my way through this or it this actually a sound way to keep going?
 

Attachments

  • BehaviorScreenshot.png
    BehaviorScreenshot.png
    123.4 KB · Views: 35
If you're just getting started you generally don't need to use the Selector Evaluator or Parallel Selector to begin with. I would instead start by starting similar to the UCC tree:

 
The problem I was running into is that I wanted a higher priority branch to run only WHILE their WITHIN DISTANCE was success, so I achieved that by using 'Selector Evaluator' and the conditional abort 'SELF' on the whole branch. Is there a better way to set that up?
 
If you set the Within Distance branch to the left with a Lower Priority conditional abort then that branch will always run when Within Distance returns success.
 
Top