00001 #ifndef DAMERULES_HPP 00002 #define DAMERULES_HPP 00003 00004 #include "Rules2D.hpp" 00005 00006 #include "Game/Boards/DameBoard.hpp" 00007 00008 class DameRules : public Rules<DameBoard>, public Rules2D 00009 { 00010 private: 00011 00012 public: 00013 static const unsigned int NB_PLAYERS = 2; 00014 00015 void init(DameBoard& cb); 00016 00017 bool check(const DameBoard& cb, Move<ChessBoard::Coords>& move)const; 00018 00019 bool isCheck(const DameBoard& cb, const int color)const; 00020 bool checkVictory(const DameBoard& cb, const int color)const; 00021 00022 bool checkDraw(const History<Move<DameBoard::Coords> >& history)const; 00023 void move(const DameBoard& cb, const Move<DameBoard::Coords>& move); 00024 }; 00025 00032 #endif