mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 03:57:45 +00:00
Rename piece_count and piece_list
No functional change.
This commit is contained in:
+4
-4
@@ -1332,7 +1332,7 @@ Key Position::compute_material_key() const {
|
||||
|
||||
for (Color c = WHITE; c <= BLACK; c++)
|
||||
for (PieceType pt = PAWN; pt <= QUEEN; pt++)
|
||||
for (int cnt = 0; cnt < piece_count(c, pt); cnt++)
|
||||
for (int cnt = 0; cnt < pieceCount[c][pt]; cnt++)
|
||||
k ^= Zobrist::psq[c][pt][cnt];
|
||||
|
||||
return k;
|
||||
@@ -1368,7 +1368,7 @@ Value Position::compute_non_pawn_material(Color c) const {
|
||||
Value value = VALUE_ZERO;
|
||||
|
||||
for (PieceType pt = KNIGHT; pt <= QUEEN; pt++)
|
||||
value += piece_count(c, pt) * PieceValue[MG][pt];
|
||||
value += pieceCount[c][pt] * PieceValue[MG][pt];
|
||||
|
||||
return value;
|
||||
}
|
||||
@@ -1558,10 +1558,10 @@ bool Position::pos_is_ok(int* failedStep) const {
|
||||
for (PieceType pt = PAWN; pt <= KING; pt++)
|
||||
for (int i = 0; i < pieceCount[c][pt]; i++)
|
||||
{
|
||||
if (piece_on(piece_list(c, pt)[i]) != make_piece(c, pt))
|
||||
if (board[pieceList[c][pt][i]] != make_piece(c, pt))
|
||||
return false;
|
||||
|
||||
if (index[piece_list(c, pt)[i]] != i)
|
||||
if (index[pieceList[c][pt][i]] != i)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user