Force Failure

Force Failure — finish a step, then reject the branch

Force Failure runs its child and returns Failure to the parent, even if the child succeeded. For example, this lets you end the current branch of a Sequence. It does not cut off unfinished work: Running stays Running.

Observe the parent stop

You need your own tree that you start by hand: Activation → Is Loaded and Execution → When Activated → Do nothing. Getting Started shows how to add and connect nodes.

  1. Add Sequence, Force Failure and two Fixed Status nodes. Connect them in the order below, left to right.
  2. Set both Fixed Status nodes to General → Status → Success. General → Child on Force Failure should name its child.
text
My Tree
└─ Sequence
   ├─ Force Failure
   │  └─ Fixed Status: Success
   └─ Fixed Status: Success
  1. Click the upper Tick BT Once. The child of Force Failure returns Success, but Force Failure and Sequence return Failure. The last Fixed Status is not called in this pass.
  2. Set the first Fixed Status to Running and tick again. Now Force Failure and Sequence return Running. Set the child back to Success, and the next tick finishes the branch with Failure.
Setting or child resultEffect
ChildOne child. For several steps, connect a child Sequence
SuccessForce Failure returns Failure
FailureForce Failure returns Failure
RunningForce Failure returns Running and does not force the child to finish

The smallest case, a successful child whose result is changed:

plaintext
Force Failure
    └── Child Node (Success)

With no children, the node returns Failure. The parent decides what happens next: Sequence stops on Failure, while Selector tries the next option.