3 #include "../world/Coordinates.hpp"
14 MoveAction(std::chrono::system_clock::time_point startTime,
Coordinates target, std::shared_ptr<Entity> pEntity);
47 std::vector<std::pair<int, int>>
pathM;
Represents an action that an entity can perform.
Definition: Action.hpp:15
Action used for moving.
Definition: MoveAction.hpp:12
Coordinates getTarget()
Returns the target location of the action.
Definition: MoveAction.cpp:17
static const std::chrono::milliseconds getMoveTime()
Get the Move Time object.
MoveAction(std::chrono::system_clock::time_point startTime, Coordinates target, std::shared_ptr< Entity > pEntity)
Definition: MoveAction.cpp:7
Coordinates targetM
Definition: MoveAction.hpp:45
std::vector< std::pair< int, int > > pathM
Definition: MoveAction.hpp:47
std::chrono::milliseconds actionTimeM
Definition: MoveAction.hpp:50
ActionType actionTypeM
Definition: MoveAction.hpp:52
virtual void act()
Movement functionality, which finds the shortest path to target location and performs the movement th...
Definition: MoveAction.cpp:22
std::optional< Coordinates > nextMoveM
Next move to be taken. Stores the first element of pathM, after its deleted. Ww need this to be able ...
Definition: MoveAction.hpp:48
CurrentAction getActionInfo()
Returns information about the current action.
Definition: MoveAction.cpp:55
Struct for coordinates.
Definition: Coordinates.hpp:7