22 #include "MABodyLying.hpp" 24 #include "types/MABodyMotion.hpp" 25 #include "types/MAComplexIndicators.hpp" 26 #include "types/MAGoals.hpp" 27 #include "types/MARobotState.hpp" 28 #include "controllers/MALegController.hpp" 29 #include "MABodyLyingBored.hpp" 30 #include "MABodyLyingHappyTalk.hpp" 31 #include "MALegLyingPosition.hpp" 32 #include "MALegMoved.hpp" 33 #include "MALookForAbyss.hpp" 34 #include "MATailToBack.hpp" 44 if (MA::RobotState->BodyMotion->OnStation || MA::RobotState->BodyMotion->Lying > 80)
54 return MA::RobotState->BodyMotion->Lying < 20 && !MA::RobotState->BodyMotion->OnStation;
61 if (MA::RobotState->ComplexIndicators->AbyssWhileLying < 0)
65 if (MA::RobotState->Goals->DesireLyingOnTheFloor > 0)
71 if (!MA::RobotState->LegLF->Moving)
72 MA::LegLF->SetPower(
false);
73 if (!MA::RobotState->LegRF->Moving)
74 MA::LegRF->SetPower(
false);
75 if (!MA::RobotState->LegLH->Moving)
76 MA::LegLH->SetPower(
false);
77 if (!MA::RobotState->LegRH->Moving)
78 MA::LegRH->SetPower(
false);
83 MALEGBEHAVIOR_CREATE(
MALegMoved, MA::Leg::LF,
this);
84 MALEGBEHAVIOR_CREATE(
MALegMoved, MA::Leg::LH,
this);
85 MALEGBEHAVIOR_CREATE(
MALegMoved, MA::Leg::RF,
this);
86 MALEGBEHAVIOR_CREATE(
MALegMoved, MA::Leg::RH,
this);
Move the tail to the back behavior.
virtual void ActivatingActions() override
Perform actions when the behavior is being activated.
virtual MABehavior::StimulusLevelType GetCurrentStimulus() override
Get the current behavior stimulus.
Move a leg to lying position.
#define MABEHAVIOR_CREATE(_behavior, _master,...)
Create behaviors with custom constructor safely.
std::string MCGetClassName(T *instance=nullptr, const std::string &name_suffix="")
Get a class name.
The leg is being moved on its own.
Look for abyss before the dog.
virtual bool IsFailed() override
Whether the behavior is failed.
Talking when the dog goes to lying after flying or upside down.
Body lying bored behavior.