When using the ForceSuccess decorator on a Run Behavior task which also has an abort decorator, the Force Success node cannot make the task return succeeded when the abort is triggered. This means that using the Run Behavior node in a sequence will stop the sequence from running rather than allowing the Run Behavior node to be used as an optional branch.
If the same two decorators run on another BT task that does not create a subtree, the behavior is that the sequence continues to the next node/branch within the sequence. It was expected that running on a node that has a subtree would have the same behavior. Debugging this showed that the NodeResult *is *Failed *inside of *UBTDecorator_ForceSuccess::OnNodeProcessed, but SearchData.SearchRootNode is using the root node of the main tree while the SearchData.RollbackInstanceIdx is set to the root of the subtree. This always sets bCanForceSuccess *to false so the decorator does not change the *NodeResult.
This applies to both Run Behavior and Run Behavior Dynamic nodes.
Steps to Reproduce
Sample Tree:
[Image Removed]
How does TextureRenderTarget2D get TArray<uint8> type data?
Why does the REMOVE method of map container remove elements have memory leaks?
How do I set a material as a post-processing material?
What is the cause of the packaging error falling back to 'GameUserSettings' in ue5?
How to delete some elements correctly when deleting an array loop?
UMG RichText not appear image when packaged
What is the difference between Camera and CineCamera?
How does TArray loop correctly remove elements in blueprints?
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-235314 in the post.
0 |
Component | UE - AI - BehaviorTree |
---|---|
Affects Versions | 5.4, 5.5 |
Target Fix | 5.6 |
Fix Commit | 39455252 |
---|
Created | Dec 20, 2024 |
---|---|
Resolved | Jan 24, 2025 |
Updated | Feb 10, 2025 |