I'm using AngryAnt's Behave, and I have several sub-trees, but when I have them called I don't see the Action's handler called. I've instantiated the main tree and the sub tree, and have the main tree's Tick() method called in Update(). I don't call the sub-tree's Tick() method because that would defeat the purpose of the main tree determining whether or not to call the sub-tree.
public class NonInteractiveCharacter : MonoBehaviour
{
private Behave.Runtime.Tree nicSelectorTree = null;
private Behave.Runtime.Tree idleTree = null;
void Awake ()
{
nicSelectorTree = BLNICLibrary.InstantiateTree(
BLNICLibrary.TreeType.NonInteractiveCharacters_NICSelector,
new NICSelectorAgent());
idleTree = BLNICLibrary.InstantiateTree(
BLNICLibrary.TreeType.NonInteractiveCharacters_Idle,
new NICIdleAgent());
}
// Update is called once per frame
void Update ()
{
nicSelectorTree.Tick();
// I shouldn't have to call idle's Tick method since it's called
// from the above selector tree
//idleTree.Tick();
}
}
Thanks in advance, Scott