85 : m_data(
type | (
Side::NoSide << 10))
92 Q_ASSERT(!
side.isNull());
99 return m_data == other.m_data;
104 return m_data != other.m_data;
109 return m_data < other.m_data;
114 return m_data > other.m_data;
139 return m_data & 0x3FF;
149 m_data =
type | (m_data & 0xC00);
void setSide(Side side)
Definition piece.h:142
bool isWall() const
Definition piece.h:127
bool operator>(const Piece &other) const
Definition piece.h:112
void setType(int type)
Definition piece.h:147
bool isValid() const
Definition piece.h:122
bool operator!=(const Piece &other) const
Definition piece.h:102
bool isEmpty() const
Definition piece.h:117
int type() const
Definition piece.h:137
static const int WallPiece
Definition piece.h:46
static const int NoPiece
Definition piece.h:44
bool operator<(const Piece &other) const
Definition piece.h:107
Side side() const
Definition piece.h:132
bool operator==(const Piece &other) const
Definition piece.h:97
Piece(int type=NoPiece)
Definition piece.h:84
The side or color of a chess player.
Definition side.h:36
bool isNull() const
Definition side.h:89