- reworked completly the JNetwork, JSocket interface (had to ifdef out the PSP socket code)
- added 2 menus to wait for connection and wait for deck selection - tested compilation on Qt Linux, Qt Windows and PSP - deactivated everywhere (NETWORK_SUPPORT to activate).
This commit is contained in:
33
projects/mtg/include/NetworkPlayer.h
Normal file
33
projects/mtg/include/NetworkPlayer.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef NETWORKPLAYER_H
|
||||
#define NETWORKPLAYER_H
|
||||
|
||||
#include "PrecompiledHeader.h"
|
||||
#include "Player.h"
|
||||
#include "JNetwork.h"
|
||||
|
||||
extern void RegisterNetworkPlayers();
|
||||
|
||||
class ProxyPlayer
|
||||
{
|
||||
protected:
|
||||
Player* mpPlayer;
|
||||
JNetwork* mpNetwork;
|
||||
static ProxyPlayer* mInstance;
|
||||
public:
|
||||
ProxyPlayer(Player* pxPlayer, JNetwork* pxNetwork);
|
||||
static void Serialize(istream& in, ostream& out);
|
||||
};
|
||||
|
||||
|
||||
class RemotePlayer : public Player
|
||||
{
|
||||
protected:
|
||||
JNetwork* mpNetwork;
|
||||
static RemotePlayer* mInstance;
|
||||
public:
|
||||
RemotePlayer(JNetwork*);
|
||||
static void Deserialize(istream& in, ostream& out);
|
||||
bool isLoaded() {return game!=NULL;};
|
||||
};
|
||||
|
||||
#endif // NETWORKPLAYER_H
|
||||
Reference in New Issue
Block a user