summaryrefslogtreecommitdiffstats
path: root/source/Concept/Framework/modules/logic/logic.h
diff options
context:
space:
mode:
authorsicarius <devnull@localhost>2007-02-26 22:25:01 +0100
committersicarius <devnull@localhost>2007-02-26 22:25:01 +0100
commitf61eb900879fe941460a284ff9e4681b0958b944 (patch)
treee32e6e091b0d025e071f3eab1dbf52c04d107d1d /source/Concept/Framework/modules/logic/logic.h
parent343397ecf6e8ba9ca94fc61e27c241139eff120b (diff)
downloadrc2007-soccer-f61eb900879fe941460a284ff9e4681b0958b944.tar
rc2007-soccer-f61eb900879fe941460a284ff9e4681b0958b944.zip
SoccerTeam, Stuff from Magdeburg
Diffstat (limited to 'source/Concept/Framework/modules/logic/logic.h')
-rwxr-xr-xsource/Concept/Framework/modules/logic/logic.h23
1 files changed, 21 insertions, 2 deletions
diff --git a/source/Concept/Framework/modules/logic/logic.h b/source/Concept/Framework/modules/logic/logic.h
index ad8bad7..031e0b6 100755
--- a/source/Concept/Framework/modules/logic/logic.h
+++ b/source/Concept/Framework/modules/logic/logic.h
@@ -12,6 +12,8 @@ public:
this->moduleId = 0;
this->isKeeper = false;
this->status = 0;
+ this->hasBall = false;
+ this->avoidsObstacle = false;
}
Logic(uint32 logicId)
@@ -20,16 +22,29 @@ public:
this->moduleId = logicId;
this->isKeeper = false;
this->status = 0;
+ this->hasBall = false;
+ this->avoidsObstacle = false;
}
protected:
bool isKeeper;
uint8 status;
+ bool hasBall;
+ bool avoidsObstacle;
enum LogicalStatus
{
STATUS_KEEPER_TURN_RIGHT,
STATUS_KEEPER_TURN_LEFT,
+ STATUS_KEEPER_RETURN_HOME,
+ STATUS_KEEPER_HUNT_BALL,
+ STATUS_KEEPER_TURN_TO_BALL,
+ STATUS_KEEPER_DRIVE_TO_DEFEND,
+
+ STATUS_ATTACKER_TURN_TO_BALL,
+ STATUS_ATTACKER_DRIVE_TO_BALL,
+ STATUS_ATTACKER_SEARCHING_AT_HOME,
+ STATUS_ATTACKER_SEARCHING_AT_ENEMY,
};
void OnBallOwned();
@@ -51,7 +66,8 @@ public:
return !isKeeper;
}
- void SetKeeper(bool newStatus) {
+ void SetKeeper(bool newStatus)
+ {
if(!this->isKeeper && newStatus)
{
this->OnBecomeKeeper();
@@ -65,8 +81,11 @@ public:
bool HasBall()
{
- //fill me!
+ return this->hasBall;
}
+
+ void UpdateKeeperMovement();
+ void UpdateAttackerMovement();
};
#endif