home *** CD-ROM | disk | FTP | other *** search
/ MORE WinGames / WINGAMES.iso / chess / chess.h < prev    next >
C/C++ Source or Header  |  1991-02-03  |  5KB  |  168 lines

  1. /*
  2.   C source for GNU CHESS
  3.  
  4.   Revision: 1990-09-30
  5.   Modified by Daryl Baker for use in MS WINDOWS environment
  6.  
  7.   This file is part of CHESS.
  8.  
  9.   CHESS is distributed in the hope that it will be useful, but WITHOUT ANY
  10.   WARRANTY.  No author or distributor accepts responsibility to anyone for
  11.   the consequences of using it or for whether it serves any particular
  12.   purpose or works at all, unless he says so in writing.  Refer to the CHESS
  13.   General Public License for full details.
  14.  
  15.   Everyone is granted permission to copy, modify and redistribute CHESS, but
  16.   only under the conditions described in the CHESS General Public License.
  17.   A copy of this license is supposed to have been given to you along with
  18.   CHESS so you can know your rights and responsibilities.  It should be in a
  19.   file named COPYING.  Among other things, the copyright notice and this
  20.   notice must be preserved on all copies.
  21. */
  22.  
  23. struct PIECEBITMAP {
  24.    HBITMAP piece;
  25.    HBITMAP mask;
  26.    HBITMAP outline;
  27. };
  28.  
  29. #define BLACK 1
  30. #define WHITE 2
  31.  
  32. #define NETURAL 2
  33.  
  34. #define PAWNBASE 0
  35. #define PAWN   1
  36. #define KNIGHT 2
  37. #define BISHOP 3
  38. #define ROOK   4
  39. #define QUEEN  5
  40. #define KING   6
  41.  
  42. #define PAWNM   7
  43. #define KNIGHTM 8
  44. #define BISHOPM 9
  45. #define ROOKM   10
  46. #define QUEENM  11
  47. #define KINGM   12
  48.  
  49. #define PAWNO   13
  50. #define KNIGHTO 14
  51. #define BISHOPO 15
  52. #define ROOKO   16
  53. #define QUEENO  17
  54. #define KINGO   18
  55.  
  56. #define ID_ABOUT  (WM_USER+1)
  57.  
  58. #define MSG_CHESS_NEW     (WM_USER+2)
  59. #define MSG_CHESS_LIST    (WM_USER+3)
  60. #define MSG_CHESS_GET     (WM_USER+4)
  61. #define MSG_CHESS_SAVE    (WM_USER+5)
  62. #define MSG_CHESS_QUIT    (WM_USER+6)
  63. #define MSG_CHESS_HASH    (WM_USER+7)
  64. #define MSG_CHESS_BEEP    (WM_USER+8)
  65. #define MSG_CHESS_BOTH    (WM_USER+9)
  66. #define MSG_CHESS_POST    (WM_USER+10)
  67. #define MSG_CHESS_AWIN    (WM_USER+11)
  68. #define MSG_CHESS_BWIN    (WM_USER+12)
  69. #define MSG_CHESS_CONTEMP (WM_USER+13)
  70. #define MSG_CHESS_UNDO    (WM_USER+14)
  71. #define MSG_CHESS_ABOUT   (WM_USER+15)
  72.  
  73. #define MSG_CHESS_COORD   (WM_USER+16)
  74. #define MSG_CHESS_REVIEW  (WM_USER+17)
  75. #define MSG_CHESS_TEST    (WM_USER+18)
  76. #define MSG_CHESS_BOOK    (WM_USER+19)
  77.  
  78. #define MSG_CHESS_RANDOM  (WM_USER+25)
  79. #define MSG_CHESS_EASY    (WM_USER+26)
  80. #define MSG_CHESS_DEPTH   (WM_USER+27)
  81. #define MSG_CHESS_REVERSE (WM_USER+28)
  82. #define MSG_CHESS_SWITCH  (WM_USER+29)
  83. #define MSG_CHESS_BLACK   (WM_USER+30)
  84. #define MSG_CHESS_WHITE   (WM_USER+31)
  85.                                     
  86. #define MSG_EDITBOARD     (WM_USER+32)
  87. #define ID_EDITDONE       (WM_USER+33)
  88.  
  89. #define MSG_CHESS_EDIT    (WM_USER+34)
  90. #define MSG_CHESS_EDITDONE (WM_USER+24)
  91.  
  92. #define MSG_USER_MOVE      (WM_USER+35)
  93. #define MSG_USER_ENTERED_MOVE (WM_USER+36)
  94. #define MSG_COMPUTER_MOVE  (WM_USER+37)
  95.  
  96. #define MSG_CHESS_HINT     (WM_USER+38)
  97. #define MSG_CHESS_REMOVE   (WM_USER+39)
  98. #define MSG_CHESS_FORCE    (WM_USER+40)
  99. #define MSG_MANUAL_ENTRY_POINT    (WM_USER+41)
  100.  
  101. #define MSG_HELP_INDEX     (WM_USER+50)
  102. #define MSG_HELP_HELP      (WM_USER+51)
  103.  
  104. #define MSG_DESTROY     (WM_USER+60)
  105. #define MSG_WM_COMMAND  (WM_USER+61)
  106.  
  107. #define IDM_BACKGROUND  300
  108. #define IDM_BLACKSQUARE 301
  109. #define IDM_WHITESQUARE 302
  110. #define IDM_BLACKPIECE  303
  111. #define IDM_WHITEPIECE  304
  112. #define IDM_DEFAULT     305
  113. #define IDM_TEXT        307
  114.  
  115. #define IDM_TIMECONTROL 306
  116.  
  117. /* Resource definitions */
  118.  
  119. #define AboutBox    262
  120. #define REVIEW      263
  121. #define NUMBERDLG   264
  122. #define COLOR       266
  123. #define TIMECONTROL 267
  124. /*#define STATS     268*/
  125. #define TEST        269
  126. /*#define FILESAVE  270*/     /* Defined in saveopen.h */
  127. /*#define FILEOPEN  271*/
  128. /*#define WILDFILEOPEN 272*/
  129. #define PAWNPROMOTE 273
  130. #define MANUALDLG   274
  131.  
  132.  
  133. /* String Definitions */
  134.  
  135. #define IDS_ILLEGALMOVE   1000     /* Illeagal move */
  136. #define IDS_AMBIGUOUSMOVE 1001    /* Ambigous move */
  137. #define IDS_OBAE          1002    /* Opening book allocation error */
  138. #define IDS_OBNF          1003    /* Opening Book not found */
  139. #define IDS_UNABLESAVE    1004    /* Unable to save game*/
  140. #define IDS_UNABLELIST    1005    /* Unable to list game */
  141. #define IDS_CHESS         1006    /* Chess */
  142. #define IDS_DRAWGAME      1007    /* Draw Game */
  143. #define IDS_YOUWIN        1008    /* You win */
  144. #define IDS_COMPUTERWIN   1009    /* Computer wins */
  145. #define IDS_MATESOON      1010    /* You will soon mate */
  146. #define IDS_COMPMATE      1011    /* Computer will soon mate */
  147. #define IDS_TTABLEAF      1012    /* ttable Allocation Failed*/
  148. #define IDS_SQDATAAF      1013    /* sqdata Allocation Failed*/
  149. #define IDS_HISTORYAF     1014    /* History Allocation Failed*/
  150. #define IDS_TREEAF        1016    /* Tree Allocation Failed*/
  151. #define IDS_GAMEAF        1017    /* Game List Allocation Failed*/
  152. #define IDS_LOADFAILED    1018
  153. #define IDS_SETAWIN       1019
  154. #define IDS_SETBWIN       1020
  155. #define IDS_SETCONTEMPT   1021
  156. #define IDS_MAXSEARCH     1022
  157. #define IDS_INITERROR     1023
  158.  
  159. #define MENU_ID_FILE      0
  160. #define MENU_ID_EDIT      1
  161. #define MENU_ID_OPTIONS   2
  162. #define MENU_ID_SKILL     3
  163. #define MENU_ID_SIDE      4
  164. #define MENU_ID_HINT      5
  165. #define MENU_ID_ABORT     6
  166.  
  167.  
  168.