Changeset 8978 for code/branches
- Timestamp:
- Dec 14, 2011, 2:15:45 PM (13 years ago)
- Location:
- code/branches/formation/src/orxonox/controllers
- Files:
-
- 2 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/formation/src/orxonox/controllers/AIController.cc
r8965 r8978 118 118 if (this->state_ == SLAVE && this->mode_==ATTACK) 119 119 { 120 if (!this->target_)121 {122 this->searchNewTarget();123 }120 // search enemy 121 random = rnd(maxrand); 122 if (random < 75 && (!this->target_)) 123 this->searchNewTarget(); 124 124 125 125 // next enemy -
code/branches/formation/src/orxonox/controllers/ArtificialController.cc
r8953 r8978 35 35 { 36 36 37 ArtificialController::ArtificialController(BaseObject* creator) : Masterable(creator)37 ArtificialController::ArtificialController(BaseObject* creator) : FormationController(creator) 38 38 { 39 39 -
code/branches/formation/src/orxonox/controllers/ArtificialController.h
r8953 r8978 31 31 32 32 #include "OrxonoxPrereqs.h" 33 #include "controllers/ Masterable.h"33 #include "controllers/FormationController.h" 34 34 35 35 namespace orxonox 36 36 { 37 class _OrxonoxExport ArtificialController : public Masterable37 class _OrxonoxExport ArtificialController : public FormationController 38 38 { 39 39 public: -
code/branches/formation/src/orxonox/controllers/CMakeLists.txt
r8939 r8978 9 9 WaypointPatrolController.cc 10 10 DroneController.cc 11 Masterable.cc11 FormationController.cc 12 12 ) -
code/branches/formation/src/orxonox/controllers/HumanController.cc
r8965 r8978 71 71 /*static*/ const float HumanController::BOOSTING_TIME = 0.1f; 72 72 73 HumanController::HumanController(BaseObject* creator) : Masterable(creator)73 HumanController::HumanController(BaseObject* creator) : FormationController(creator) 74 74 { 75 75 RegisterObject(HumanController); … … 176 176 { 177 177 HumanController::localController_s->controllableEntity_->fire(firemode); 178 //if human fires, set slaves free. See Masterable::forceFreeSlaves()178 //if human fires, set slaves free. See FormationController::forceFreeSlaves() 179 179 if (HumanController::localController_s->state_==MASTER && HumanController::localController_s->mode_==NORMAL) 180 180 { -
code/branches/formation/src/orxonox/controllers/HumanController.h
r8965 r8978 34 34 #include "tools/Timer.h" 35 35 #include "tools/interfaces/Tickable.h" 36 #include " Masterable.h"36 #include "FormationController.h" 37 37 38 38 // tolua_begin … … 41 41 class _OrxonoxExport HumanController 42 42 // tolua_end 43 : public Masterable, public Tickable43 : public FormationController, public Tickable 44 44 { // tolua_export 45 45 public: … … 113 113 Timer boostingTimeout_; // A timer to check whether the player is no longer boosting. 114 114 static const float BOOSTING_TIME; // The time after it is checked, whether the player is no longer boosting. 115 Masterable* tempMaster;115 FormationController* tempMaster; 116 116 117 117 }; // tolua_export
Note: See TracChangeset
for help on using the changeset viewer.