mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
game is almost playable again
This commit is contained in:
parent
0d4717f40b
commit
e796af2b89
34 changed files with 309 additions and 320 deletions
|
|
@ -20,6 +20,18 @@ enum ResponseCode { RespNothing, RespOk, RespInvalidCommand, RespInvalidData, Re
|
|||
// list index, whereas cards in any other zone are referenced by their ids.
|
||||
enum ZoneType { PrivateZone, PublicZone, HiddenZone };
|
||||
|
||||
class ColorConverter {
|
||||
public:
|
||||
static int colorToInt(const QColor &color)
|
||||
{
|
||||
return color.red() * 65536 + color.green() * 256 + color.blue();
|
||||
}
|
||||
static QColor colorFromInt(int colorValue)
|
||||
{
|
||||
return QColor(colorValue / 65536, (colorValue % 65536) / 256, colorValue % 256);
|
||||
}
|
||||
};
|
||||
|
||||
class SerializableItem {
|
||||
protected:
|
||||
SerializableItem *currentItem;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue