Main Page | Modules | Namespace List | Class Hierarchy | Compound List | File List | Compound Members | File Members

animation.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002  * $Id: animation.h,v 1.1 2003/07/16 11:42:14 schou Exp $
00003  * Author: Jakob Schou Jensen <schou@sourceforge.net>
00004  * Licence: GPL
00005  *
00006  * Description: Animation
00007  *
00008  ****************************************************************************/
00009 
00015 #ifndef ANIMATION_H
00016 #define ANIMATION_H
00017 
00018 
00019 #define ANIM_MAX_ANIMATIONS 32
00020 
00021 extern float frame_rate;
00022 
00023 void tick(void);
00024 void updateNetbot();
00025 
00028 class TimedAnimation {
00029 public:
00030   virtual void update(double deltaTime) = 0;
00031   virtual TimedAnimation::~TimedAnimation(){}
00032 };
00033 
00037 class PhysicalAnimation {
00038 public:
00039   virtual void update(double deltaTime) = 0; 
00040   virtual PhysicalAnimation::~PhysicalAnimation(){}
00041 };
00042 
00049 class AnimationServer {
00050   TimedAnimation *timedAnimList[ANIM_MAX_ANIMATIONS];
00051   PhysicalAnimation *physAnimList[ANIM_MAX_ANIMATIONS];
00052   int taCount, paCount;
00053 
00054 public:
00055   void addAnimation(TimedAnimation *anim);
00056   void addAnimation(PhysicalAnimation *anim);
00057   void update();
00058 
00059   AnimationServer(){
00060     taCount = 0;
00061     paCount = 0;
00062   }
00063 };
00064 
00065 extern AnimationServer animationServer;
00066 
00067 #endif
00068 

Generated on Mon Jul 21 10:44:47 2003 for Rover by doxygen 1.3.2