Changeset 1957 in orxonox.OLD for orxonox/trunk/src/shoot_rocket.cc
- Timestamp:
- Jun 16, 2004, 9:43:10 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/shoot_rocket.cc
r1956 r1957 49 49 glPushMatrix(); 50 50 glTranslatef(tmpShoot->xCor, tmpShoot->yCor, tmpShoot->zCor); 51 tmpShoot->age+=step; 51 52 switch (tmpShoot->type) 52 53 { … … 89 90 /* fix2: conditions, that a struct tree can be cut off */ 90 91 /* fix3: more efficent and nicer please */ 91 if (tmpShoot-> yCor - DataTank::yOffset > 20)92 if (tmpShoot->age > tmpShoot->lifetime) 92 93 { 93 94 /* normal case: delete one element, link the others */ … … 151 152 sh->zVel = (1-(float)rand() / 1000000000/step)/5; 152 153 sh->xAcc = 0; sh->yAcc = .01/step; sh->zAcc = 0; 154 sh->age=0; 155 sh->lifetime=5; 153 156 sh->next = lastShoot; 154 157 lastShoot = sh; … … 170 173 } 171 174 sh->xAcc = .9; sh->yAcc = .02; sh->zAcc = 0; 175 sh->age=0; 176 sh->lifetime=10; 172 177 sh->next = lastShoot; 173 178 lastShoot = sh; … … 183 188 sh->type = ROTATER; 184 189 sh->xCor = x+radius*sin(rotateAngle); sh->yCor = y; sh->zCor = z+radius*cos(rotateAngle); 185 sh->xVel = .1*cos(rotateAngle)/step; 186 sh->yVel = 0.4/step; 187 sh->zVel = .1*sin(rotateAngle)/step; 188 sh->xAcc = 1.01; sh->yAcc = 1.01/step; sh->zAcc = 1.01; 190 sh->xVel = 1*cos(rotateAngle)*step; 191 sh->yVel = 4*step; 192 sh->zVel = 1*sin(rotateAngle)*step; 193 sh->xAcc = 1.01; sh->yAcc = 1- step; sh->zAcc = 1.01; 194 sh->age=0; 195 sh->lifetime=10; 189 196 sh->next = lastShoot; 190 197 lastShoot = sh;
Note: See TracChangeset
for help on using the changeset viewer.