]> git.sesse.net Git - stockfish/blobdiff - src/types.h
Move zobrist keys out of Position
[stockfish] / src / types.h
index a9aa514c97ab21caf63c0a9355643c0d136148a4..d67b2eea63a411bcda7fccfdc55ec26b2438ea97 100644 (file)
@@ -321,9 +321,21 @@ inline Score apply_weight(Score v, Score w) {
 #undef ENABLE_OPERATORS_ON
 #undef ENABLE_SAFE_OPERATORS_ON
 
+namespace Zobrist {
+
+  extern Key psq[2][8][64]; // [color][pieceType][square]/[piece count]
+  extern Key enpassant[8];  // [file]
+  extern Key castle[16];    // [castleRight]
+  extern Key side;
+  extern Key exclusion;
+
+  void init();
+}
+
+extern Score pieceSquareTable[16][64];
+extern int SquareDistance[64][64];
 extern const Value PieceValueMidgame[17]; // Indexed by Piece or PieceType
 extern const Value PieceValueEndgame[17];
-extern int SquareDistance[64][64];
 
 struct MoveStack {
   Move move;