クラス rcsc::BodySensor

sense_body info holder [詳細]

#include <body_sensor.h>

すべてのメンバ一覧

Public メソッド

 BodySensor ()
 init member variables
void parse (const char *msg, const double &version, const GameTime &current)
 analyze server message
void parse1 (const char *msg, const double &version, const GameTime &current)
 analyze server message usind very ugly style but very fast
void parse2 (const char *msg, const double &version, const GameTime &current)
 analyze server message using std::sscanf.
const GameTimetime () const
 get last updated time
const ViewQualityviewQuality () const
 get analyzed view quality
const ViewWidthviewWidth () const
 get analyzed view width
const double & stamina () const
 get analyzed stamina value
const double & effort () const
 get analyzed effort
const double & speedMag () const
 get analyzed speed value
const double & speedDir () const
 get analyzed velocity direction relative to player's face direction
const double & neckDir () const
 get analyzed neck angle
int kickCount () const
 get analyzed kick count
int dashCount () const
 get analyzed kick count
int turnCount () const
 get analyzed turn count
int sayCount () const
 get analyzed say count
int turnNeckCount () const
 get analyzed turn_neck count
int catchCount () const
 get analyzed catch count
int moveCount () const
 get analyzed move count
int changeViewCount () const
 get analyzed change_view count
int armMovable () const
 get analyzed cycles till the arm is movable
int armExpires () const
 get analyzed cycles till the arm stops pointing
const double & pointtoDist () const
 get analyzed distance to the point that player is pointing
const double & pointtoDir () const
 get analyzed direction relative to player's face
int pointtoCount () const
 get analyzed pointto count
SideID attentiontoSide () const
 get analyzed attended player's side
int attentiontoUnum () const
 get analyzed attended player's uniform number
int attentiontoCount () const
 get analyzed attentionto count
int tackleExpires () const
 get analyzed cycles the current tackle will last for
int tackleCount () const
 get analyzed tackle count
bool noneCollided () const
bool ballCollided () const
 get the information wheter the agent collides with ball
bool playerCollided () const
 get the information wheter the agent collides with player
bool postCollided () const
 get the information wheter the agent collides with posts
std::ostream & print (std::ostream &os) const
 put data to output stream

Public 変数

GameTime M_time
 updated game time
ViewQuality M_view_quality
 sensed view quality
ViewWidth M_view_width
 sensed view width
double M_stamina
 sensed stamina value
double M_effort
 sensed effort value
double M_speed_mag
 sensed speed magnitude. this is quantized by 0.01.
double M_speed_dir_relative
 speed dir. this is relative to face angle.
double M_neck_relative
 neck angle. this is relative to body angle
int M_kick_count
 sensed command count
int M_dash_count
 sensed command count
int M_turn_count
 sensed command count
int M_say_count
 sensed command count
int M_turn_neck_count
 sensed command count
int M_catch_count
 sensed command count
int M_move_count
 sensed command count
int M_change_view_count
 sensed command count
int M_arm_movable
int M_arm_expires
double M_pointto_dist
double M_pointto_dir
int M_pointto_count
 sensed command count
SideID M_attentionto_side
 attended side
int M_attentionto_unum
 attended player number
int M_attentionto_count
 sensed command count
int M_tackle_expires
int M_tackle_count
 sensed command count1
bool M_none_collided
 true if 'none' collides
bool M_ball_collided
 ball collision info
bool M_player_collided
 player collision info
bool M_post_collided
 post collision info


説明

sense_body info holder


関数

void rcsc::BodySensor::parse ( const char *  msg,
const double &  version,
const GameTime current 
) [inline]

analyze server message

引数:
msg raw server message
version client version
current current game time

void rcsc::BodySensor::parse1 ( const char *  msg,
const double &  version,
const GameTime current 
)

analyze server message usind very ugly style but very fast

引数:
msg server message
version client version
current current game time

void rcsc::BodySensor::parse2 ( const char *  msg,
const double &  version,
const GameTime current 
)

analyze server message using std::sscanf.

引数:
msg server message
version client version
current current game time

const GameTime& rcsc::BodySensor::time (  )  const [inline]

get last updated time

戻り値:
const reference to the game time

const ViewQuality& rcsc::BodySensor::viewQuality (  )  const [inline]

get analyzed view quality

戻り値:
const reference to the view quality object

const ViewWidth& rcsc::BodySensor::viewWidth (  )  const [inline]

get analyzed view width

戻り値:
const reference to the view width object

const double& rcsc::BodySensor::stamina (  )  const [inline]

get analyzed stamina value

