Skip to content

Commit 9f0a969

Browse files
committed
minor changes, mostly comments
1 parent 60b40be commit 9f0a969

File tree

3 files changed

+7
-12
lines changed

3 files changed

+7
-12
lines changed

examples/t09_scripting.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,6 @@ static const char* xml_text = R"(
2727

2828
int main()
2929
{
30-
// Simple tree: a sequence of two asycnhronous actions,
31-
// but the second will be halted because of the timeout.
32-
3330
BehaviorTreeFactory factory;
3431
factory.registerNodeType<DummyNodes::SaySomething>("SaySomething");
3532

examples/t11_replace_rules.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,12 @@ int main(int argc, char** argv)
5757

5858
factory.registerNodeType<SaySomething>("SaySomething");
5959

60-
// We use lambdasand registerSimpleAction, to create
60+
// We use lambdas and registerSimpleAction, to create
6161
// a "dummy" node, that we want to create instead of a given one.
6262

6363
// Simple node that just prints its name and return SUCCESS
64-
factory.registerSimpleAction("TestAction", [](BT::TreeNode& self){
65-
std::cout << "TestAction substituting: "<< self.name() << std::endl;
64+
factory.registerSimpleAction("DummyAction", [](BT::TreeNode& self){
65+
std::cout << "DummyAction substituting: "<< self.name() << std::endl;
6666
return BT::NodeStatus::SUCCESS;
6767
});
6868

@@ -84,7 +84,7 @@ int main(int argc, char** argv)
8484

8585
if(!skip_substitution)
8686
{
87-
// we can use a JSOn file to configure the substitution rules
87+
// we can use a JSON file to configure the substitution rules
8888
// or do it manually
8989
bool const USE_JSON = true;
9090

examples/t12_groot_howto.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -49,22 +49,20 @@ int main()
4949
cross_door.registerNodes(factory);
5050

5151
// Groot2 editor requires a model of your registered Nodes.
52-
// You don't need to write that by hand, if can be automatically
53-
// generated using this command and imported.
54-
52+
// You don't need to write that by hand, it can be automatically
53+
// generated using the following command.
5554
std::string xml_models = BT::writeTreeNodesModelXML(factory);
5655

5756
factory.registerBehaviorTreeFromText(xml_text);
5857
auto tree = factory.createTree("MainTree");
5958

60-
std::cout << " ---------- XML file ----------\n"
59+
std::cout << "----------- XML file ----------\n"
6160
<< BT::WriteTreeToXML(tree, false)
6261
<< "--------------------------------\n";
6362

6463
// Connect the Groot2Publisher. This will allow Groot2 to
6564
// get the tree and poll status updates.
6665
BT::Groot2Publisher publisher(tree);
67-
BT::SqliteLogger logger(tree, "test_sqlite.db3", true);
6866

6967
while(1)
7068
{

0 commit comments

Comments
 (0)