Fix using VariantMen PGN tag for both colors
authorH.G.Muller <hgm@hgm-xboard.(none)>
Sat, 6 Feb 2016 17:18:29 +0000 (18:18 +0100)
committerH.G.Muller <hgm@hgm-xboard.(none)>
Sat, 6 Feb 2016 17:18:29 +0000 (18:18 +0100)
Black pieces were not recognized as the same as white pieces.

moves.c

diff --git a/moves.c b/moves.c
index 0b6b9b4..bd516de 100644 (file)
--- a/moves.c
+++ b/moves.c
@@ -256,7 +256,7 @@ LoadPieceDesc (char *s)
            if(pieceToChar[piece] != '+') { ok = FALSE; continue; } // promoted form does not exist
        }
        ASSIGN(pieceDesc[piece], p);
-       if(piece < BlackPawn && (pieceToChar[WHITE_TO_BLACK piece] == pieceToChar[piece] || promoted)) {
+       if(piece < BlackPawn && (pieceToChar[WHITE_TO_BLACK piece] == pieceToChar[piece] + 32 || promoted)) {
            ASSIGN(pieceDesc[WHITE_TO_BLACK piece], p);
        }
        pieceDefs = TRUE;