include/Application.h

00001 
00026 #ifndef _GAME_
00027 #define _GAME_
00028 
00029 #include <Level2D.h>
00030 #include <Physics.h>
00031 #include <Graphics.h>
00032 #include <Sound.h>
00033 #include <Haptics.h>
00034 #include <SvgLoader.h>
00035 #include <string>
00036 #include <disableWarnings.h>
00037 
00038 namespace sonus
00039 {
00040 
00061         class Application
00062         {
00063 
00064                 public:
00065 
00070                         Application();
00071 
00076                         ~Application();
00077 
00082                         void            startApplication();
00083 
00084                         Physics*        physics;
00085                         Sound*          sound;
00086                         Graphics*       graphics;
00087                         Haptics*        haptics;
00088                         SvgLoader*      svgLoader;
00089 
00090                 private:
00091 
00096                         void            beginGame();
00097 
00103                         void            playReplay( int no );
00104 
00110                         bool            initNewLevel();
00111 
00112                         bool            hapticsEnabled;
00113 
00114                         bool            applicationFlag;
00115                         bool            gameFlag;
00116                         bool            replayFlag;
00117 
00118                         int                     replayNo;
00119                         int                     levelInterpolationSteps;
00120                         int                     currentLevelIndex;
00121                         int                     totalLevelCount;
00122                         int                     currentViewport;
00123                         int                     gameViewport;
00124                         int                     replayViewport;
00125                         Level2D*        currentLevel;
00126                         Player*         playerPreviousState;
00127                         Player*         playerCurrentState;
00128                         bool            portalSoundPlayed;
00129                         long            levelFinishedTimer;
00130                         std::string     levelNames[ 10 ];
00131                         int                     avgFPS;
00132 
00133                         long            currentTime;
00134                         long            newTime;
00135                         long            deltaTime;
00136                         long            replayT0;
00137                         long            replayT1;
00138                         float           accumulator;
00139                         float           alpha;
00140                         float           dt;
00141                         
00142         };
00143 
00144 }
00145 
00146 #endif

Generated on Tue Aug 26 12:26:54 2008 for sonus by  doxygen 1.5.4