X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fsearch.cpp;h=9244ce3dc7bbb8d13402ec25171498229f514216;hp=81f96ccdc74162d7ac63e1b37eece83b23ad9a60;hb=a9782b94e640d3a35b597758ff1d5f0e56465666;hpb=351ef5c85b6d4b9c71e9da367f0be5ab6e6f8117 diff --git a/src/search.cpp b/src/search.cpp index 81f96ccd..9244ce3d 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -300,7 +300,7 @@ namespace { if (moveIsCheck && pos.see_sign(m) >= 0) result += CheckExtension[PvNode]; - if (pos.type_of_piece_on(move_from(m)) == PAWN) + if (type_of_piece(pos.piece_on(move_from(m))) == PAWN) { Color c = pos.side_to_move(); if (relative_rank(c, move_to(m)) == RANK_7) @@ -316,7 +316,7 @@ namespace { } if ( captureOrPromotion - && pos.type_of_piece_on(move_to(m)) != PAWN + && type_of_piece(pos.piece_on(move_to(m))) != PAWN && ( pos.non_pawn_material(WHITE) + pos.non_pawn_material(BLACK) - piece_value_midgame(pos.piece_on(move_to(m))) == VALUE_ZERO) && !move_is_special(m)) @@ -1666,7 +1666,7 @@ split_point_start: // At split points actual search starts from here // value of the threatening piece, don't prune moves which defend it. if ( pos.move_is_capture(threat) && ( piece_value_midgame(pos.piece_on(tfrom)) >= piece_value_midgame(pos.piece_on(tto)) - || pos.type_of_piece_on(tfrom) == KING) + || type_of_piece(pos.piece_on(tfrom)) == KING) && pos.move_attacks_square(m, tto)) return true;