⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 worldmodel.h

📁 University of Amsterdam的2003年robocup源程序代码
💻 H
📖 第 1 页 / 共 4 页
字号:
  // heterogeneous player information  set<ObjectT>  m_setSubstitutedOpp;    /*!< Set of substituted opp players. */    // upcoming view angle/quality  SoccerCommand m_changeViewCommand;    /*!< last sent change_view command   */    // side of penalty shootout  SideT         m_sidePenalty;public:  bool          m_bWasCollision;        /*!<Indicates whether it is collision*/  Time          m_timeLastCollision;    /*!< Last collision time             */  // statistics  int           iNrHoles;                /*!< nr of holes recorded           */  int           iNrOpponentsSeen;        /*!< total nr of opponents seen     */  int           iNrTeammatesSeen;        /*!< total nr of teammates seen     */  // last received messages  char          strLastSeeMessage  [MAX_MSG];  /*!< Last see message         */  char          strLastSenseMessage[MAX_MSG];  /*!< Last sense_body message  */  char          strLastHearMessage [MAX_MSG];  /*!< Last hear message        */  /***************************************************************************/  /*************************** OPERATIONS ************************************/  /***************************************************************************/  ////////////////////////// DIRECT RETRIEVAL (WorldModel.C) //////////////////private:  // private methods  Object*       getObjectPtrFromType       ( ObjectT        o           );public:  // get and set methods of attributes in WorldModel itself  void          setTimeLastCatch           ( Time           time        );  int           getTimeSinceLastCatch      (                            );  bool          setTimeLastRefereeMessage  ( Time           time        );  Time          getTimeLastRefereeMessage  (                            );  Time          getCurrentTime             (                            );  int           getCurrentCycle            (                            );  bool          isTimeStopped              (                            );  bool          isLastMessageSee           (                            )const;  Time          getTimeLastSeeGlobalMessage(                            )const;  bool          setTimeLastSeeGlobalMessage( Time           time        );  Time          getTimeLastSeeMessage      (                            )const;  Time          getTimeLastRecvSeeMessage  (                            )const;  bool          setTimeLastSeeMessage      ( Time           time        );  Time          getTimeLastSenseMessage    (                            )const;  Time          getTimeLastRecvSenseMessage(                            )const;  bool          setTimeLastSenseMessage    ( Time           time        );  Time          getTimeLastHearMessage     (                            )const;  bool          setTimeLastHearMessage     ( Time           time        );  int           getPlayerNumber            (                            )const;  bool          setPlayerNumber            ( int            i           );  SideT         getSide                    (                            )const;  bool          setSide                    ( SideT          s           );  const char*   getTeamName                (                            )const;  bool          setTeamName                ( char           *str        );  PlayModeT     getPlayMode                (                            )const;  bool          setPlayMode                ( PlayModeT      pm          );  int           getGoalDiff                (                            )const;  int           addOneToGoalDiff           (                            );  int           subtractOneFromGoalDiff    (                            );  int           getNrOfCommands            ( CommandT       c           )const;  bool          setNrOfCommands            ( CommandT       c,                                             int            i           );  Time          getTimeCheckBall           (                            )const;  bool          setTimeCheckBall           ( Time           time        );  BallStatusT   getCheckBallStatus         (                            )const;  bool          setCheckBallStatus         ( BallStatusT    bs          );  bool          getRecvThink               (                            );  char*         getCommunicationString     (                            );  bool          setCommunicationString     ( char*          srt         );  ObjectT       getObjectFocus             (                            );  bool          setObjectFocus             ( ObjectT        obj         );  // iterate over a specific object set  ObjectT       iterateObjectStart         ( int            &iIndex,                                             ObjectSetT     g,                                             double         dConf = -1.0,					     bool           bForward = false );  ObjectT       iterateObjectNext          ( int            &iIndex,                                             ObjectSetT     g,                                             double         dConf = -1.0,					     bool           bForward = false );  void          iterateObjectDone          ( int            &iIndex          );  // get and set methods for agent information  ObjectT       getAgentObjectType         (                            )const;  int           getAgentIndex              (                            )const;  bool          setAgentObjectType         ( ObjectT        o           );  AngDeg        getAgentBodyAngleRelToNeck (                            )const;  AngDeg        getAgentGlobalNeckAngle    (                            )const;  AngDeg        getAgentGlobalBodyAngle    (                            );  Stamina       getAgentStamina            (                            )const;  TiredNessT    getAgentTiredNess          (                            )const;  double        getAgentEffort             (                            )const;  VecPosition   getAgentGlobalVelocity     (                            )const;  double        getAgentSpeed              (                            )const;  VecPosition   getAgentGlobalPosition     (                            )const;  bool          setAgentViewAngle          ( ViewAngleT     va          ) ;  ViewAngleT    getAgentViewAngle          (                            )const;  bool          setAgentViewQuality        ( ViewQualityT   vq          ) ;    ViewQualityT  getAgentViewQuality        (                            )const;  double        getAgentViewFrequency      ( ViewAngleT     va = VA_ILLEGAL,                                             ViewQualityT   vq = VQ_ILLEGAL  );  bool          getAgentArmMovable         (                                 );  VecPosition   getAgentArmPosition        (                                 );  int           getAgentArmExpires         (                                 );  // get methods for ball information  VecPosition   getBallPos                 (                                 );  double        getBallSpeed               (                                 );  AngDeg        getBallDirection           (                                 );  // get method for different information about a specific object  Time          getTimeGlobalPosition      ( ObjectT        o                );  VecPosition   getGlobalPosition          ( ObjectT        o                );  Time          getTimeGlobalVelocity      ( ObjectT        o                );  VecPosition   getGlobalVelocity          ( ObjectT        o                );  double        getRelativeDistance        ( ObjectT        o                );  VecPosition   getRelativePosition        ( ObjectT        o                );  AngDeg        getRelativeAngle           ( ObjectT        o,                                             bool           bWithBody = false);  Time          getTimeGlobalAngles        ( ObjectT        o                );  AngDeg        getGlobalBodyAngle         ( ObjectT        o                );  AngDeg        getGlobalNeckAngle         ( ObjectT        o                );  AngDeg        getGlobalAngle             ( ObjectT        o                );  double        getConfidence              ( ObjectT        o                );  bool          isKnownPlayer              ( ObjectT        o                );  ObjectT       getOppGoalieType           (                                 );  ObjectT       getOwnGoalieType           (                                 );  Time          getTimeLastSeen            ( ObjectT        o                );  Time          getTimeChangeInformation   ( ObjectT        o                );  VecPosition   getGlobalPositionLastSee   ( ObjectT        o                );  Time          getTimeGlobalPositionLastSee( ObjectT       o                );  VecPosition   getGlobalVelocityLastSee   ( ObjectT        o                );  AngDeg        getGlobalBodyAngleLastSee  ( ObjectT        o                );  int           getTackleExpires           ( ObjectT        o =OBJECT_ILLEGAL);  AngDeg        getGlobalArmDirection      ( ObjectT        o                );  Time          getTimeGlobalArmDirection  ( ObjectT        o                );  double        getProbTackleSucceeds      ( ObjectT        o = OBJECT_ILLEGAL,					     int            iExtraCycles = 0,                                             VecPosition    *pos = NULL      );  double        getProbTackleClosestOpp    ( int            iExtraCycles = 0 );  list<ObjectT> getListCloseOpponents      ( VecPosition    pos,                                             double         dDist = 15       );  // set methods for objects  bool          setIsKnownPlayer           ( ObjectT        o,                                             bool           isKnownPlayer    );  bool          setTimeLastSeen            ( ObjectT        o,                                             Time           time             );  bool          setHeteroPlayerType        ( ObjectT        o,                                             int            iPlayer          );  // formation information  PlayerT       getPlayerType              ( ObjectT        o =OBJECT_ILLEGAL);  bool          isInPlayerSet              ( ObjectT        o,					     PlayerSetT     ps               );                                                 // get method for information about goals  VecPosition   getPosOpponentGoal         (                                 );  VecPosition   getPosOwnGoal              (                                 );  double        getRelDistanceOpponentGoal (                                 );  AngDeg        getRelAngleOpponentGoal    (                                 );  ObjectT       getLastOpponentDefender    ( double         *dX = NULL       );  // get and methods about fixed specifications (heterogeneous players)  HeteroPlayerSettings getInfoHeteroPlayer ( int            iIndex           );  HeteroPlayerSettings getHeteroInfoPlayer ( ObjectT        obj              );  int           getHeteroPlayerType        ( ObjectT        obj              );  bool          setSubstitutedOpp          ( ObjectT        obj              );  ObjectT       getSubstitutedOpp          (                                 );  double        getDashPowerRate           ( ObjectT        obj              );  double        getPlayerSpeedMax          ( ObjectT        obj              );  double        getPlayerDecay             ( ObjectT        obj              );  double        getMaximalKickDist         ( ObjectT        obj              );  double        getStaminaIncMax           ( ObjectT        obj              );  double        getPlayerSize              ( ObjectT        obj              );  double        getInertiaMoment           ( ObjectT        obj              );  double        getEffortMax               ( ObjectT        obj              );  double        getEffectiveMaxSpeed       ( ObjectT        obj,					     bool           bWithNoise =false);  // get method about previous commands  bool          isQueuedActionPerformed    (                                 );  // methods that return truth values about current play mode  bool          isFreeKickUs               (  PlayModeT pm = PM_ILLEGAL      );  bool          isFreeKickThem             (  PlayModeT pm = PM_ILLEGAL      );  bool          isCornerKickUs             (  PlayModeT pm = PM_ILLEGAL      );  bool          isCornerKickThem           (  PlayModeT pm = PM_ILLEGAL      );  bool          isOffsideUs                (  PlayModeT pm = PM_ILLEGAL      );  bool          isOffsideThem              (  PlayModeT pm = PM_ILLEGAL      );  bool          isKickInUs                 (  PlayModeT pm = PM_ILLEGAL      );  bool          isKickInThem               (  PlayModeT pm = PM_ILLEGAL      );  bool          isFreeKickFaultUs          (  PlayModeT pm = PM_ILLEGAL      );  bool          isFreeKickFaultThem        (  PlayModeT pm = PM_ILLEGAL      );  bool          isKickOffUs                (  PlayModeT pm = PM_ILLEGAL      );  bool          isKickOffThem              (  PlayModeT pm = PM_ILLEGAL      );  bool          isBackPassUs               (  PlayModeT pm = PM_ILLEGAL      );  bool          isBackPassThem             (  PlayModeT pm = PM_ILLEGAL      );  bool          isGoalKickUs               (  PlayModeT pm = PM_ILLEGAL      );  bool          isGoalKickThem             (  PlayModeT pm = PM_ILLEGAL      );  bool          isBeforeKickOff            (  PlayModeT pm = PM_ILLEGAL      );  bool          isDeadBallUs               (  PlayModeT pm = PM_ILLEGAL      );  bool          isDeadBallThem             (  PlayModeT pm = PM_ILLEGAL      );  bool          isPenaltyUs                (  PlayModeT pm = PM_ILLEGAL      );  bool          isPenaltyThem              (  PlayModeT pm = PM_ILLEGAL      );  bool          isFullStateOn              (  SideT     s  = SIDE_ILLEGAL    );  // various methods  bool          setChangeViewCommand       ( SoccerCommand  soc              );  SoccerCommand getChangeViewCommand       (                                 );  SideT         getSidePenalty             (                                 );  bool          setSidePenalty             ( SideT          side             );

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -