3. Behavior Trees Flashcards
What is reactive planning?
A class of algorithms that compute the next action based on the current context rather than planning entire sequences in advance.
What are the benefits of reactive planning?
It is time-bound and can handle dynamic, unpredictable environments quickly.
What is a Behavior Tree (BT)?
A formal graphical modeling language used to define behaviors in AI systems, originally developed by R.G. Dromey.
Why were Behavior Trees developed?
To provide a more structured and scalable way of designing AI behaviors, especially for games like Halo 2 and Façade.
How do Behavior Trees improve on Finite State Machines (FSMs)?
FSMs become complex as the number of states increases, making transitions hard to manage. BTs provide a more scalable and modular approach.
What are the main types of nodes in Behavior Trees?
Task, Condition, Composite, Decorator, and Sub-tree nodes.
How are Behavior Trees evaluated?
They are evaluated in cycles using depth-first traversal from left to right.
What are the possible results of a Behavior Tree node?
SUCCEEDED, FAILED, or RUNNING.
What is a Sequence node?
A composite node that evaluates children left to right, failing as soon as one child fails and succeeding if all children succeed.
What is a Selector node?
A composite node that evaluates children left to right, succeeding as soon as one child succeeds and failing only if all children fail.
What is a Priority node?
A composite node that evaluates children in priority order, stopping when a child succeeds.
What is a Decorator node?
A node that modifies the behavior of a child node (e.g., negation, looping, or delaying execution).
What is a Blackboard in Behavior Trees?
A shared memory structure used for storing system state and inter-node communication.
What are the advantages of using Behavior Trees?
Reusability, goal-directed autonomy, event-driven responses, and easy debugging.
How do Behavior Trees improve on Hierarchical FSMs?
They clarify state transitions, simplify sequence building, and allow easy behavior modification without rewiring.
What are some criticisms of Behavior Trees?
They do not perform full search in the space, can be slow due to order of evaluation, and require careful task/condition selection.
What are common Behavior Tree design patterns?
Conditional execution (if-then-else), negation, timers, and until-fail loops.