Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 27, 2006, 5:26:04 PM (19 years ago)
Author:
hdavid
Message:

branches/mountain_lake: fading sky/cloud colors works, RainEffect::stopRaining is a bit buggy

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/mountain_lake/src/lib/graphics/effects/rain_effect.cc

    r8793 r8837  
    103103  this->rainFadeOutDuration = 0;
    104104 
    105   this->cloudColor = Vector(0.8f, 0.8f, 0.8f);
     105  this->cloudColor = Vector(0.6f, 0.6f, 0.6f);
    106106  this->skyColor = Vector(0.0f, 0.0f, 0.0f);
    107107
     
    180180  if (this->rainWindForce != 0)
    181181    this->soundSource.play(this->windBuffer, 0.1f * this->rainWindForce, true);
    182 
    183   if (this->rainFadeInDuration == 0)
    184     lightMan->setAmbientColor(.1,.1,.1);
    185182 
    186183  // Change the cloudcolor,skycolor
    187184  this->oldCloudColor = CloudEffect::cloudColor;
    188185  this->oldSkyColor = CloudEffect::skyColor;
    189   CloudEffect::changeCloudColor(this->cloudColor);
    190   CloudEffect::changeSkyColor(this->skyColor);
     186  CloudEffect::changeCloudColor(this->cloudColor, this->rainFadeInDuration);
     187  CloudEffect::changeSkyColor(this->skyColor, this->rainFadeInDuration);
    191188}
    192189
     
    207204  lightMan->setAmbientColor(this->rainAmbient, this->rainAmbient, this->rainAmbient);
    208205 
    209   CloudEffect::changeCloudColor(this->oldCloudColor);
    210   CloudEffect::changeSkyColor(this->oldSkyColor);
     206  CloudEffect::changeCloudColor(this->oldCloudColor, this->rainFadeOutDuration);
     207  CloudEffect::changeSkyColor(this->oldSkyColor, this->rainFadeOutDuration);
    211208}
    212209
     
    291288
    292289  if (!this->rainFadeInDuration > 0)
    293     this->rainFadeInDuration = 20;
     290    this->rainFadeInDuration = 10;
    294291
    295292  this->localTimer = 0;
     
    308305
    309306  if (!this->rainFadeOutDuration > 0)
    310     this->rainFadeOutDuration = 20;
     307    this->rainFadeOutDuration = 10;
    311308
    312309  this->localTimer = 0;
Note: See TracChangeset for help on using the changeset viewer.