X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fposition.h;h=fafb55f7eb84b6f91e3591e630d7681894e425af;hb=1ae8c59c0bf7cc87d69673de95363bd222ef6642;hp=2568563cb5d335147d700e509a6349ea14f250df;hpb=0855d93de8cf7c68af616a2d5f384a7632470895;p=stockfish diff --git a/src/position.h b/src/position.h index 2568563c..fafb55f7 100644 --- a/src/position.h +++ b/src/position.h @@ -90,7 +90,7 @@ struct StateInfo { Key key, pawnKey, materialKey; int castleRights, rule50, pliesFromNull; Square epSquare; - Value mgValue, egValue; + Score value; Value npMaterial[2]; PieceType capture; @@ -203,6 +203,7 @@ public: // Properties of moves bool pl_move_is_legal(Move m, Bitboard pinned) const; + bool pl_move_is_evasion(Move m, Bitboard pinned) const; bool move_is_check(Move m) const; bool move_is_check(Move m, Bitboard dcCandidates) const; bool move_is_capture(Move m) const; @@ -239,8 +240,7 @@ public: Key get_material_key() const; // Incremental evaluation - Value mg_value() const; - Value eg_value() const; + Score value() const; Value non_pawn_material(Color c) const; Phase game_phase() const; template Value pst_delta(Piece piece, Square from, Square to) const; @@ -513,12 +513,8 @@ inline Value Position::pst_delta(Piece piece, Square from, Square to) const { : EgPieceSquareTable[piece][to] - EgPieceSquareTable[piece][from]); } -inline Value Position::mg_value() const { - return st->mgValue; -} - -inline Value Position::eg_value() const { - return st->egValue; +inline Score Position::value() const { + return st->value; } inline Value Position::non_pawn_material(Color c) const {