mirror of
https://github.com/peterosterlund2/droidfish.git
synced 2025-12-11 08:32:41 +01:00
Update Stockfish to development version from 2020-06-17
This commit is contained in:
@@ -84,7 +84,7 @@ namespace {
|
||||
template<Color Us>
|
||||
int imbalance(const int pieceCount[][PIECE_TYPE_NB]) {
|
||||
|
||||
constexpr Color Them = (Us == WHITE ? BLACK : WHITE);
|
||||
constexpr Color Them = ~Us;
|
||||
|
||||
int bonus = 0;
|
||||
|
||||
@@ -129,7 +129,7 @@ Entry* probe(const Position& pos) {
|
||||
|
||||
Value npm_w = pos.non_pawn_material(WHITE);
|
||||
Value npm_b = pos.non_pawn_material(BLACK);
|
||||
Value npm = clamp(npm_w + npm_b, EndgameLimit, MidgameLimit);
|
||||
Value npm = Utility::clamp(npm_w + npm_b, EndgameLimit, MidgameLimit);
|
||||
|
||||
// Map total non-pawn material into [PHASE_ENDGAME, PHASE_MIDGAME]
|
||||
e->gamePhase = Phase(((npm - EndgameLimit) * PHASE_MIDGAME) / (MidgameLimit - EndgameLimit));
|
||||
|
||||
Reference in New Issue
Block a user