--- a/src/Engine.hh Thu Jan 22 00:28:26 2009 +0200
+++ b/src/Engine.hh Thu Jan 22 01:53:05 2009 +0200
@@ -5,11 +5,15 @@
class Engine;
#include "GameState.hh"
-#include "Graphics/Graphics.hh"
-#include "Network/Server.hh"
-#include "Network/Client.hh"
+#include "Configuration.hh"
+#include "Logger.hh"
-#include "Logger.hh"
+// forward-declare component pointer types
+// XXX: move to some kind of Components.hh file?
+namespace graphics { class Graphics; }
+class NetworkServer;
+class NetworkClientConnect;
+class NetworkClient;
/**
* This is the core class that glues all the other components together and runs the main loop
@@ -51,17 +55,23 @@
void setupGame (const TerrainConfig &config);
/**
- * Enable graphics
+ * Enable graphics.
+ *
+ * Requires: GRAPHICS_ENABLED
*/
- void setupGraphics (const graphics::DisplayConfig &config);
+ void setupGraphics (const DisplayConfig &config);
/**
* Setup server, must call setupGame first
+ *
+ * Requires: NETWORK_ENABLED
*/
void setupNetworkServer (const std::string &listen_port);
/**
* Setup client, do *not* call setupGame, configuration comes from the server
+ *
+ * Requires: NETWORK_ENABLED
*/
void setupNetworkClient (const std::string &connect_host, const std::string &connect_port);
@@ -82,9 +92,9 @@
private:
/**
- * Actually start graphics, requires that game_state is now set
+ * Puts graphics into GameView mode, using our GameState and the given player
*/
- void startGraphics (void);
+ void startGameView (LocalPlayer *player);
public:
// get a pointer to our resource manager