Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8223 in orxonox.OLD for branches/atmospheric_engine/src


Ignore:
Timestamp:
Jun 8, 2006, 9:57:49 AM (18 years ago)
Author:
hdavid
Message:

branches/atmospheric_enc_engine: starting implementation of random raising for the lightening

Location:
branches/atmospheric_engine/src/lib/graphics/effects
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/atmospheric_engine/src/lib/graphics/effects/lightening_effect.cc

    r8179 r8223  
    8181  this->seedZ = 10.0f;
    8282  this->seedTime = 4.0f;
     83 
     84  lightening1 = 1;
     85  lightening2 = 2;
     86  lightening3 = 3;
    8387
    8488  this->billboard[0] = new Billboard(NULL);
     
    160164    //this->soundSource.play(this->thunderBuffer);
    161165  }
    162   else if( this->billboard[3]->isVisible() && this->time > this->flashConstTime)
    163   {
    164     this->billboard[3]->setVisibiliy(false);
     166  else if( this->billboard[lightening3]->isVisible() && this->time > this->flashConstTime)
     167  {
     168    this->billboard[lightening3]->setVisibiliy(false);
    165169    this->time = 0.0f;
    166170    this->bNewCoordinate = true;
    167171  }
    168172
    169   if( this->billboard[2]->isVisible() && this->time > this->flashRisingTime)
    170   {
    171     this->billboard[2]->setVisibiliy(false);
    172     this->billboard[3]->setVisibiliy(true);
    173   }
    174   else if( this->billboard[1]->isVisible() && this->time > this->flashRisingTime*2/3 )
    175   {
    176     this->billboard[1]->setVisibiliy(false);
    177     this->billboard[2]->setVisibiliy(true);
     173  if( this->billboard[lightening2]->isVisible() && this->time > this->flashRisingTime)
     174  {
     175    this->billboard[lightening2]->setVisibiliy(false);
     176    this->billboard[lightening3]->setVisibiliy(true);
     177  }
     178  else if( this->billboard[lightening1]->isVisible() && this->time > this->flashRisingTime*2/3 )
     179  {
     180    this->billboard[lightening1]->setVisibiliy(false);
     181    this->billboard[lightening2]->setVisibiliy(true);
    178182  }
    179183  else if( this->billboard[0]->isVisible() && this->time > this->flashRisingTime*1/3 )
    180184  {
    181185    this->billboard[0]->setVisibiliy(false);
    182     this->billboard[1]->setVisibiliy(true);
     186    this->billboard[lightening1]->setVisibiliy(true);
    183187  }
    184188
  • branches/atmospheric_engine/src/lib/graphics/effects/lightening_effect.h

    r8179 r8223  
    5454    Billboard* billboard[4];
    5555    bool lighteningActivate;
     56    int lightening1;
     57    int lightening2;
     58    int lightening3;
    5659
    5760    float flashFrequency;
Note: See TracChangeset for help on using the changeset viewer.