Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3855 in orxonox.OLD for orxonox/trunk/src/t_animation.h


Ignore:
Timestamp:
Apr 17, 2005, 2:46:27 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: animation of weapon reimplemented (but only with Linear interpolation.
doxy-tags

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/t_animation.h

    r3854 r3855  
    5454  //  ANIM_FUNCTION animFunc;
    5555  float (tAnimation<T>::*animFunc)(float) const;  //!< A Function for the AnimationType
     56
    5657  KeyFrameF* currentKeyFrame;                     //!< The current KeyFrame
    5758  KeyFrameF* nextKeyFrame;                        //!< The KeyFrame we iterate to
     
    247248
    248249// animation functions
    249 
    250 /**
    251    \brief some random animation (fluctuating)
    252    \param timePassed The time passed since this Keyframe began
    253 */
    254 template<class T>
    255 float tAnimation<T>::random(float timePassed) const
    256 {
    257   return this->currentKeyFrame->value * (float)rand()/(float)RAND_MAX;
    258 }
    259 
    260250/**
    261251   \brief stays at the value of the currentKeyFrame
     
    345335}
    346336
     337/**
     338   \brief some random animation (fluctuating)
     339   \param timePassed The time passed since this Keyframe began
     340*/
     341template<class T>
     342float tAnimation<T>::random(float timePassed) const
     343{
     344  return this->currentKeyFrame->value * (float)rand()/(float)RAND_MAX;
     345}
    347346
    348347#endif /* _T_ANIMATION_H */
Note: See TracChangeset for help on using the changeset viewer.