Changeset 3733 in orxonox.OLD for orxonox/trunk/src/simple_animation.cc
- Timestamp:
- Apr 6, 2005, 11:24:17 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/simple_animation.cc
r3732 r3733 52 52 this->tmpVect = new Vector(); 53 53 this->lastPosition = new Vector(); 54 this->deltaT = 0.2; 54 55 } 55 56 … … 269 270 this->currentFrame = this->frames->nextElement(this->currentFrame); 270 271 this->mode = this->currentFrame->mode; 272 if( this->mode == NEG_EXP) 273 { 274 *this->tmpVect = *this->currentFrame->position - *this->lastFrame->position; 275 deltaT = 1/this->currentFrame->time * logf(1.0 + 100.0/this->tmpVect->len()); 276 } 271 277 } 272 278 … … 286 292 case NEG_EXP: 287 293 *this->tmpVect = *this->currentFrame->position - *this->lastFrame->position; 288 *this->tmpVect = *this->tmpVect * (1 - exp(- this->localTime / this->currentFrame->time));294 *this->tmpVect = *this->tmpVect * (1 - exp(- this->localTime * this->deltaT)); 289 295 this->currentFrame->object->setRelCoor(*this->lastFrame->position + *this->tmpVect); 290 296 *this->lastPosition = *this->tmpVect;
Note: See TracChangeset
for help on using the changeset viewer.