From d4ebe9b5f28a3669819eecf0888ac5095aba0669 Mon Sep 17 00:00:00 2001 From: H.G.Muller Date: Mon, 11 Jan 2016 11:35:22 +0100 Subject: [PATCH] Correct backup pieces for addition of minor Lion The added piece type was not put in the list of backup pieces, so that the pieces beyond it got out of phase, and no backup for the Prince would be found, leading to an error popup about missing default pieces. The error message on this has now been improved to mention the piece casing the trouble. --- draw.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/draw.c b/draw.c index 81f5392..b88d53d 100644 --- a/draw.c +++ b/draw.c @@ -298,7 +298,7 @@ char *pngPieceNames[] = // must be in same order as internal piece encoding }; char *backupPiece[] = { "Princess", NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, "King", "Queen", "Lion" }; // pieces that map on other when not kanji RsvgHandle * @@ -373,7 +373,7 @@ ScaleOnePiece (int color, int piece) if(!(svgPieces[color][piece] = LoadSVG(svgDir, color, piece, 0)) // try to fall back on installed svg && !warned && strcmp(pngPieceNames[piece], "Tile")) { // but do not complain about missing 'Tile' char *msg = _("No default pieces installed!\nSelect your own using '-pieceImageDirectory'."); - printf("%s\n", msg); // give up + printf("%s (%s)\n", msg, pngPieceNames[piece]); // give up DisplayError(msg, 0); warned = 1; // prevent error message being repeated for each piece type } -- 1.7.0.4