Created a NetworkGameObserver class able to extend the serialization code of GameObserver to synchronize and forward game actions on the network
Fixes in GameObserver serialization/deserialization code Fixes in JNetwork and JSocket on windows Various code cleanup (currentGamePhase access in particular) Updated GUI code to re-enable a basic network GUI Activated threaded tests on Windows. It uses 4 threads by default.
This commit is contained in:
@@ -15,7 +15,7 @@ protected:
|
||||
static ProxyPlayer* mInstance;
|
||||
public:
|
||||
ProxyPlayer(Player* pxPlayer, JNetwork* pxNetwork);
|
||||
static void Serialize(istream& in, ostream& out);
|
||||
static void Serialize(void*, stringstream& in, stringstream& out);
|
||||
};
|
||||
|
||||
|
||||
@@ -25,8 +25,8 @@ protected:
|
||||
JNetwork* mpNetwork;
|
||||
static RemotePlayer* mInstance;
|
||||
public:
|
||||
RemotePlayer(JNetwork*);
|
||||
static void Deserialize(istream& in, ostream& out);
|
||||
RemotePlayer(GameObserver* observer, JNetwork*);
|
||||
static void Deserialize(void*, stringstream& in, stringstream& out);
|
||||
bool isLoaded() {return game!=NULL;};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user