It's just a seed for a random generator, but it's not used anymore so I should have removed it. Just delete the line and the include file.Don wrote:Then I look and see this:
static RKISS rk;
And not a single reference to it in your code.
Bitboard is just uint64.
pop_lsb is what it says.
Position is what Stockfish calls its position class. Komodo surely has one but it will be a bit different. What must be extracted is:
- number of pieces of particular type and color;
- squares of those pieces for a particuar type and color;
- material signature (the code assumes you already have one, which seems reasonable, which saves the effort of calculating one);
- side to move;
- 50-move counter.
Somewhat tricky is has_repeated(): does the game history since the last reset of the 50-move counter contain two identical positions. I should have added a comment there.
MoveStack, StateInfo and CheckInfo are just things that Stockfish happens to require to generate and make moves. You know how to do this in Komodo.
Zobrist* is used only for calculating the material signature the way Stockfish does it. You should calculate it the way Komodo does it (in calc_key() and calc_key_from_pcs()).
Basically just delete everything you don't understand but keep the comments.