I just implemented a method in GameState_t called is_ok(), that simply checks if the kings are present, if they are at their designated squares etc..
It also computes a zobrist key, and compares it with the incrementally updated one, and it seems that there is a bug here.
I don't know exactly what it is, but i will do some perft tests to see where it is and then I'll try fixing it before v3.0.0.
It turns out, that it was the update of the zobrist key when making a null-move. I had forgotten to XOR out the potential en-passant square (and XOR it in again after the null-move).
It has been fixed now.
I just implemented a method in GameState_t called is_ok(), that simply checks if the kings are present, if they are at their designated squares etc.. It also computes a zobrist key, and compares it with the incrementally updated one, and it seems that there is a bug here.
I don't know exactly what it is, but i will do some perft tests to see where it is and then I'll try fixing it before v3.0.0.