Skip to content

Commit

Permalink
hubero_core - FollowObject task: added transition handlers to setup a…
Browse files Browse the repository at this point in the history
…nimations
  • Loading branch information
rayvburn committed Feb 20, 2022
1 parent f08f9cf commit 2ed295e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions hubero_core/include/hubero_core/tasks/task_follow_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,16 @@ class TaskFollowObject: public TaskEssentials<FsmFollowObject, FsmFollowObject::
TaskFollowObject::State::MOVING_TO_GOAL,
std::bind(&TaskFollowObject::thSetupAnimation, this, ANIMATION_WALK)
);
fsm_.addTransitionHandler(
TaskFollowObject::State::MOVING_TO_GOAL,
TaskFollowObject::State::FINISHED,
std::bind(&TaskFollowObject::thSetupAnimation, this, ANIMATION_STAND)
);
fsm_.addTransitionHandler(
TaskFollowObject::State::MOVING_TO_GOAL,
TaskFollowObject::State::WAITING_FOR_MOVEMENT,
std::bind(&TaskFollowObject::thSetupAnimation, this, ANIMATION_STAND)
);
}

virtual bool request(const std::string& object_name) override {
Expand Down

0 comments on commit 2ed295e

Please sign in to comment.