Add cleanup for compsites in BT + refactor

This commit is contained in:
2024-01-11 07:48:49 +01:00
parent 2f2974fb77
commit 8043d56af9
2 changed files with 35 additions and 14 deletions

View File

@@ -26,7 +26,7 @@ bool init(int *game) {
// delay 1s
// print "Hello, world!"
printBT = bzBTMakeRoot(nodePool);
BzBTNode *pseq = bzBTCompSequence(nodePool, printBT, true);
BzBTNode *pseq = bzBTCompSelector(nodePool, printBT, true);
bzBTDecorDelay(nodePool, pseq, 2.0f);
BzBTNode *node = bzBTDecorRepeat(nodePool, pseq, 5);