Suppress use of promo-Gold bitmaps in Tori Shogi (WB)
authorH.G.Muller <hgm@hgm-xboard.(none)>
Sun, 28 Sep 2014 09:18:10 +0000 (11:18 +0200)
committerH.G.Muller <hgm@hgm-xboard.(none)>
Sun, 28 Sep 2014 20:14:28 +0000 (22:14 +0200)
In Tori Shogi the Swallow Pawn does not promote to Tokin, so the use
of a Gold General pictogram would only be confusing. So we stick to
the regular fairy bitmaps in Tori, which is recognized by the board
having 7 ranks in Shogi.

winboard/winboard.c

index db317ce..d0eb772 100644 (file)
@@ -2690,7 +2690,7 @@ InitDrawingSizes(BoardSize boardSize, int flags)
     pieceBitmap[1][WhiteLion] = DoLoadBitmap(hInst, "ln", squareSize, "o");\r
     pieceBitmap[2][WhiteLion] = DoLoadBitmap(hInst, "ln", squareSize, "w");\r
 \r
-    if(gameInfo.variant == VariantShogi) { /* promoted Gold represemtations */\r
+    if(gameInfo.variant == VariantShogi && BOARD_HEIGHT != 7) { /* promoted Gold representations (but not in Tori!)*/\r
       pieceBitmap[0][WhiteCannon] = DoLoadBitmap(hInst, "wp", squareSize, "s");\r
       pieceBitmap[1][WhiteCannon] = DoLoadBitmap(hInst, "wp", squareSize, "o");\r
       pieceBitmap[2][WhiteCannon] = DoLoadBitmap(hInst, "w", squareSize, "w");\r
@@ -5740,6 +5740,7 @@ WndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
     return (DefWindowProc(hwnd, message, wParam, lParam));\r
   }\r
 \r
+\r
   return 0;\r
 }\r
 \r