src/proto2/Engine.hh
changeset 21 32c6cc55256a
child 22 b70d30e1b0fe
equal deleted inserted replaced
20:f6dc5967c49c 21:32c6cc55256a
       
     1 
       
     2 #include "NetworkServer.hh"
       
     3 #include "NetworkClient.hh"
       
     4 
       
     5 class Engine {
       
     6 	private:
       
     7 		// game state
       
     8 		GameState game_state;
       
     9 		
       
    10 		// network server/client
       
    11 		NetworkServer *net_server;
       
    12 		NetworkClient *net_client;
       
    13 
       
    14 		// to exit the mainloop
       
    15 		bool is_running;
       
    16 		
       
    17 		// default constructor
       
    18 		Engine (void);
       
    19 
       
    20 	public:
       
    21 		static void runNetworkServer (const std::string &listen_port);
       
    22 		static void runNetworkClient (const std::string &connect_host, const std::string &connect_port);
       
    23 	
       
    24 	private:
       
    25 		void main_loop (void);
       
    26 
       
    27 };