24 enum Side {White=0, Black=1};
    26 #include "SideState.h"    27 #include "SearchAlgorithm.h"    46   void move(
Move m, Side s, Piece promotion=Pawn);
    57   bool inCheck(Side side);
    58   bool inCheckmate(Side side);
    59   bool underAttack(
Square sq, Side side); 
    60   bool rightCastleSquaresFree(Side side);
    61   bool leftCastleSquaresFree(Side side);
    96   bool load(
int minPly, Side toPlay, MoveList &ml, 
long &h);
   101   void save(
int ply, Side toPlay, 
long h, MoveList &ml);
   104   void uncache(Side toPlay);
   112   bool whiteInCheck; 
bool whiteCheckStateCalculated;
   113   bool blackInCheck; 
bool blackCheckStateCalculated;
   114   bool whiteInMate;  
bool whiteMateStateCalculated;
   115   bool blackInMate;  
bool blackMateStateCalculated;
   116   long cachedHash;   
bool hashCalculated;
   117   long cachedHash2;  
bool hash2Calculated;
 void move(Move m, Side s, Piece promotion=Pawn)
 
bool load(int minPly, Side toPlay, MoveList &ml, long &h)
 
bool canCastle(Side side)
 
Square firstPawn(Side s, Bitboard *b=NULL)
 
long heuristic(Side side)
 
void save(int ply, Side toPlay, long h, MoveList &ml)
 
bool isLegal(Move m, Side s)