Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 14, 2011, 10:29:18 PM (13 years ago)
Author:
jo
Message:

Code clean up.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/ai2/src/orxonox/controllers/AIController.cc

    r8736 r8758  
    196196                    this->bShooting_ = false;
    197197
     198                //boost
     199                random = rnd(maxrand);
     200                if (random < botlevel_*100 )
     201                    this->boostControl(); //TEST
    198202            }
    199203        }
     
    205209        if (!this->isActive())
    206210            return;
    207         if(this->bDeathFlag_)//If a bot died recently, make him check his weaponsystem.
    208         {
    209             this->bSetupWorked = false;
    210             this->numberOfWeapons = 0;
    211             this->resetDeathFlag();
    212         }
    213         this->boostControl();//TEST
     211
    214212        float random;
    215213        float maxrand = 100.0f / ACTION_INTERVAL;
     
    229227                            random = rnd(maxrand);
    230228                            if(this->botlevel_*100 > random)
    231                                 this->follow();//If a bot is shooting a player, it shouldn't let him go away easily.
     229                                this->follow();  //If a bot is shooting a player, it shouldn't let him go away easily.
    232230                        }
    233231                    }
     
    277275        else if (this->mode_ == ROCKET)//Rockets do not belong to a group of bots -> bot states are not relevant.
    278276        {   //Vector-implementation: mode_.back() == ROCKET;
    279             ControllableEntity *controllable = this->getControllableEntity(); 
     277            ControllableEntity *controllable = this->getControllableEntity();
    280278            if(controllable)
    281279            {
Note: See TracChangeset for help on using the changeset viewer.