Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 2, 2005, 10:46:36 PM (19 years ago)
Author:
bensch
Message:

orxonox/branches/particleEngine: no more random()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/particleEngine/src/lib/graphics/particles/particle_emitter.cc

    r4001 r4016  
    133133          // emmits from EMITTER_DOT,
    134134          {
    135             Vector randDir = Vector(random()-RAND_MAX/2, random()-RAND_MAX/2, random()-RAND_MAX/2);
     135            Vector randDir = Vector(rand()-RAND_MAX/2, rand()-RAND_MAX/2, rand()-RAND_MAX/2);
    136136            randDir.normalize();
    137             randDir = (this->getAbsDir()*Quaternion(angle + randomAngle *((float)random()/RAND_MAX -.5), randDir)).apply(this->direction);
     137            randDir = (this->getAbsDir()*Quaternion(angle + randomAngle *((float)rand()/RAND_MAX -.5), randDir)).apply(this->direction);
    138138            Vector velocityV = randDir.getNormalized()*this->velocity + inheritVelocity;
    139139           
Note: See TracChangeset for help on using the changeset viewer.