forked from speed-dreams/speed-dreams-code
fix little bug with cloudtype if rain
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@2631 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 6a39681482030852c64a054b3a4a754d16e81014 Former-commit-id: cb0e41d43e59a1187ec26d83a4ff4c76b7a5afd1
This commit is contained in:
parent
49fd9645be
commit
fd7e64f184
2 changed files with 9 additions and 9 deletions
|
@ -13,13 +13,13 @@
|
|||
void ReStartWeather(void)
|
||||
{
|
||||
int cloud;
|
||||
int Timeday;
|
||||
int Timeday;
|
||||
int rain;
|
||||
int problrain;
|
||||
int probrain;
|
||||
int problrain;
|
||||
int probrain;
|
||||
int rainbool;
|
||||
int resul;
|
||||
int resul2;
|
||||
int resul2;
|
||||
tTrack *track = ReInfo->track;
|
||||
|
||||
srand((unsigned)time(NULL));
|
||||
|
|
|
@ -226,7 +226,7 @@ grInitScene(void)
|
|||
|
||||
//Add the Sun itself
|
||||
//ssgaCelestialBody *bodies[MAX_BODIES] = { NULL };
|
||||
bodies[SUN] = Sky->addBody(NULL, "data/textures/halo.rgba", (2500 / div), skydynamic, true);
|
||||
bodies[SUN] = Sky->addBody(NULL, "data/textures/halo.rgba", (2500 / div), skydynamic, true);
|
||||
GLfloat sunpos1 = 0.0f;
|
||||
GLfloat sunpos2 = 0.0f;
|
||||
int cloudtype = 0;
|
||||
|
@ -281,9 +281,6 @@ grInitScene(void)
|
|||
|
||||
//Add clouds
|
||||
|
||||
if (RainBool > 0)
|
||||
cloudtype = 8;
|
||||
|
||||
if(Timeday > 0)
|
||||
{
|
||||
switch (grTrack->weather)
|
||||
|
@ -301,6 +298,9 @@ grInitScene(void)
|
|||
else
|
||||
cloudtype = grTrack->weather;
|
||||
|
||||
if (RainBool > 0)
|
||||
cloudtype = 8;
|
||||
|
||||
printf("Cloud = %d", cloudtype);
|
||||
|
||||
grCloudLayer *clouds[MAX_CLOUDS] = { NULL };
|
||||
|
@ -312,7 +312,7 @@ grInitScene(void)
|
|||
clouds[0]->setSpeed(60);
|
||||
clouds[0]->setDirection(45);
|
||||
|
||||
/*clouds[1] = Sky->addCloud ("data/textures/scattered.png", 20000, 2500, 400, 400);
|
||||
/*clouds[1] = Sky->addCloud ("data/textures/scattered1.rgba", skydynamic, skydynamic-2000, 400 * div, 400 * div);
|
||||
clouds[1] -> setSpeed (20);
|
||||
clouds[1] -> setDirection (45);
|
||||
|
||||
|
|
Loading…
Reference in a new issue