HomeLearnCoursesHackathonsAccount
Behavior Trees for Robot Control
Core Node Types · 1/2

Sequences, Selectors, and leaves

A Sequence node ticks its children left to right and only succeeds if every child succeeds. The moment one child returns Failure, the Sequence stops and returns Failure itself, without ticking the remaining children. This is the natural way to express 'do A, then B, then C, and if any step fails, the whole thing fails.'

A Selector, sometimes called a Fallback, is the mirror image. It ticks its children left to right and returns Success as soon as any child succeeds, only failing if every child fails. This is how you express 'try A, and if that doesn't work try B, and if that doesn't work try C.' Underneath both of these are the leaves of the tree: Action nodes, which do real work like moving an arm or driving to a point, and Condition nodes, which check something about the world, like whether an object is visible, without changing anything.