From: H.G. Muller Date: Sun, 27 Nov 2011 21:27:00 +0000 (+0100) Subject: Fix parsing of O-O castling in variant janus X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=8956784f75e9790b059abd9b66b8f2daef2b3e18;p=xboard.git Fix parsing of O-O castling in variant janus The new parser did not realize it meant e1i1 rather than wild e1h1. --- diff --git a/parser.c b/parser.c index 38ae6b7..de9ee25 100644 --- a/parser.c +++ b/parser.c @@ -356,7 +356,7 @@ badMove:// we failed to find algebraic move ff = (BOARD_WIDTH-1)>>1; // this would be d-file if (boards[yyboardindex][rf][ff] == king) { /* ICS wild castling */ - ft = castlingType == 1 ? BOARD_LEFT+1 : BOARD_RGHT-3; + ft = castlingType == 1 ? BOARD_LEFT+1 : (gameInfo.variant == VariantJanus ? BOARD_RGHT-2 : BOARD_RGHT-3); } else { ff = BOARD_WIDTH>>1; // e-file ft = castlingType == 1 ? BOARD_RGHT-2 : BOARD_LEFT+2;