Closed Disservin closed 1 year ago
To reproduce
Board b = Board.CreateBoardFromFEN("rn1q1rk1/p1p2ppp/bp1ppn2/8/2PP4/P1N1P3/1P2BPPP/R1BQK2R w KQ - 0 1");
string moves = "e2f3 c7c6 d1b3 a6b7 c3e4 d8c7 e4f6 g7f6 e3e4 c6c5 c1h6 f8c8 h6e3 c5d4 e3d4 c7c4 b3c4 c8c4 d4f6 b8d7 b2b3 c4c5 f6d4 c5b5 a1b1 b5a5 b1a1 d7c5 b3b4 a5a4 d4c5 b6c5 f3d1 a4a6 d1e2 a6b6 b4c5 d6c5 e4e5 f7f6 e5f6 a8f8 e2f3 f8f6 h1g1 e6e5 a1d1 b7f3 g2f3 g8f8 g1g5 f6f3 g5e5 f3a3 d1c1 a3f3 c1c5 b6f6 c5c8 f8f7 c8c2 f7g6 c2a2 f3f4 e5e3 f4f3 e3f3 f6f3 a2a7 f3f5 a7e7 f5f4 e1e2 f4f5 e2f1 f5f4 f1e1 f4f5 e1e2 f5f4 e2e3 f4f5 f2f3 g6h6 e3e4 h6g6 e7e6 f5f6 e6e5 h7h6 e4e3 g6f7 e3d2 f6f3 d2e2 f3h3 e2d1 h3h2 d1c1 f7f6 c1b1 f6e5 b1a1 e5d4 a1b1 d4c3 b1a1 c3c2 a1a2 h2h1 a2a3 c2c3 a3a2";
string[] moves_split = moves.Split(' ');
foreach (string move_str in moves_split)
{
b.MakeMove(new Move(move_str, b));
}
Console.WriteLine(b.GetFenString());
Ah yes, I'll leave this open because it's easier for @SebLague to test.
Hi, thanks for the heads-up! It's not quite as serious as it seems because the fifty move counter is reset correctly with actual game moves (so would only cause problems for super deep searches). Still a weird behaviour though of course, and I will patch it.
Fixed in latest patch, thanks again!
8/8/7p/8/8/2k5/K7/7r b - - 113 57
This is the fen that you will get, as you can see the half moves are incorrect. A rather big bug becauseisDraw()
wont return the correct result. It should be8/8/7p/8/8/2k5/K7/7r b - - 11 57
Here is the pgn in case you need it