From f794b9ee52293cefd6ac73fdf0d2a01c5388f057 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Thu, 31 Jan 2008 18:22:44 +0000 Subject: modular system works now --- src/game/game.h | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) (limited to 'src/game/game.h') diff --git a/src/game/game.h b/src/game/game.h index f2a0eab..ee9e286 100644 --- a/src/game/game.h +++ b/src/game/game.h @@ -7,17 +7,26 @@ #ifndef __INCLUDED_GAME_H__ #define __INCLUDED_GAME_H__ +// project headers #include "game/ship.h" #include "game/star.h" - +#include "core/core.h" #include "common/common.h" -/// the game engine -/** - * The main game functions. The console should be initialized before calling these. +/// the game-specific engine +/** The main game functions. The console should be initialized before calling these. */ namespace game { + +/// the only ship in the game +extern Ship ship; + +/// the only star in the game +extern Star star; + +class Game : public core::Game { +public: /// initialize the game void init(); @@ -25,17 +34,10 @@ namespace game void shutdown(); /// update the game state - void update(float elapsed); - - /// the only ship in the game - extern Ship ship; - - /// the only star in the game - extern Star star; - - /// true while the game is running - extern bool initialized; + void frame(float sec); }; +} + #endif // __INCLUDED_GAME_H__ -- cgit v1.2.3