- Timestamp:
- Jul 21, 2011, 5:36:37 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/ai2/src/orxonox/controllers/ArtificialController.h
r8763 r8769 84 84 { return this->botlevel_; } 85 85 static void setAllBotLevel(float level); 86 //WAYPOINT FUNCTIONS 87 void addWaypoint(WorldEntity* waypoint); 88 WorldEntity* getWaypoint(unsigned int index) const; 89 90 inline void setAccuracy(float accuracy) 91 { this->squaredaccuracy_ = accuracy*accuracy; } 92 inline float getAccuracy() const 93 { return sqrt(this->squaredaccuracy_); } 94 void updatePointsOfInterest(std::string name, float distance); 86 95 87 96 protected: … … 149 158 bool bShooting_; 150 159 151 std::map<std::string, int> weaponModes_; //<! Links each "weapon" to it's weaponmode- managed by setupWeapons()152 //std::vector<int> projectiles_; //<! Displays amount of projectiles of each weapon. - managed by setupWeapons()153 160 float botlevel_; //<! Makes the level of a bot configurable. 154 float timeout_; //<! Timeout for rocket usage. (If a rocket misses, a bot should stop using it.)155 156 161 enum Mode {DEFAULT, ROCKET, DEFENCE, MOVING};//TODO; implement DEFENCE, MOVING modes 157 162 Mode mode_; //TODO: replace single value with stack-like implementation: std::vector<Mode> mode_; 158 163 void setPreviousMode(); 164 165 //WEAPONSYSTEM DATA 166 std::map<std::string, int> weaponModes_; //<! Links each "weapon" to it's weaponmode- managed by setupWeapons() 167 //std::vector<int> projectiles_; //<! Displays amount of projectiles of each weapon. - managed by setupWeapons() 168 float timeout_; //<! Timeout for rocket usage. (If a rocket misses, a bot should stop using it.) 159 169 void setupWeapons(); //<! Defines which weapons are available for a bot. Is recalled whenever a bot was killed. 160 170 bool bSetupWorked; //<! If false, setupWeapons() is called. 161 171 int getFiremode(std::string name); 172 173 //WAYPOINT DATA 174 std::vector<WorldEntity*> waypoints_; 175 size_t currentWaypoint_; 176 float squaredaccuracy_; 162 177 }; 163 178 }
Note: See TracChangeset
for help on using the changeset viewer.