Skip to content

Commit 5b33f1e

Browse files
committed
minor changes
1 parent 92564df commit 5b33f1e

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

examples/t01_build_your_first_tree.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,11 @@ int main()
7373
// it automated the registering step.
7474
factory.registerFromPlugin("./libdummy_nodes_dyn.so");
7575
#endif
76-
// register the XML description
77-
factory.registerBehaviorTreeFromText(xml_text);
7876

7977
// Trees are created at deployment-time (i.e. at run-time, but only once at the beginning).
8078
// The currently supported format is XML.
8179
// IMPORTANT: when the object "tree" goes out of scope, all the TreeNodes are destroyed
82-
auto tree = factory.createTree("MainTree");
80+
auto tree = factory.createTreeFromText(xml_text);
8381

8482
// To "execute" a Tree you need to "tick" it.
8583
// The tick is propagated to the children based on the logic of the tree.

examples/t05_crossdoor.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ int main()
4646
CrossDoor cross_door;
4747
cross_door.registerNodes(factory);
4848

49-
// In this example a single XML contains multiple tags <BehaviorTree>
49+
// In this example a single XML contains multiple <BehaviorTree>
5050
// To determine which one is the "main one", we should first register
5151
// the XML and then allocate a specific tree, using its ID
5252

0 commit comments

Comments
 (0)