Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 19, 2005, 6:27:06 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: messed things up a bit, try fixing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/world_entities/weapons/weapon_manager.cc

    r4885 r4895  
    7676  }
    7777  this->currConfID = W_CONFIG0;
     78
     79
     80
     81
    7882  this->crosshair = new Crosshair();
    7983
     
    237241{
    238242  Weapon* w;
     243  for (int j = 0; j < 4; ++j )
     244    for(int i = 0; i < W_MAX_SLOTS; ++i)
     245  {
     246    w = this->configs[j].slots[i];
     247    if( w != NULL) w->tick(dt);
     248  }
     249
     250  crosshair->setRotationSpeed(5);
     251}
     252
     253
     254/**
     255 * triggers draw of all weapons in the current weaponconfig
     256 */
     257void WeaponManager::draw()
     258{
     259  Weapon* w;
     260  for (int j = 0; j < 4; ++j )
    239261  for(int i = 0; i < W_MAX_SLOTS; ++i)
    240262  {
    241     w = this->configs[this->currConfID].slots[i];
    242     if( w != NULL) w->tick(dt);
    243   }
    244 
    245   crosshair->setRotationSpeed(5);
    246 }
    247 
    248 
    249 /**
    250  * triggers draw of all weapons in the current weaponconfig
    251  */
    252 void WeaponManager::draw()
    253 {
    254   Weapon* w;
    255   for(int i = 0; i < W_MAX_SLOTS; ++i)
    256   {
    257     w = this->configs[this->currConfID].slots[i];
     263    w = this->configs[j].slots[i];
    258264    if( w != NULL)
    259265      w->draw();
Note: See TracChangeset for help on using the changeset viewer.