mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-15 15:02:16 -07:00
Turn Card, Deck_List, Protocol, RNG, Server, Settings and Utility into libraries and remove cockatrice_common.
Took 6 hours 3 minutes Took 31 seconds
This commit is contained in:
parent
3cff55b0bb
commit
1e4e5a4419
593 changed files with 1913 additions and 1601 deletions
|
|
@ -0,0 +1,33 @@
|
|||
#ifndef SERVER_PLAYER_REFERENCE_H
|
||||
#define SERVER_PLAYER_REFERENCE_H
|
||||
|
||||
class PlayerReference
|
||||
{
|
||||
private:
|
||||
int roomId;
|
||||
int gameId;
|
||||
int playerId;
|
||||
|
||||
public:
|
||||
PlayerReference(int _roomId, int _gameId, int _playerId) : roomId(_roomId), gameId(_gameId), playerId(_playerId)
|
||||
{
|
||||
}
|
||||
int getRoomId() const
|
||||
{
|
||||
return roomId;
|
||||
}
|
||||
int getGameId() const
|
||||
{
|
||||
return gameId;
|
||||
}
|
||||
int getPlayerId() const
|
||||
{
|
||||
return playerId;
|
||||
}
|
||||
bool operator==(const PlayerReference &other)
|
||||
{
|
||||
return ((roomId == other.roomId) && (gameId == other.gameId) && (playerId == other.playerId));
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue