From: Fabian Fichter Date: Fri, 3 Apr 2020 21:57:04 +0000 (+0200) Subject: Consider Janggi cannon restrictions in evaluation X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=2ffdf8ba25f8c12b504af17a10b418f0607b8ee0;p=fairystockfish.git Consider Janggi cannon restrictions in evaluation janggi LLR: 2.99 (-2.94,2.94) [0.00,10.00] Total: 694 W: 364 L: 260 D: 70 --- diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 638789f..12c7067 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -321,6 +321,12 @@ namespace { score -= make_score(PieceValue[MG][Pt], PieceValue[EG][Pt]) / 3; } + if (Pt == JANGGI_CANNON) + { + b &= ~pos.pieces(Pt); + b &= attacks_bb(Us, Pt, s, pos.pieces() ^ pos.pieces(Pt)); + } + if (pos.blockers_for_king(Us) & s) b &= LineBB[pos.square(Us)][s];