|
Thunderbots Project
|
#include <tactic.h>

Public Member Functions | |
| Tactic (const std::set< RobotCapability > &capability_reqs_) | |
| virtual bool | done () const =0 |
| virtual std::string | getFSMState () const =0 |
| const std::set< RobotCapability > & | robotCapabilityRequirements () const |
| std::set< RobotCapability > & | mutableRobotCapabilityRequirements () |
| void | setLastExecutionRobot (std::optional< RobotId > last_execution_robot) |
| std::map< RobotId, std::shared_ptr< Primitive > > | get (const WorldPtr &world_ptr) |
| virtual void | accept (TacticVisitor &visitor) const =0 |
Protected Attributes | |
| std::optional< RobotId > | last_execution_robot |
In the STP framework, a Tactic represents a role or objective for a single robot. This can be thought of as a "position" on a typical soccer team. Some examples are:
Tactics are stateful, and use Primitives to implement their behaviour. They also make heavy use of our Evaluation functions in order to help them make decisions.
|
explicit |
|
pure virtual |
Accepts a Tactic Visitor and calls the visit function on itself
| visitor | A Tactic Visitor |
Implemented in AttackerTactic, ChipTactic, CreaseDefenderTactic, DribbleTactic, GetBehindBallTactic, GoalieTactic, HaltTactic, KickTactic, MoveTactic, PassDefenderTactic, PenaltyKickTactic, PivotKickTactic, ReceiverTactic, and ShadowEnemyTactic.
|
pure virtual |
| std::map< RobotId, std::shared_ptr< Primitive > > get | ( | const WorldPtr & | world_ptr | ) |
Updates and returns a set of primitives for all friendly robots from this tactic
| world | The updated world |
|
pure virtual |
Gets the FSM state of the tactic
| std::set< RobotCapability > & mutableRobotCapabilityRequirements | ( | ) |
Mutable robot hardware capability requirements of the tactic.
| const std::set< RobotCapability > & robotCapabilityRequirements | ( | ) | const |
robot hardware capability requirements of the tactic.
| void setLastExecutionRobot | ( | std::optional< RobotId > | last_execution_robot | ) |
Updates the last execution robot
| last_execution_robot | The robot id of the robot that last executed the primitive for this tactic |