Changeset 3685 in orxonox.OLD for orxonox/trunk/src/world_entities/projectile.cc
- Timestamp:
- Mar 30, 2005, 11:04:39 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world_entities/projectile.cc
r3683 r3685 37 37 this->flightDirection = NULL; 38 38 this->currentLifeTime = 0.0f; 39 this->ttl = 1.0f;39 this->ttl = 0.75f; /* sec */ 40 40 this->speed = 2.0f; 41 41 } … … 89 89 void Projectile::setSpeed(float speed) 90 90 { 91 this->speed = speed * 5;92 printf("Projectile::setting speed to: %f\n", this->speed);91 this->speed = speed * 3; 92 PRINTF(4)("Projectile::setting speed to: %f\n", this->speed); 93 93 } 94 94 … … 99 99 void Projectile::tick (float time) 100 100 { 101 this->speed = this->weapon->getSpeed() * 5;101 this->speed = this->weapon->getSpeed() * 3; 102 102 this->shiftCoor(*this->flightDirection * this->speed * time); 103 printf("current speed is: %f\n", this->speed);103 //printf("current speed is: %f\n", this->speed); 104 104 105 105 this->currentLifeTime += time; 106 if( this->ttl > this->currentLifeTime) 107 this->finalize(); 106 if( this->ttl < this->currentLifeTime) 107 { 108 PRINTF(5)("FINALIZE=============================================================\n"); 109 PRINTF(5)("current life time is: %f/%f\n", this->currentLifeTime, this->ttl); 110 PRINTF(5)("FINALIZE=============================================================\n"); 111 this->finalize(); 112 } 108 113 } 109 114
Note: See TracChangeset
for help on using the changeset viewer.