戻り値:
stamina value

const double& rcsc::BodySensor::effort (  )  const [inline]

get analyzed effort

戻り値:
effort value

const double& rcsc::BodySensor::speedMag (  )  const [inline]

get analyzed speed value

戻り値:
scalar value of velocity

const double& rcsc::BodySensor::speedDir (  )  const [inline]

get analyzed velocity direction relative to player's face direction

戻り値:
velocity direction

const double& rcsc::BodySensor::neckDir (  )  const [inline]

get analyzed neck angle

戻り値:
neck angle value

int rcsc::BodySensor::kickCount (  )  const [inline]

get analyzed kick count

戻り値:
count of performed kick command

int rcsc::BodySensor::dashCount (  )  const [inline]

get analyzed kick count

戻り値:
count of performed kick command

int rcsc::BodySensor::turnCount (  )  const [inline]

get analyzed turn count

戻り値:
count of performed turn command

int rcsc::BodySensor::sayCount (  )  const [inline]

get analyzed say count

戻り値:
count of performed say command

int rcsc::BodySensor::turnNeckCount (  )  const [inline]

get analyzed turn_neck count

戻り値:
count of performed turn_neck command

int rcsc::BodySensor::catchCount (  )  const [inline]

get analyzed catch count

戻り値:
count of performed catch command

int rcsc::BodySensor::moveCount (  )  const [inline]

get analyzed move count

戻り値:
count of performed move command

int rcsc::BodySensor::changeViewCount (  )  const [inline]

get analyzed change_view count

戻り値:
count of performed change_view command

int rcsc::BodySensor::armMovable (  )  const [inline]

get analyzed cycles till the arm is movable

戻り値:
cycles till the arm is movable

int rcsc::BodySensor::armExpires (  )  const [inline]

get analyzed cycles till the arm stops pointing

戻り値:
cycles till the arm is movable

const double& rcsc::BodySensor::pointtoDist (  )  const [inline]

get analyzed distance to the point that player is pointing

戻り値:
distance value

const double& rcsc::BodySensor::pointtoDir (  )  const [inline]

get analyzed direction relative to player's face

戻り値:
direction value

int rcsc::BodySensor::pointtoCount (  )  const [inline]

get analyzed pointto count

戻り値:
count of performed pointto command

SideID rcsc::BodySensor::attentiontoSide (  )  const [inline]

get analyzed attended player's side

戻り値:
side Id

int rcsc::BodySensor::attentiontoUnum (  )  const [inline]

get analyzed attended player's uniform number

戻り値:
uniform number

int rcsc::BodySensor::attentiontoCount (  )  const [inline]

get analyzed attentionto count

戻り値:
count of performed attentionto command

int rcsc::BodySensor::tackleExpires (  )  const [inline]

get analyzed cycles the current tackle will last for

戻り値:
cycles till tackle is exired

int rcsc::BodySensor::tackleCount (  )  const [inline]

get analyzed tackle count

戻り値:
count of performed tackle command

bool rcsc::BodySensor::noneCollided (  )  const [inline]

get the information wheter the agent receive does not collide.

戻り値:
true if this body sensor has 'none' collision information.

bool rcsc::BodySensor::ballCollided (  )  const [inline]

get the information wheter the agent collides with ball

戻り値:
true if the agent collides with ball.

bool rcsc::BodySensor::playerCollided (  )  const [inline]

get the information wheter the agent collides with player

戻り値:
true if the agent collides with player.

bool rcsc::BodySensor::postCollided (  )  const [inline]

get the information wheter the agent collides with posts

戻り値:
true if the agent collides with posts.

std::ostream & rcsc::BodySensor::print ( std::ostream &  os  )  const

put data to output stream

引数:
os reference to the output stream
戻り値:
reference to the output stream


変数

int rcsc::BodySensor::M_arm_movable

the number of cycles till the arm is movable. if 0, arm is movable now

int rcsc::BodySensor::M_arm_expires

the number of cycles till the arm stops pointing. if 0, player is not pointing.

double rcsc::BodySensor::M_pointto_dist

the distance of the point the player is pointing to, relative to the player's position, accurate to 10cm

double rcsc::BodySensor::M_pointto_dir

the direction of the point the player is pointing to, relative to the player's face angle, accurate to 0.1 deg.

int rcsc::BodySensor::M_tackle_expires

the number of cycles the current tackle will last for. if 0, player is not tackling.


このクラスの説明は次のファイルから生成されました:
librcscに対してThu May 1 15:41:26 2008に生成されました。  doxygen 1.5.0