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

Method tick

tests/gtest_ports.cpp:329–350  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

327 {}
328
329 NodeStatus tick() override
330 {
331 const int answer = getInput<int>("answer").value();
332 if(answer != 42)
333 {
334 return NodeStatus::FAILURE;
335 }
336
337 const std::string greet = getInput<std::string>("greeting").value();
338 if(greet != "hello")
339 {
340 return NodeStatus::FAILURE;
341 }
342
343 const Point2D point = getInput<Point2D>("pos").value();
344 if(point.x != 1 || point.y != 2)
345 {
346 return NodeStatus::FAILURE;
347 }
348
349 return NodeStatus::SUCCESS;
350 }
351
352 static PortsList providedPorts()
353 {

Callers

nothing calls this directly

Calls 1

valueMethod · 0.45

Tested by

no test coverage detected