MCPcopy Create free account
hub / github.com/BehaviorTree/BehaviorTree.CPP / tick

Method tick

tests/gtest_blackboard.cpp:29–43  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27 {}
28
29 NodeStatus tick()
30 {
31 int value = 0;
32 auto res = getInput<int>("in_port");
33 if(!res)
34 {
35 throw RuntimeError("BB_TestNode needs input: ", res.error());
36 }
37 value = res.value() * 2;
38 if(!setOutput("out_port", value))
39 {
40 throw RuntimeError("BB_TestNode failed output");
41 }
42 return NodeStatus::SUCCESS;
43 }
44
45 static PortsList providedPorts()
46 {

Callers

nothing calls this directly

Calls 2

RuntimeErrorClass · 0.85
valueMethod · 0.45

Tested by

no test coverage detected