#include <global_world_model.h>
Public メソッド | |
GlobalWorldModel () | |
init member variables | |
void | init (const SideID side) |
init with team side info); | |
void | setAudioMemory (boost::shared_ptr< AudioMemory > memory) |
set new audio memory | |
const AudioMemory & | audioMemory () const |
get audio memory | |
void | initFreeformCount () |
init max freeform message count. | |
void | setTeamName (const SideID side, const std::string &name) |
set team name | |
void | setPlayerType (const SideID side, const int unum, const int type) |
update player type info. this method is called when change_player_type message is received. | |
void | updatePlayMode (const GameMode &game_mode, const GameTime ¤t) |
update playmode using heard referee info | |
void | updateAfterSeeGlobal (const GlobalVisualSensor &see_global, const GameTime ¤t) |
update status using analyzed visual info | |
void | incFreeformSendCount () |
increment freeform send count | |
SideID | ourSide () const |
get our team side | |
SideID | theirSide () const |
get opponent team side | |
const std::string & | teamNameLeft () const |
get left team name | |
const std::string & | teamNameRight () const |
get right team name | |
const std::string & | ourTeamName () const |
get our team name | |
const std::string & | theirTeamName () const |
get our team name | |
const GameTime & | time () const |
get last updated time | |
const GameTime & | seeTime () const |
get last see global time | |
const GameMode & | gameMode () const |
get latest playmode info | |
const GlobalBallObject & | ball () const |
get the latest ball data | |
BallStatus | getBallStatus () const |
get the current ball position status | |
const std::list< GlobalPlayerObject > & | players () const |
get all players | |
const std::vector< const GlobalPlayerObject * > & | playersLeft () const |
get left players' pointer | |
const std::vector< const GlobalPlayerObject * > & | playersRight () const |
get right players' pointer | |
const std::vector< const GlobalPlayerObject * > & | teammates () const |
get teammate players' pointer | |
const std::vector< const GlobalPlayerObject * > & | opponents () const |
get opponent players' pointer | |
int | playerTypeChangeCount (const SideID side) const |
get the count of change_player_type message after kickoff | |
int | heteroID (const SideID side, const int unum) const |
get teammate player type Id | |
const std::vector< int > & | playerTypeUsedCount (const SideID side) const |
get the counter of used player type for left team | |
const long & | lastPlayonStart () const |
get the last playon start cycle | |
int | freeformAllowedCount () const |
get the allowed freeform message count | |
int | freeformSendCount () const |
get the freeform message send count | |
bool | canSendFreeform () const |
check if coach can sent the freeform message now. | |
bool | existKickablePlayer () const |
check if kickable player exists or not | |
const GlobalPlayerObject * | getPlayerNearestTo (const Vector2D &point) const |
get player pointer nearest to the specified point | |
std::ostream & | print (std::ostream &os) const |
put all data to the output stream |
void rcsc::GlobalWorldModel::init | ( | const SideID | side | ) |
init with team side info);
side | side character |
void rcsc::GlobalWorldModel::setAudioMemory | ( | boost::shared_ptr< AudioMemory > | memory | ) |
set new audio memory
memory | pointer to the memory instance. This must be a dynamically allocated object. |
const AudioMemory& rcsc::GlobalWorldModel::audioMemory | ( | ) | const [inline] |
get audio memory
void rcsc::GlobalWorldModel::initFreeformCount | ( | ) |
init max freeform message count.
This method is called just after server_param message.
void rcsc::GlobalWorldModel::setTeamName | ( | const SideID | side, | |
const std::string & | name | |||
) |
set team name
side | team side | |
name | team name string |
void rcsc::GlobalWorldModel::setPlayerType | ( | const SideID | side, | |
const int | unum, | |||
const int | type | |||
) |
update player type info. this method is called when change_player_type message is received.
side | player's side | |
unum | player's uniform number | |
type | new player type id |
void rcsc::GlobalWorldModel::updatePlayMode | ( | const GameMode & | game_mode, | |
const GameTime & | current | |||
) |
update playmode using heard referee info
game_mode | analyzed referee info | |
current | current game time |
void rcsc::GlobalWorldModel::updateAfterSeeGlobal | ( | const GlobalVisualSensor & | see_global, | |
const GameTime & | current | |||
) |
update status using analyzed visual info
see_global | analyzed visual info | |
current | current game time |
SideID rcsc::GlobalWorldModel::ourSide | ( | ) | const [inline] |
get our team side
SideID rcsc::GlobalWorldModel::theirSide | ( | ) | const [inline] |
get opponent team side
const std::string& rcsc::GlobalWorldModel::teamNameLeft | ( | ) | const [inline] |
get left team name
const std::string& rcsc::GlobalWorldModel::teamNameRight | ( | ) | const [inline] |
get right team name
const std::string& rcsc::GlobalWorldModel::ourTeamName | ( | ) | const [inline] |
get our team name
const std::string& rcsc::GlobalWorldModel::theirTeamName | ( | ) | const [inline] |
get our team name
const GameTime& rcsc::GlobalWorldModel::time | ( | ) | const [inline] |
get last updated time
const GameTime& rcsc::GlobalWorldModel::seeTime | ( | ) | const [inline] |
get last see global time
const GameMode& rcsc::GlobalWorldModel::gameMode | ( | ) | const [inline] |
const GlobalBallObject& rcsc::GlobalWorldModel::ball | ( | ) | const [inline] |
get the latest ball data
BallStatus rcsc::GlobalWorldModel::getBallStatus | ( | ) | const |
get the current ball position status
const std::list< GlobalPlayerObject >& rcsc::GlobalWorldModel::players | ( | ) | const [inline] |
get all players
const std::vector< const GlobalPlayerObject * >& rcsc::GlobalWorldModel::playersLeft | ( | ) | const [inline] |
get left players' pointer
const std::vector< const GlobalPlayerObject * >& rcsc::GlobalWorldModel::playersRight | ( | ) | const [inline] |
get right players' pointer
const std::vector< const GlobalPlayerObject * >& rcsc::GlobalWorldModel::teammates | ( | ) | const [inline] |
get teammate players' pointer
const std::vector< const GlobalPlayerObject * >& rcsc::GlobalWorldModel::opponents | ( | ) | const [inline] |
get opponent players' pointer
int rcsc::GlobalWorldModel::playerTypeChangeCount | ( | const SideID | side | ) | const [inline] |
get the count of change_player_type message after kickoff
int rcsc::GlobalWorldModel::heteroID | ( | const SideID | side, | |
const int | unum | |||
) | const |
get teammate player type Id
side | side ID of the target player | |
unum | uniform number of the target player |
const std::vector< int >& rcsc::GlobalWorldModel::playerTypeUsedCount | ( | const SideID | side | ) | const [inline] |
get the counter of used player type for left team
const long& rcsc::GlobalWorldModel::lastPlayonStart | ( | ) | const [inline] |
get the last playon start cycle
int rcsc::GlobalWorldModel::freeformAllowedCount | ( | ) | const [inline] |
get the allowed freeform message count
int rcsc::GlobalWorldModel::freeformSendCount | ( | ) | const [inline] |
get the freeform message send count
bool rcsc::GlobalWorldModel::canSendFreeform | ( | ) | const |
check if coach can sent the freeform message now.
bool rcsc::GlobalWorldModel::existKickablePlayer | ( | ) | const |
check if kickable player exists or not
const GlobalPlayerObject * rcsc::GlobalWorldModel::getPlayerNearestTo | ( | const Vector2D & | point | ) | const |
get player pointer nearest to the specified point
point | target point |
std::ostream & rcsc::GlobalWorldModel::print | ( | std::ostream & | os | ) | const |
put all data to the output stream
os | reference to the output stream |