Behavior Tree sequence refusing to exit

This may be an obvious oversight by myself, but are UE Behavior Sequences meant to run infinitely? Cause this one doesn’t seem to want to exit, even when the key that’s checked through the decorator lower down the branch is being set false by the attack task in the sequence? Like I said it may just be an oversight of mine, but time’s of the essence and the fix is out of my knowledge.

So I gather. I’ve already plugged in a few all along that branch. Each one’s checking for TargetTower, but if look to the right in the keys, it has no value at that point. You can see the minions in the viewport standing where it used to be. Yet somehow it’s passing through all of those decorators and continually firing the task.

BTs run forever unless you use decorators to suppress them or stop them from BPs.

That’s why I don’t use BTs - too many moving parts.
In your case it could be anything: could be something wrong with the blackboard, something wrong with the values on the blackboard, something wrong with the decorators, something wrong with the logic, something wrong with BTs as a whole…

I’m sorry, I know this isn’t constructive in the slightest. I just don’t use them anymore, I have my own thing called the “Behavior Graph”, it’s a lot more flexible than Behavior Trees anyway with not nearly as many moving parts.

No, it’s my own thing. You basically have two classes: BehaviorGraph which runs & manages the whole thing & BehaviorGraphNode which contains the logic & the exit points. BehaviorGraphNode has a delegate that takes the current node, the success node & the failure node & returns the next node (which should be the current node if the task is in progress). BehaviorGraphNode also contains success & failure nodes.

It’s pure C++ using simple lambda delegates & I usually run them within an AIController containing all the data needed which eliminates the need for blackboards.

That’s a new one on me. Is the graph part of the engine?

I think if you set observer aborts to self (on the decorator’s settings) it should solve the issues.

Oh my. Thank you very much. I’ve set self on the Is inRadius check at the start of the branch, and it’s finally worked! You have my gratitude my good friend.