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

📄 worldmodel.h

📁 机器足球2D比赛程序 对trlen_base_2002的改进
💻 H
📖 第 1 页 / 共 3 页
字号:
				ObjectSetT     g,				double         dConf = -1.0      );		ObjectT       iterateObjectNext          ( int            &iIndex,				ObjectSetT     g,				double         dConf = -1.0      );		void          iterateObjectDone          ( int            &iIndex           );		// get and set methods for agent information		ObjectT       getAgentObjectType         (                            ) 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;		ViewAngleT    getAgentViewAngle          (                            ) const;		ViewQualityT  getAgentViewQuality        (                            ) const;		double        getAgentViewFrequency      ( ViewAngleT     va = VA_ILLEGAL,				ViewQualityT   vq = VQ_ILLEGAL   );		// 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                 );		// set methods for objects		bool          setIsKnownPlayer           ( ObjectT        o,				bool           isKnownPlayer     );		bool          setTimeLastSeen            ( ObjectT        o,				Time           time              );		// get method for information about goals		VecPosition   getPosOpponentGoal         (                                  );		VecPosition   getPosOwnGoal              (                                  );		double        getRelDistanceOpponentGoal (                                  );		AngDeg        getRelAngleOpponentGoal    (                                  );		// get methods about fixed specifications (heterogeneous players)		HeteroPlayerSettings getInfoHeteroPlayer ( int iIndex                       );		// get method about previous commands		bool          isQueuedActionPerformed    (                                  );		// methodst hat 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       );  		SideT         getSidePenalty             (                                  );		bool          setSidePenalty             ( SideT          side              );		////////////////////////// UPDATE METHODS (WorldModelUpdate.C) ////////////////		// processing new information about the objects (filling World Model).		void          processSeeGlobalInfo       ( ObjectT        o,				Time           time,				VecPosition    pos,				VecPosition    vel,				AngDeg         angBody,				AngDeg         angNeck           );		bool          processNewAgentInfo        ( ViewQualityT   vq,				ViewAngleT     va,				double         dStamina,				double         dEffort,				double         dSpeed,				AngDeg         angSpeed,				AngDeg         angHeadAngle      );		void           processNewObjectInfo       ( ObjectT        o,				Time           time,				double         dDist,				int            iDir,				double         dDistChange,				double         dDirChange,				AngDeg         angRelBodyAng,				AngDeg         angRelNeckAng,				bool           isGoalie,				ObjectT        objMin,				ObjectT        objMax            );		bool           processPerfectHearInfo     ( ObjectT        o,				VecPosition    pos,				double         dConf,				bool           bIsGoalie=0       );		bool           processPerfectHearInfoBall ( VecPosition    pos,				VecPosition    vel,				double         dConf             );		bool           processUnsureHearInfo      ( ObjectT        o,				VecPosition    pos,				double         dConf             );		bool           processNewHeteroPlayer     ( int            iIndex,				double         dPlayerSpeedMax,				double         dStaminaIncMax,				double         dPlayerDecay,				double         dInertiaMoment,				double         dDashPowerRate,				double         dPlayerSize,				double         dKickableMargin,				double         dKickRand,				double         dExtraStamina,				double         dEffortMax,				double         dEffortMin        );		void          processCatchedBall         ( RefereeMessageT rm,				Time           time              );		void          processQueuedCommands      ( SoccerCommand  commands[],				int            iCommands         );		bool          storePlayerMessage         ( int            iPlayer, 				char           *strMsg, 				int            iCycle            ); 		bool          processPlayerMessage       (                                  );                                                                                          		// update methods (defined in WorldModelUpdate.C)		bool          updateAll                  (                                  );	private:       		// update with new visual information		void          processLastSeeMessage      (                                  );		bool          updateAfterSeeMessage      (                                  );		bool          updateAgentObjectAfterSee  (                                  );		bool          updateDynamicObjectAfterSee( ObjectT        o                 );		// update with prediction for new cycle		bool          updateAfterSenseMessage    (                                  );		bool          updateAgentAndBallAfterSense(                                 );		bool          updateBallAfterKick        ( double         dPower,				AngDeg         ang               );		bool          updateDynamicObjectForNextCycle( ObjectT    o,				int            iCycle            );		bool          updateBallForCollision     ( VecPosition    posAgent          );		// update from relative to global and vice versa		bool          updateRelativeFromGlobal   (                                  );		bool          updateObjectRelativeFromGlobal( ObjectT     o                 );		// methods to determine agent state from perceived information		bool          calculateStateAgent        ( VecPosition    *posGlobal,				VecPosition    *velGlobal,				AngDeg         *angGlobal        );		void          initParticlesAgent         ( AngDeg         angGlobal         );		void          initParticlesAgent         ( VecPosition    posInitital       );		int           checkParticlesAgent        ( AngDeg         angGlobalNeck     );		void          updateParticlesAgent       ( VecPosition    vel,				bool           bAfterSense       );		VecPosition   averageParticles           ( VecPosition    posArray[],				int            iLength           );		void          resampleParticlesAgent     ( int            iLeft             );		bool          calculateStateAgent2       ( VecPosition    *posGlobal,				VecPosition    *velGlobal,				AngDeg         *angGlobal        );		VecPosition   calculatePosAgentWith2Flags( ObjectT        objFlag1,				ObjectT        objFlag2          );		AngDeg        calculateAngleAgentWithPos ( VecPosition    pos               );		// methods to determine ball state from perceived information		bool          calculateStateBall         ( VecPosition    *posGlobal,				VecPosition    *velGlobal        );		void          initParticlesBall         (  VecPosition    posArray[],				VecPosition    velArray[],				int            iLength           );		void          checkParticlesBall        (  VecPosition    posArray[],				VecPosition    velArray[],				int            iLength,				int            *iNrLeft          );		void          updateParticlesBall       (  VecPosition    posArray[],				VecPosition    velArray[],				int            iLength,				double         dPower,				AngDeg         ang               );		void          resampleParticlesBall      ( VecPosition    posArray[],				VecPosition    velArray[],				int            iLength,				int            iLeft             );		ObjectT       getMaxRangeUnknownPlayer   ( ObjectT        obj, 				char*          strMsg            );		VecPosition   calculateVelocityDynamicObject( ObjectT     o                 );		bool          calculateStateBall2        ( VecPosition    *posGlobal,				VecPosition    *velGlobal        );		// methods to determine player state from perceived information		bool          calculateStatePlayer       ( ObjectT        o,				VecPosition    *posGlobal,				VecPosition    *velGlobal        );		// methods to calculate noise range (quantized noise)		bool          getMinMaxDistQuantizeValue ( double         dInput,				double         *dMin,				double         *dMax,				double         x1,				double         x2                );

⌨️ 快捷键说明

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