Inheritance diagram for RS::AmIFirstToBall:


Public Member Functions | |
| AmIFirstToBall (bool includeTeammates=true, float assumeSpeed=5) | |
| Create a predicate with default behavior. | |
| AmIFirstToBall (const AmIFirstToBall &obj) | |
| Creates a predicate that is an exact copy of obj. | |
| virtual | ~AmIFirstToBall () |
| Destroys the predicate. | |
| AmIFirstToBall & | operator= (const AmIFirstToBall &obj) |
| Assignment operator. | |
| virtual FuzzyBool | operator() () |
| Function application operator. | |
| virtual FuzzyBool | evaluate () |
| Should return the truth value of the predicate. | |
Protected Member Functions | |
| virtual void | update (const UInt32 update_number) |
| The update function, should be used to update the value of the predicate if necessary. | |
Protected Attributes | |
| AgentView * | agentView |
| BallView * | ballView |
| PlayerView * | playerView |
| bool | includeTeammates |
| float | assumedSpeed |
Including opponents only or all visible players in the test is optional. For now, it assumes that all players will keep their speed towards the ball. (The projection of the speed vector on the line towards the ball) It doesn't yet take the ball speed into account.
We will implement another model that doesn't rely that much on the magnitude of speed vector later.
It will calculate the time towards the ball with the function t = (distance to ball)/ (K1 + Project(SpeedVector(Ball) on Vector(Ball to Player)) * S) where K1 is a speed that all players are assumed to have and S is a function that is 1 for all players but the Agent, for which it is dependent on the current stamina level and distance to the ball.
Definition at line 96 of file AmIFirstToBall.h.
|
|
Assignment operator. Assigns obj to this predicate. Definition at line 98 of file AmIFirstToBall.cc. References agentView, assumedSpeed, ballView, includeTeammates, and playerView. |
|
|
Function application operator. Will call evaluate(). Reimplemented from RS::Predicate. Definition at line 55 of file AmIFirstToBall.icc. References evaluate(). |
|
|
The update function, should be used to update the value of the predicate if necessary. The method needUpdate(const UInt32 update_number) can be used to check if the predicate needs to be updated based on the last update number it was updated for. Not used. Implements RS::Predicate. Definition at line 186 of file AmIFirstToBall.cc. |
1.3-rc3