]> git.sesse.net Git - stockfish/blobdiff - src/move.cpp
Evaluate: rename king attack variables
[stockfish] / src / move.cpp
index 2de102dff058e8af955d205cade269f04e485776..d09c3052c7c981c6eeca55b01bb491e7ee8f627c 100644 (file)
@@ -81,9 +81,9 @@ Move move_from_string(const Position &pos, const std::string &str) {
       SquareDelta delta = (to > from)? DELTA_E : DELTA_W;
       Square s;
       for(s = from + delta;
-          pawn_rank(us, s) == RANK_1 && pos.piece_on(s) != rook_of_color(us);
+          relative_rank(us, s) == RANK_1 && pos.piece_on(s) != rook_of_color(us);
           s += delta);
-      if(pawn_rank(us, s) == RANK_1 && pos.piece_on(s) == rook_of_color(us))
+      if(relative_rank(us, s) == RANK_1 && pos.piece_on(s) == rook_of_color(us))
         return make_castle_move(from, s);
     }
   }