All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
fixedDepthSearcher.cc
Go to the documentation of this file.
1 /* fixedDepthSearcher.cc
2  */
6 
9 hasCheckmateMoveOfTurn(int depth, Move& best_move, PieceStand& proof_pieces)
10 {
11  if (state->turn() == BLACK)
12  return hasCheckmateMove<BLACK>(depth, best_move, proof_pieces);
13  else
14  return hasCheckmateMove<WHITE>(depth, best_move, proof_pieces);
15 }
16 
20 {
21  if (state->turn() == BLACK)
22  return hasCheckmateMove<BLACK>(depth, best_move);
23  else
24  return hasCheckmateMove<WHITE>(depth, best_move);
25 }
26 
29 hasCheckmateWithGuideOfTurn(int depth, Move& guide, PieceStand& proof_pieces)
30 {
31  if (state->turn() == BLACK)
32  return hasCheckmateWithGuide<BLACK>(depth, guide, proof_pieces);
33  else
34  return hasCheckmateWithGuide<WHITE>(depth, guide, proof_pieces);
35 }
36 
40 {
41  if (state->turn() == BLACK)
42  return hasEscapeMove<BLACK>(last_move, depth);
43  else
44  return hasEscapeMove<WHITE>(last_move, depth);
45 }
46 
50  Move& check_move, PieceStand& proof_pieces)
51 {
52  if (state->turn() == BLACK)
53  return hasEscapeByMove<WHITE>(next_move, depth, check_move, proof_pieces);
54  else
55  return hasEscapeByMove<BLACK>(next_move, depth, check_move, proof_pieces);
56 }
57 
61 {
62  if (state->turn() == BLACK)
63  return hasEscapeByMove<WHITE>(next_move, depth);
64  else
65  return hasEscapeByMove<BLACK>(next_move, depth);
66 }
67 
68 /* ------------------------------------------------------------------------- */
69 // ;;; Local Variables:
70 // ;;; mode:c++
71 // ;;; c-basic-offset:2
72 // ;;; End: