home *** CD-ROM | disk | FTP | other *** search
/ Giga Games 1 / Giga Games.iso / net / usenet / volume11 / reve / patch4d < prev    next >
Encoding:
Internet Message Format  |  1991-01-03  |  48.6 KB

  1. Path: uunet!zephyr.ens.tek.com!tekred!saab!billr
  2. From: billr@saab.CNA.TEK.COM (Bill Randle)
  3. Newsgroups: comp.sources.games
  4. Subject: v12i013:  reve - an othello game, Patch4d
  5. Message-ID: <6771@tekred.CNA.TEK.COM>
  6. Date: 21 Dec 90 20:56:37 GMT
  7. Sender: news@tekred.CNA.TEK.COM
  8. Lines: 1439
  9. Approved: billr@saab.CNA.TEK.COM
  10.  
  11. Submitted-by: Rich Burridge <rburridge@sun.COM>
  12. Posting-number: Volume 12, Issue 13
  13. Archive-name: reve/Patch4d
  14. Patch-To: reve: Volume 11, Issue 52-58
  15. Environment: SunView, XView, X11R4, termcap
  16.  
  17.  
  18.  
  19. #! /bin/sh
  20. # This is a shell archive.  Remove anything before this line, then unpack
  21. # it by saving it into a file and typing "sh file".  To overwrite existing
  22. # files, type "sh file -c".  You can also feed this as standard input via
  23. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  24. # will see the following message at the end:
  25. #        "End of archive 4 (of 4)."
  26. # Contents:  patches04d
  27. # Wrapped by billr@saab on Fri Dec 21 11:36:12 1990
  28. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  29. if test -f 'patches04d' -a "${1}" != "-c" ; then 
  30.   echo shar: Will not clobber existing file \"'patches04d'\"
  31. else
  32. echo shar: Extracting \"'patches04d'\" \(46589 characters\)
  33. sed "s/^X//" >'patches04d' <<'END_OF_FILE'
  34. X
  35. X------- items.c -------
  36. X*** /tmp/da06882    Tue Dec 18 10:10:23 1990
  37. X--- items.c    Mon Dec 17 10:24:06 1990
  38. X***************
  39. X*** 40,45 ****
  40. X--- 40,46 ----
  41. X  
  42. X    x = items[(int) item].x ;
  43. X    y = items[(int) item].y ;
  44. X+   if (x == -1 && y == -1) return ;
  45. X    if (iscolor[(int) cur_dpyno])
  46. X      {
  47. X        draw_stencil(wtype, x, y, BWIDTH, BHEIGHT, RSRC, color,
  48. X***************
  49. X*** 50,56 ****
  50. X                      BUT_STENCIL, image) ;
  51. X    label = items[(int) item].text ;
  52. X    if (image == BUT_INVERT) color = C_WHITE ;
  53. X!   else                     color = C_BLACK ;
  54. X    x += ((BWIDTH - get_strwidth(NFONT, label)) / 2) ;
  55. X    y += (nfont_height + (BHEIGHT - nfont_height) / 2) - 5 ;
  56. X    draw_text(wtype, x, y, NFONT, color, label) ;
  57. X--- 51,57 ----
  58. X                      BUT_STENCIL, image) ;
  59. X    label = items[(int) item].text ;
  60. X    if (image == BUT_INVERT) color = C_WHITE ;
  61. X!   else                     color = C_TEXT ;
  62. X    x += ((BWIDTH - get_strwidth(NFONT, label)) / 2) ;
  63. X    y += (nfont_height + (BHEIGHT - nfont_height) / 2) - 5 ;
  64. X    draw_text(wtype, x, y, NFONT, color, label) ;
  65. X***************
  66. X*** 64,75 ****
  67. X  int color ;
  68. X  {
  69. X    char *str ;
  70. X!   int height, i, maxw, val, width, x, xoff, y ;
  71. X  
  72. X    if (strlen(items[(int) item].label))
  73. X      draw_text(items[(int) item].wtype,
  74. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  75. X!               BFONT, C_BLACK, items[(int) item].label) ;
  76. X  
  77. X    maxw = 0 ;
  78. X    for (i = 0; i < items[(int) item].nopts; i++)
  79. X--- 65,77 ----
  80. X  int color ;
  81. X  {
  82. X    char *str ;
  83. X!   int height, i, maxw, tcol, val, width, x, xoff, y ;
  84. X  
  85. X+   tcol = B_COLOR(C_TEXT) ;
  86. X    if (strlen(items[(int) item].label))
  87. X      draw_text(items[(int) item].wtype,
  88. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  89. X!               BFONT, tcol, items[(int) item].label) ;
  90. X  
  91. X    maxw = 0 ;
  92. X    for (i = 0; i < items[(int) item].nopts; i++)
  93. X***************
  94. X*** 100,109 ****
  95. X        xoff = (maxw - val) / 2 ;
  96. X        draw_text(items[(int) item].wtype,
  97. X                  x + (i * maxw) + xoff,
  98. X!                 y + nfont_height + (nfont_height / 2), NFONT, C_BLACK, str) ;
  99. X      }
  100. X  
  101. X    val = items[(int) item].value ;
  102. X    draw_rect(wtype,
  103. X              x + (val * maxw) + 1, y + 1,
  104. X              x + ((val + 1) * maxw) - 1, y + height - 1, RSRC, C_BLACK) ;
  105. X--- 102,112 ----
  106. X        xoff = (maxw - val) / 2 ;
  107. X        draw_text(items[(int) item].wtype,
  108. X                  x + (i * maxw) + xoff,
  109. X!                 y + nfont_height + (nfont_height / 2), NFONT, tcol, str) ;
  110. X      }
  111. X  
  112. X    val = items[(int) item].value ;
  113. X+   if (val < 0 || val >= items[(int) item].nopts) return ;
  114. X    draw_rect(wtype,
  115. X              x + (val * maxw) + 1, y + 1,
  116. X              x + ((val + 1) * maxw) - 1, y + height - 1, RSRC, C_BLACK) ;
  117. X***************
  118. X*** 140,152 ****
  119. X  enum image_type image ;
  120. X  {
  121. X    char val[4] ;
  122. X  
  123. X    if (strlen(items[(int) item].label))
  124. X      draw_text(items[(int) item].wtype,
  125. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  126. X!               BFONT, C_BLACK, items[(int) item].label) ;
  127. X  
  128. X!   SPRINTF(val, "%d", items[(int) item].value) ;
  129. X    set_cycle(wtype, item, val) ;
  130. X    draw_cycle(wtype, item, color, image) ;
  131. X  }
  132. X--- 143,158 ----
  133. X  enum image_type image ;
  134. X  {
  135. X    char val[4] ;
  136. X+   int tcol ;
  137. X  
  138. X+   tcol = B_COLOR(C_TEXT) ;
  139. X    if (strlen(items[(int) item].label))
  140. X      draw_text(items[(int) item].wtype,
  141. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  142. X!               BFONT, tcol, items[(int) item].label) ;
  143. X  
  144. X!   if (item == MAX_DEPTH && !items[(int) item].value) STRCPY(val, "off") ;
  145. X!   else SPRINTF(val, "%d", items[(int) item].value) ;
  146. X    set_cycle(wtype, item, val) ;
  147. X    draw_cycle(wtype, item, color, image) ;
  148. X  }
  149. X***************
  150. X*** 158,166 ****
  151. X  {
  152. X    int y ;
  153. X  
  154. X!   color_area(W_MAIN, tx + 1, ty + 1, tw - 2, th - 2, C_WHITE) ;
  155. X    y = ty + (nfont_height + (th - nfont_height) / 2) - 5 ;
  156. X!   draw_text(W_MAIN, tx + 5, y, NFONT, C_BLACK, str) ;
  157. X    draw_line(W_MAIN, tx + 5 + get_strwidth(NFONT, str), y + 5,
  158. X                      tx + 5 + get_strwidth(NFONT, str), y + 5 - nfont_height,
  159. X                      RSRC, C_BLACK) ;
  160. X--- 164,172 ----
  161. X  {
  162. X    int y ;
  163. X  
  164. X!   color_area(W_MAIN, tx + 1, ty + 1, tw - 2, th - 2, W_COLOR(C_PANEL)) ;
  165. X    y = ty + (nfont_height + (th - nfont_height) / 2) - 5 ;
  166. X!   draw_text(W_MAIN, tx + 5, y, NFONT, B_COLOR(C_TEXT), str) ;
  167. X    draw_line(W_MAIN, tx + 5 + get_strwidth(NFONT, str), y + 5,
  168. X                      tx + 5 + get_strwidth(NFONT, str), y + 5 - nfont_height,
  169. X                      RSRC, C_BLACK) ;
  170. X***************
  171. X*** 174,185 ****
  172. X  int color ;
  173. X  {
  174. X    enum image_type image ;
  175. X!   int x, y ;
  176. X  
  177. X    if (strlen(items[(int) item].label))
  178. X      draw_text(items[(int) item].wtype,
  179. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  180. X!               BFONT, C_BLACK, items[(int) item].label) ;
  181. X  
  182. X    if (items[(int) item].value) image = TOGGLE_ON ;
  183. X    else                         image = TOGGLE_OFF ;
  184. X--- 180,192 ----
  185. X  int color ;
  186. X  {
  187. X    enum image_type image ;
  188. X!   int tcol, x, y ;
  189. X  
  190. X+   tcol = B_COLOR(C_TEXT) ;
  191. X    if (strlen(items[(int) item].label))
  192. X      draw_text(items[(int) item].wtype,
  193. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  194. X!               BFONT, tcol, items[(int) item].label) ;
  195. X  
  196. X    if (items[(int) item].value) image = TOGGLE_ON ;
  197. X    else                         image = TOGGLE_OFF ;
  198. X***************
  199. X*** 199,205 ****
  200. X      draw_text(items[(int) item].wtype,
  201. X                items[(int) item].x + TICKWIDTH + 10,
  202. X                items[(int) item].y + nfont_height,
  203. X!               NFONT, C_BLACK, items[(int) item].text) ;
  204. X  }
  205. X  
  206. X  
  207. X--- 206,212 ----
  208. X      draw_text(items[(int) item].wtype,
  209. X                items[(int) item].x + TICKWIDTH + 10,
  210. X                items[(int) item].y + nfont_height,
  211. X!               NFONT, tcol, items[(int) item].text) ;
  212. X  }
  213. X  
  214. X  
  215. X***************
  216. X*** 211,222 ****
  217. X    lsval = (curx < (BBORDER + (2*(BWIDTH+BGAP)))) ? 'l' : 's' ;
  218. X    x1 = BBORDER + BWIDTH + (BGAP / 2) ;
  219. X    y1 = BBORDER + BHEIGHT + (BGAP / 2) ;
  220. X!   color_area(W_MAIN, x1, y1, 4 * (BWIDTH + BGAP), BHEIGHT + BGAP, C_WHITE) ;
  221. X    draw_rect(W_MAIN, x1, y1, x1 + (4 * (BWIDTH + BGAP)) - 1,
  222. X                      y1 + BHEIGHT + BGAP - 1, RSRC, C_BLACK) ;
  223. X    draw_text(W_MAIN, BBORDER + BWIDTH + BGAP, BBORDER + BHEIGHT + BGAP +
  224. X              (nfont_height + (BHEIGHT - nfont_height) / 2) - 5,
  225. X!             BFONT, C_BLACK, "File:") ;
  226. X    tx = BBORDER + BWIDTH + BGAP + (BWIDTH / 2) + 10 ;
  227. X    ty = BBORDER + BHEIGHT + BGAP ;
  228. X    tw = (BWIDTH / 2) - 10 + (2 * (BWIDTH + BGAP)) ;
  229. X--- 218,230 ----
  230. X    lsval = (curx < (BBORDER + (2*(BWIDTH+BGAP)))) ? 'l' : 's' ;
  231. X    x1 = BBORDER + BWIDTH + (BGAP / 2) ;
  232. X    y1 = BBORDER + BHEIGHT + (BGAP / 2) ;
  233. X!   color_area(W_MAIN, x1, y1,
  234. X!              4 * (BWIDTH + BGAP), BHEIGHT + BGAP, W_COLOR(C_PANEL)) ;
  235. X    draw_rect(W_MAIN, x1, y1, x1 + (4 * (BWIDTH + BGAP)) - 1,
  236. X                      y1 + BHEIGHT + BGAP - 1, RSRC, C_BLACK) ;
  237. X    draw_text(W_MAIN, BBORDER + BWIDTH + BGAP, BBORDER + BHEIGHT + BGAP +
  238. X              (nfont_height + (BHEIGHT - nfont_height) / 2) - 5,
  239. X!             BFONT, B_COLOR(C_TEXT), "File:") ;
  240. X    tx = BBORDER + BWIDTH + BGAP + (BWIDTH / 2) + 10 ;
  241. X    ty = BBORDER + BHEIGHT + BGAP ;
  242. X    tw = (BWIDTH / 2) - 10 + (2 * (BWIDTH + BGAP)) ;
  243. X***************
  244. X*** 227,233 ****
  245. X    tinput = 1 ;
  246. X    items[(int) CANCEL_BUT].x = BBORDER + (4*(BWIDTH+BGAP)) ;
  247. X    items[(int) CANCEL_BUT].y = BBORDER + (1*(BHEIGHT+BGAP)) ;
  248. X!   draw_button(W_MAIN, CANCEL_BUT, C_LGREY, BUT_NORMAL) ;
  249. X  }
  250. X  
  251. X  
  252. X--- 235,241 ----
  253. X    tinput = 1 ;
  254. X    items[(int) CANCEL_BUT].x = BBORDER + (4*(BWIDTH+BGAP)) ;
  255. X    items[(int) CANCEL_BUT].y = BBORDER + (1*(BHEIGHT+BGAP)) ;
  256. X!   draw_button(W_MAIN, CANCEL_BUT, C_ITEMS, BUT_NORMAL) ;
  257. X  }
  258. X  
  259. X  
  260. X***************
  261. X*** 273,286 ****
  262. X    if (strlen(items[(int) item].label))
  263. X      draw_text(items[(int) item].wtype,
  264. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  265. X!               BFONT, C_BLACK, items[(int) item].label) ;
  266. X  
  267. X    message = items[(int) item].text ;
  268. X    x = items[(int) item].x ;
  269. X    y = items[(int) item].y ;
  270. X!   color = (iscolor[(int) cur_dpyno]) ? C_BEIGE : C_WHITE ;
  271. X!   color_area(wtype, x, y, TOTAL_WIDTH, 15, color) ;
  272. X!   draw_text(wtype, x, y + nfont_height, NFONT, C_BLACK, message) ;
  273. X  }
  274. X  
  275. X  
  276. X--- 281,293 ----
  277. X    if (strlen(items[(int) item].label))
  278. X      draw_text(items[(int) item].wtype,
  279. X                items[(int) item].lx, items[(int) item].ly + bfont_height,
  280. X!               BFONT, B_COLOR(C_TEXT), items[(int) item].label) ;
  281. X  
  282. X    message = items[(int) item].text ;
  283. X    x = items[(int) item].x ;
  284. X    y = items[(int) item].y ;
  285. X!   color_area(wtype, x, y, TOTAL_WIDTH, 15, W_COLOR(C_PANEL)) ;
  286. X!   draw_text(wtype, x, y + nfont_height, NFONT, B_COLOR(C_TEXT), message) ;
  287. X  }
  288. X  
  289. X  
  290. X***************
  291. X*** 287,301 ****
  292. X  void
  293. X  make_panel()
  294. X  {
  295. X!   draw_button(W_MAIN, LOAD_BUT,     C_LGREY, BUT_NORMAL) ;
  296. X!   draw_button(W_MAIN, MOVES_BUT,    C_LGREY, BUT_NORMAL) ;
  297. X!   draw_button(W_MAIN, NEW_GAME_BUT, C_LGREY, BUT_NORMAL) ;
  298. X!   draw_button(W_MAIN, SAVE_BUT,     C_LGREY, BUT_NORMAL) ;
  299. X!   draw_button(W_MAIN, SUGGEST_BUT,  C_LGREY, BUT_NORMAL) ;
  300. X!   draw_button(W_MAIN, UNDO_BUT,     C_LGREY, BUT_NORMAL) ;
  301. X  
  302. X!   draw_button(W_MAIN, PROPS_BUT,    C_LGREY, BUT_NORMAL) ;
  303. X!   draw_button(W_MAIN, QUIT_BUT,     C_LGREY, BUT_NORMAL) ;
  304. X  
  305. X    make_message(W_MAIN, BLACK_PLAYS) ;
  306. X    make_message(W_MAIN, WHITE_PLAYS) ;
  307. X--- 294,312 ----
  308. X  void
  309. X  make_panel()
  310. X  {
  311. X!   draw_button(W_MAIN, LOAD_BUT,     C_ITEMS, BUT_NORMAL) ;
  312. X!   draw_button(W_MAIN, MOVES_BUT,    C_ITEMS, BUT_NORMAL) ;
  313. X!   draw_button(W_MAIN, NEW_GAME_BUT, C_ITEMS, BUT_NORMAL) ;
  314. X!   draw_button(W_MAIN, HELP_BUT,     C_ITEMS, BUT_NORMAL) ;
  315. X!   draw_button(W_MAIN, REDO_BUT,     C_ITEMS, BUT_NORMAL) ;
  316. X!   draw_button(W_MAIN, PROPS_BUT,    C_ITEMS, BUT_NORMAL) ;
  317. X  
  318. X!   draw_button(W_MAIN, SAVE_BUT,     C_ITEMS, BUT_NORMAL) ;
  319. X!   draw_button(W_MAIN, SUGGEST_BUT,  C_ITEMS, BUT_NORMAL) ;
  320. X!   draw_button(W_MAIN, EDIT_BUT,     C_ITEMS, BUT_NORMAL) ;
  321. X!   draw_button(W_MAIN, STOP_BUT,     C_ITEMS, BUT_NORMAL) ;
  322. X!   draw_button(W_MAIN, UNDO_BUT,     C_ITEMS, BUT_NORMAL) ;
  323. X!   draw_button(W_MAIN, QUIT_BUT,     C_ITEMS, BUT_NORMAL) ;
  324. X  
  325. X    make_message(W_MAIN, BLACK_PLAYS) ;
  326. X    make_message(W_MAIN, WHITE_PLAYS) ;
  327. X***************
  328. X*** 314,342 ****
  329. X    int n ;
  330. X  
  331. X    n = (int) mtype ;
  332. X-   color = (iscolor[(int) cur_dpyno]) ? C_BEIGE : C_WHITE ;
  333. X    color_area(W_MAIN, items[n].x, items[n].y,
  334. X!              get_strwidth(NFONT, items[n].text), nfont_height + 5, color) ;
  335. X    draw_text(W_MAIN, items[n].x, items[n].y + nfont_height,
  336. X!             NFONT, C_BLACK, str) ;
  337. X    STRCPY(items[n].text, str) ;
  338. X  }
  339. X  
  340. X  
  341. X  void
  342. X  paint_prop_sheet()
  343. X  {
  344. X!   int color, d ;
  345. X  
  346. X!   d = (int) cur_dpyno ;
  347. X!   color = (iscolor[d]) ? C_BEIGE : C_WHITE ;
  348. X    color_area(W_PROPS, 0, 0, PROPS_WIDTH, PROPS_HEIGHT, color) ;
  349. X  
  350. X-   color = (iscolor[d]) ? C_BEIGE : C_WHITE ;
  351. X    draw_choice(W_PROPS, COMP_CHOICE, color) ;
  352. X    draw_choice(W_PROPS, DIFF_CHOICE, color) ;
  353. X  
  354. X!   draw_cycle_item(W_PROPS, MAX_DEPTH, C_LGREY, CY_NORMAL) ;
  355. X  
  356. X    draw_toggle(W_PROPS, OPT_ANIM, color) ;
  357. X    draw_toggle(W_PROPS, OPT_BEST, color) ;
  358. X--- 325,383 ----
  359. X    int n ;
  360. X  
  361. X    n = (int) mtype ;
  362. X    color_area(W_MAIN, items[n].x, items[n].y,
  363. X!              get_strwidth(NFONT, items[n].text),
  364. X!              nfont_height + 5, W_COLOR(C_PANEL)) ;
  365. X    draw_text(W_MAIN, items[n].x, items[n].y + nfont_height,
  366. X!             NFONT, B_COLOR(C_TEXT), str) ;
  367. X    STRCPY(items[n].text, str) ;
  368. X  }
  369. X  
  370. X  
  371. X  void
  372. X+ paint_help()
  373. X+ {
  374. X+   if (hfp == NULL) return ;
  375. X+   color_area(W_HELP, 0, 0,
  376. X+              help_width, (2 * CGAP) + CHEIGHT, W_COLOR(C_PANEL)) ;
  377. X+   draw_cycle_item(W_HELP, HELP_PAGE, C_ITEMS, CY_NORMAL) ;
  378. X+   draw_line(W_HELP, 0,          (2 * CGAP) + CHEIGHT,
  379. X+                     help_width, (2 * CGAP) + CHEIGHT, RSRC, C_BLACK) ;
  380. X+   paint_help_text() ;
  381. X+ }
  382. X+ 
  383. X+ 
  384. X+ void
  385. X+ paint_help_text()
  386. X+ {
  387. X+   char buf[MAXLINE] ;
  388. X+   int i, y ;
  389. X+ 
  390. X+   color_area(W_HELP, 0, (2 * CGAP) + CHEIGHT + 1,
  391. X+              help_width, ((hfont_height + 1) * HELP_ROWS) + (2 * CGAP) - 1,
  392. X+              W_COLOR(C_PANEL)) ;
  393. X+   FSEEK(hfp, help_offsets[items[(int) HELP_PAGE].value], 0) ;
  394. X+   for (i = 0; i < HELP_ROWS; i++)
  395. X+     {
  396. X+       if (fgets(buf, MAXLINE, hfp) == NULL) return ;
  397. X+       y = (3 * CGAP) + CHEIGHT + ((i + 1) * (hfont_height + 1)) ;
  398. X+       draw_text(W_HELP, CGAP, y, NFONT, B_COLOR(C_TEXT), buf) ;
  399. X+     }
  400. X+ }
  401. X+ 
  402. X+ 
  403. X+ void
  404. X  paint_prop_sheet()
  405. X  {
  406. X!   int color ;
  407. X  
  408. X!   color = W_COLOR(C_PANEL) ;
  409. X    color_area(W_PROPS, 0, 0, PROPS_WIDTH, PROPS_HEIGHT, color) ;
  410. X  
  411. X    draw_choice(W_PROPS, COMP_CHOICE, color) ;
  412. X    draw_choice(W_PROPS, DIFF_CHOICE, color) ;
  413. X  
  414. X!   draw_cycle_item(W_PROPS, MAX_DEPTH, C_ITEMS, CY_NORMAL) ;
  415. X  
  416. X    draw_toggle(W_PROPS, OPT_ANIM, color) ;
  417. X    draw_toggle(W_PROPS, OPT_BEST, color) ;
  418. X***************
  419. X*** 355,364 ****
  420. X    x1 = BBORDER + BWIDTH + (BGAP / 2) ;
  421. X    y1 = BBORDER + BHEIGHT + (BGAP / 2) ;
  422. X    color_area(W_MAIN, x1, y1, 4 * (BWIDTH + BGAP), BHEIGHT + BGAP,
  423. X!              (iscolor[(int) cur_dpyno]) ? C_BEIGE : C_WHITE) ;
  424. X    tinput = 0 ;
  425. X    items[(int) CANCEL_BUT].x = -1 ;
  426. X    items[(int) CANCEL_BUT].y = -1 ;
  427. X  }
  428. X  
  429. X  
  430. X--- 396,410 ----
  431. X    x1 = BBORDER + BWIDTH + (BGAP / 2) ;
  432. X    y1 = BBORDER + BHEIGHT + (BGAP / 2) ;
  433. X    color_area(W_MAIN, x1, y1, 4 * (BWIDTH + BGAP), BHEIGHT + BGAP,
  434. X!              W_COLOR(C_PANEL)) ;
  435. X    tinput = 0 ;
  436. X    items[(int) CANCEL_BUT].x = -1 ;
  437. X    items[(int) CANCEL_BUT].y = -1 ;
  438. X+ 
  439. X+   draw_button(W_MAIN, SUGGEST_BUT,  C_ITEMS, BUT_NORMAL) ;
  440. X+   draw_button(W_MAIN, EDIT_BUT,     C_ITEMS, BUT_NORMAL) ;
  441. X+   draw_button(W_MAIN, STOP_BUT,     C_ITEMS, BUT_NORMAL) ;
  442. X+   draw_button(W_MAIN, UNDO_BUT,     C_ITEMS, BUT_NORMAL) ;
  443. X  }
  444. X  
  445. X  
  446. X***************
  447. X*** 368,379 ****
  448. X  enum panel_type item ;
  449. X  char *str ;
  450. X  {
  451. X-   color = (iscolor[(int) cur_dpyno]) ? C_BEIGE : C_WHITE ;
  452. X- 
  453. X    color_area(wtype, items[(int) item].x, items[(int) item].y,
  454. X!              items[(int) item].width, CHEIGHT, color) ;
  455. X    draw_text(wtype, items[(int) item].x, items[(int) item].y + nfont_height,
  456. X!             NFONT, C_BLACK, str) ;
  457. X    STRCPY(items[(int) item].text, str) ;
  458. X    items[(int) item].width = get_strwidth(NFONT, str) ;
  459. X  }
  460. X--- 414,423 ----
  461. X  enum panel_type item ;
  462. X  char *str ;
  463. X  {
  464. X    color_area(wtype, items[(int) item].x, items[(int) item].y,
  465. X!              items[(int) item].width, CHEIGHT, W_COLOR(C_PANEL)) ;
  466. X    draw_text(wtype, items[(int) item].x, items[(int) item].y + nfont_height,
  467. X!             NFONT, B_COLOR(C_TEXT), str) ;
  468. X    STRCPY(items[(int) item].text, str) ;
  469. X    items[(int) item].width = get_strwidth(NFONT, str) ;
  470. X  }
  471. X
  472. X------- main.c -------
  473. X*** /tmp/da06885    Tue Dec 18 10:10:24 1990
  474. X--- main.c    Sun Dec 16 02:44:07 1990
  475. X***************
  476. X*** 38,46 ****
  477. X  } ;
  478. X  #endif /*NO_TIMEVAL*/
  479. X  
  480. X! /* Text values for the cyclic buttons. */
  481. X  char *comp_plays[]    = { "white", "black", "neither", "both" } ;
  482. X- char *diff_values[]   = { "1", "2", "3", "4", "5", "6", "7", "8", "9", NULL } ;
  483. X  char *notes_values[]  = { "off", "on", NULL } ;
  484. X  char *player_values[] = { "human", "computer", NULL } ;
  485. X  
  486. X--- 38,48 ----
  487. X  } ;
  488. X  #endif /*NO_TIMEVAL*/
  489. X  
  490. X! char *diff_values[]   = {
  491. X!   " 1 ", " 2 ", " 3 ", " 4 ", " 5 ", " 6 ", " 7 ", " 8 ", " 9 ", NULL
  492. X! } ;
  493. X! 
  494. X  char *comp_plays[]    = { "white", "black", "neither", "both" } ;
  495. X  char *notes_values[]  = { "off", "on", NULL } ;
  496. X  char *player_values[] = { "human", "computer", NULL } ;
  497. X  
  498. X***************
  499. X*** 52,58 ****
  500. X    "log",                   /* Boolean: write computer info to log file. */
  501. X    "notes",                 /* Boolean: show computer notes. */
  502. X    "number",                /* Boolean: show last move (number on stone). */
  503. X!   "quick"                  /* Boolean: play quick game (don't flip stones). */
  504. X  } ;
  505. X  
  506. X  enum cantype cmode, last_cmode ;
  507. X--- 54,68 ----
  508. X    "log",                   /* Boolean: write computer info to log file. */
  509. X    "notes",                 /* Boolean: show computer notes. */
  510. X    "number",                /* Boolean: show last move (number on stone). */
  511. X!   "quick",                 /* Boolean: play quick game (don't flip stones). */
  512. X!   "panelColor",            /* String:  main and property panels color. */
  513. X!   "boardColor",            /* String:  playing board color. */
  514. X!   "boardBorderColor",      /* String:  playing board border color. */
  515. X!   "gridColor",             /* String:  grid lines color. */
  516. X!   "textColor",             /* String:  text color. */
  517. X!   "itemColor",             /* String:  color of the panel items. */
  518. X!   "properties",            /* Boolean: initially show property window? */
  519. X!   "showHelp"               /* Boolean: initially show help window? */
  520. X  } ;
  521. X  
  522. X  enum cantype cmode, last_cmode ;
  523. X***************
  524. X*** 61,66 ****
  525. X--- 71,86 ----
  526. X  enum set_type direction ;   /* Incremental direction for cycle item. */
  527. X  enum win_type curwin ;      /* Window the current event for in. */
  528. X  
  529. X+ FILE *hfp ;                 /* File descriptor for online help file. */
  530. X+ 
  531. X+ char *colstr[REVE_COLORSIZE] = {
  532. X+   NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL
  533. X+ } ;
  534. X+ 
  535. X+ int rcols[REVE_COLORSIZE] ;   /* Red colormap values. */
  536. X+ int gcols[REVE_COLORSIZE] ;   /* Green colormap values. */
  537. X+ int bcols[REVE_COLORSIZE] ;   /* Blue colormap values. */
  538. X+ 
  539. X  int tx, ty, tw, th ;    /* Position and size of text field. */
  540. X  
  541. X  int piece_x ;           /* Current X position of moving piece. */
  542. X***************
  543. X*** 77,82 ****
  544. X--- 97,106 ----
  545. X  int down ;              /* Indicates is a mouse button is down. */
  546. X  int first_move = 0 ;    /* Set if computer plays first move. */
  547. X  int iconic ;            /* Set if window is currently iconic. */
  548. X+ int help_height ;       /* Height of the help window. */
  549. X+ int help_showing ;      /* If set, the help window is visible. */
  550. X+ int help_width ;        /* Width of the help window. */
  551. X+ int hfont_height ;      /* Height in pixels for help font. */
  552. X  int inv_video = 0 ;     /* Set if displaying in inverse video. */
  553. X  int isblack ;           /* Set if human to play the black pieces. */
  554. X  int iscolor[MAXDPY] ;   /* Set if this is a color screen. */
  555. X***************
  556. X*** 96,101 ****
  557. X--- 120,126 ----
  558. X  int nextc ;             /* Current event identifier. */
  559. X  int next_player ;       /* Next player (BLACK or WHITE) to move. */
  560. X  int nfont_height ;      /* Height in pixels for normal font. */
  561. X+ int old_diffval ;       /* Old difficulty value (possibly restored). */
  562. X  int play_computer ;     /* Set if playing against the computer. */
  563. X  int posspec ;           /* Set if -Wp or -g option is present (for X11) */
  564. X  int processing ;        /* If set, computer is procesing a move. */
  565. X***************
  566. X*** 110,115 ****
  567. X--- 135,142 ----
  568. X  int wx ;                /* Initial X position of the window. */
  569. X  int wy ;                /* Initial Y position of the window. */
  570. X  
  571. X+ long help_offsets[MAXPAGES] ;    /* Offsets into the reve help file. */
  572. X+ 
  573. X  /*  Globals for passing arguments to "sandwich";
  574. X   *  this is to save time putting arguments on and off the
  575. X   *  stack in a very heavily used piece of code
  576. X***************
  577. X*** 168,177 ****
  578. X      new_game
  579. X    },
  580. X  
  581. X!   {                                   /* save button. */
  582. X      W_MAIN, P_BUTTON, 0, 0,
  583. X      "",
  584. X      BBORDER + (3*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  585. X      BWIDTH, BHEIGHT, "save", 0,
  586. X      (char **) NULL, 0,
  587. X      draw_textfield
  588. X--- 195,231 ----
  589. X      new_game
  590. X    },
  591. X  
  592. X!   {                                   /* help button. */
  593. X      W_MAIN, P_BUTTON, 0, 0,
  594. X      "",
  595. X      BBORDER + (3*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  596. X+     BWIDTH, BHEIGHT, "help", 0,
  597. X+     (char **) NULL, 0,
  598. X+     do_help
  599. X+   },
  600. X+ 
  601. X+   {                                   /* redo button. */
  602. X+     W_MAIN, P_BUTTON, 0, 0,
  603. X+     "",
  604. X+     BBORDER + (4*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  605. X+     BWIDTH, BHEIGHT, "redo", 0,
  606. X+     (char **) NULL, 0,
  607. X+     redo
  608. X+   },
  609. X+ 
  610. X+   {                                   /* props button. */
  611. X+     W_MAIN, P_BUTTON, 0, 0,
  612. X+     "",
  613. X+     BBORDER + (5*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  614. X+     BWIDTH, BHEIGHT, "props", 0,
  615. X+     (char **) NULL, 0,
  616. X+     do_props
  617. X+   },
  618. X+ 
  619. X+   {                                   /* save button. */
  620. X+     W_MAIN, P_BUTTON, 0, 0,
  621. X+     "",
  622. X+     BBORDER + (0*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)),
  623. X      BWIDTH, BHEIGHT, "save", 0,
  624. X      (char **) NULL, 0,
  625. X      draw_textfield
  626. X***************
  627. X*** 180,209 ****
  628. X    {                                   /* suggest button. */
  629. X      W_MAIN, P_BUTTON, 0, 0,
  630. X      "",
  631. X!     BBORDER + (4*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  632. X      BWIDTH, BHEIGHT, "suggest", 0,
  633. X      (char **) NULL, 0,
  634. X      suggest
  635. X    },
  636. X    
  637. X    {                                   /* undo button. */
  638. X      W_MAIN, P_BUTTON, 0, 0,
  639. X      "",
  640. X!     BBORDER + (5*(BWIDTH+BGAP)), BBORDER + (0*(BHEIGHT+BGAP)),
  641. X      BWIDTH, BHEIGHT, "undo", 0,
  642. X      (char **) NULL, 0,
  643. X      undo
  644. X    },
  645. X    
  646. X-   {                                   /* props button. */
  647. X-     W_MAIN, P_BUTTON, 0, 0,
  648. X-     "",
  649. X-     BBORDER + (0*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)),
  650. X-     BWIDTH, BHEIGHT, "props", 0,
  651. X-     (char **) NULL, 0,
  652. X-     do_props
  653. X-   },
  654. X- 
  655. X    {                                   /* cancel button. */
  656. X      W_MAIN, P_BUTTON, 0, 0,
  657. X      "",
  658. X--- 234,274 ----
  659. X    {                                   /* suggest button. */
  660. X      W_MAIN, P_BUTTON, 0, 0,
  661. X      "",
  662. X!     BBORDER + (1*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)),
  663. X      BWIDTH, BHEIGHT, "suggest", 0,
  664. X      (char **) NULL, 0,
  665. X      suggest
  666. X    },
  667. X    
  668. X+   {                                   /* edit button. */
  669. X+     W_MAIN, P_BUTTON, 0, 0,
  670. X+     "",    
  671. X+ /*    BBORDER + (2*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)), */
  672. X+     -1, -1,
  673. X+     BWIDTH, BHEIGHT, "edit", 0,
  674. X+     (char **) NULL, 0,
  675. X+     do_edit
  676. X+   },
  677. X+ 
  678. X+   {                                   /* stop button. */
  679. X+     W_MAIN, P_BUTTON, 0, 0,
  680. X+     "",    
  681. X+ /*    BBORDER + (3*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)), */
  682. X+     -1, -1,
  683. X+     BWIDTH, BHEIGHT, "stop", 0,
  684. X+     (char **) NULL, 0,
  685. X+     do_stop
  686. X+   },
  687. X+ 
  688. X    {                                   /* undo button. */
  689. X      W_MAIN, P_BUTTON, 0, 0,
  690. X      "",
  691. X!     BBORDER + (4*(BWIDTH+BGAP)), BBORDER + (1*(BHEIGHT+BGAP)),
  692. X      BWIDTH, BHEIGHT, "undo", 0,
  693. X      (char **) NULL, 0,
  694. X      undo
  695. X    },
  696. X    
  697. X    {                                   /* cancel button. */
  698. X      W_MAIN, P_BUTTON, 0, 0,
  699. X      "",
  700. X***************
  701. X*** 312,318 ****
  702. X      BBORDER + (0*(BWIDTH+BGAP)), BBORDER + (2*(BHEIGHT+BGAP)),
  703. X      "Set search depth:",
  704. X      BBORDER + (2*(BWIDTH+BGAP)), BBORDER + (2*(BHEIGHT+BGAP)),
  705. X!     0, 0, "", INIT_DEPTH,
  706. X      (char **) NULL, 0,
  707. X      set_option
  708. X    },
  709. X--- 377,383 ----
  710. X      BBORDER + (0*(BWIDTH+BGAP)), BBORDER + (2*(BHEIGHT+BGAP)),
  711. X      "Set search depth:",
  712. X      BBORDER + (2*(BWIDTH+BGAP)), BBORDER + (2*(BHEIGHT+BGAP)),
  713. X!     0, 0, "", 0,
  714. X      (char **) NULL, 0,
  715. X      set_option
  716. X    },
  717. X***************
  718. X*** 371,376 ****
  719. X--- 436,451 ----
  720. X      (char **) NULL, 0,
  721. X      set_option
  722. X    },
  723. X+ 
  724. X+   {                                   /* Help window page cycle. */
  725. X+     W_HELP, P_CYCLE,
  726. X+     BBORDER + (0*(BWIDTH+BGAP)), CGAP,
  727. X+     "Page",
  728. X+     BBORDER + (1*(BWIDTH+BGAP)), CGAP,
  729. X+     0, 0, "", 1,
  730. X+     (char **) NULL, 0,
  731. X+     display_help
  732. X+   },
  733. X  } ;
  734. X  
  735. X  char geometry[MAXDPY][MAXLINE] ;       /* X11 geometry information. */
  736. X***************
  737. X*** 378,383 ****
  738. X--- 453,459 ----
  739. X  char *black_dpy ;              /* Black piece display information. */
  740. X  char edgefile[MAXLINE] ;       /* Location of the reve edge table file. */
  741. X  char gamefile[MAXLINE] ;       /* Name of file for load/save. */
  742. X+ char helpfile[MAXLINE] ;       /* Location of the reve online help file. */
  743. X  char line[40] ;
  744. X  char progname[MAXLINE] ;       /* The name of this program. */
  745. X  char *white_dpy ;              /* White piece display information. */
  746. X***************
  747. X*** 405,410 ****
  748. X--- 481,487 ----
  749. X    STRCPY(gamefile, "reve.game") ;
  750. X    SPRINTF(line, " Reve.  V1.1.%1d", PATCHLEVEL) ;
  751. X    init_graphics(&argc, argv) ;
  752. X+   reve_colorsetup(rcols, gcols, bcols) ;  /* Setup default colors. */
  753. X    initialise() ;                /* Initialise variables used by reve. */
  754. X    load_resources() ;            /* Get resources from various places. */
  755. X    read_resources() ;            /* Read resources from merged database. */
  756. X***************
  757. X*** 414,420 ****
  758. X    init_edge_table(edgefile) ;   /* Load reve edge table values. */
  759. X  #endif /*XVIEW*/
  760. X  
  761. X!   set_display_types() ;         /* Work out what displays to initialise. */
  762. X    if (init_ws_type())           /* Determine window system type. */
  763. X      {
  764. X        FPRINTF(stderr,"Error initialising window system.\n") ;
  765. X--- 491,499 ----
  766. X    init_edge_table(edgefile) ;   /* Load reve edge table values. */
  767. X  #endif /*XVIEW*/
  768. X  
  769. X!   init_help_file(helpfile) ;    /* Load reve help file page offsets. */
  770. X! 
  771. X! set_display_types() ;         /* Work out what displays to initialise. */
  772. X    if (init_ws_type())           /* Determine window system type. */
  773. X      {
  774. X        FPRINTF(stderr,"Error initialising window system.\n") ;
  775. X***************
  776. X*** 450,458 ****
  777. X  {
  778. X    cur_dpyno = dpyno ;
  779. X    make_icon() ;
  780. X!   make_frame(argc, argv) ;      /* Create reve window/icon. */
  781. X!   make_canvas() ;               /* Create drawing canvas. */
  782. X!   init_fonts() ;                /* Load normal and bold fonts. */
  783. X    initboard() ;
  784. X    set_cursor(CANVASCUR) ;
  785. X  }
  786. X--- 529,538 ----
  787. X  {
  788. X    cur_dpyno = dpyno ;
  789. X    make_icon() ;
  790. X!   make_frame(argc, argv) ;        /* Create reve window/icon. */
  791. X!   make_canvas() ;                 /* Create drawing canvas. */
  792. X!   init_fonts() ;                  /* Load normal and bold fonts. */
  793. X!   make_help_window(argc, argv) ;  /* Make help window based on normal font. */
  794. X    initboard() ;
  795. X    set_cursor(CANVASCUR) ;
  796. X  }
  797. X***************
  798. X*** 521,527 ****
  799. X                         getparam(next, argv, "-d needs difficulty") ;
  800. X                         level = atoi(next) ;
  801. X                         if (level < 1 || level > MAXDIFF) level = INIT_DEPTH ;
  802. X!                        items[(int) DIFF_CHOICE].value = level - 1 ;
  803. X                         break ;
  804. X              case 'e' : INC ;
  805. X                         getparam(edgefile, argv, "-e needs an edgetable file") ;
  806. X--- 601,607 ----
  807. X                         getparam(next, argv, "-d needs difficulty") ;
  808. X                         level = atoi(next) ;
  809. X                         if (level < 1 || level > MAXDIFF) level = INIT_DEPTH ;
  810. X!                        items[(int) DIFF_CHOICE].value = old_diffval = level-1 ;
  811. X                         break ;
  812. X              case 'e' : INC ;
  813. X                         getparam(edgefile, argv, "-e needs an edgetable file") ;
  814. X***************
  815. X*** 530,535 ****
  816. X--- 610,622 ----
  817. X                         getparam(geometry[0], argv,
  818. X                                  "-g needs geometry information") ;
  819. X                         break ;
  820. X+             case 'h' : if (EQUAL(argv[0], "-help")) help_showing = TRUE ;
  821. X+                        else
  822. X+                          {
  823. X+                            INC ;
  824. X+                            getparam(helpfile, argv, "-h needs a help file") ;
  825. X+                          }
  826. X+                        break ;
  827. X              case 'i' : inv_video = 1 ;       /* Display in inverse video. */
  828. X                         break ;
  829. X              case 'l' :      if (EQUAL(argv[0], "-last")) DO_LAST = TRUE ;
  830. X***************
  831. X*** 547,552 ****
  832. X--- 634,641 ----
  833. X              case 'n' :      if (EQUAL(argv[0], "-notes")) SHOW_NOTES = TRUE ;
  834. X                         else if (EQUAL(argv[0], "-number")) DO_NUMBER = TRUE ;
  835. X                         break ;
  836. X+             case 'p' : if (EQUAL(argv[0], "-props")) props_showing = TRUE ;
  837. X+                        break ;
  838. X              case 'q' : if (EQUAL(argv[0], "-quick")) QUICKGAME = TRUE ;
  839. X                         break ;
  840. X              case '?' :
  841. X***************
  842. X*** 654,663 ****
  843. X    color_area(W_MAIN, 0, 0, TOTAL_WIDTH, TOTAL_HEIGHT, C_WHITE) ;
  844. X    if (iscolor[d])
  845. X      {
  846. X!       color_area(W_MAIN, 0, 0, TOTAL_WIDTH, CY, C_BEIGE) ;
  847. X!       color_area(W_MAIN, 0, CY, TOTAL_WIDTH, TOTAL_WIDTH, C_DBROWN) ;
  848. X        color_area(W_MAIN, 0 + BBORDER, CY + BBORDER, BOARD_SIZE * CELL_SIZE,
  849. X!                  BOARD_SIZE * CELL_SIZE, C_LBROWN) ;
  850. X      }
  851. X    make_panel() ;                /* Create panel and panel items. */
  852. X  
  853. X--- 743,752 ----
  854. X    color_area(W_MAIN, 0, 0, TOTAL_WIDTH, TOTAL_HEIGHT, C_WHITE) ;
  855. X    if (iscolor[d])
  856. X      {
  857. X!       color_area(W_MAIN, 0, 0, TOTAL_WIDTH, CY, C_PANEL) ;
  858. X!       color_area(W_MAIN, 0, CY, TOTAL_WIDTH, TOTAL_WIDTH, C_BORDER) ;
  859. X        color_area(W_MAIN, 0 + BBORDER, CY + BBORDER, BOARD_SIZE * CELL_SIZE,
  860. X!                  BOARD_SIZE * CELL_SIZE, C_SQUARE) ;
  861. X      }
  862. X    make_panel() ;                /* Create panel and panel items. */
  863. X  
  864. X***************
  865. X*** 666,674 ****
  866. X    batch(IS_ON) ;
  867. X    for (n = 0; n <= BOARD_SIZE; n++)
  868. X      {
  869. X!       color = (iscolor[d]) ? C_LGREY : C_BLACK ;
  870. X        if (n == 0 || n == BOARD_SIZE) color = C_BLACK ;
  871. X!       if (color == C_LGREY) adjust = 1 ;
  872. X        else adjust = 0 ;
  873. X        draw_line(W_MAIN, (n*CELL_SIZE)+BBORDER,              /* Vertical. */
  874. X                  CY+BBORDER+adjust, (n*CELL_SIZE)+BBORDER,
  875. X--- 755,763 ----
  876. X    batch(IS_ON) ;
  877. X    for (n = 0; n <= BOARD_SIZE; n++)
  878. X      {
  879. X!       color = B_COLOR(C_GRID) ;
  880. X        if (n == 0 || n == BOARD_SIZE) color = C_BLACK ;
  881. X!       if (color == C_GRID) adjust = 1 ;
  882. X        else adjust = 0 ;
  883. X        draw_line(W_MAIN, (n*CELL_SIZE)+BBORDER,              /* Vertical. */
  884. X                  CY+BBORDER+adjust, (n*CELL_SIZE)+BBORDER,
  885. X***************
  886. X*** 711,716 ****
  887. X--- 800,808 ----
  888. X    message(TURN_MES, "Black to move.") ;
  889. X    batch(IS_OFF) ;
  890. X  
  891. X+   if (help_showing)  set_frame(W_HELP,  help_showing) ;
  892. X+   if (props_showing) set_frame(W_PROPS, props_showing) ;
  893. X+ 
  894. X    if (loadgame)
  895. X      {
  896. X        loadgame = 0 ;
  897. X***************
  898. X*** 741,748 ****
  899. X    DO_BESTMOVE   = FALSE ;
  900. X    DO_LAST       = FALSE ;
  901. X    DO_NUMBER     = FALSE ;
  902. X    processing    = FALSE ;             /* No computer move initially. */
  903. X!   props_showing = FALSE ;
  904. X    QUICKGAME     = FALSE ;
  905. X    validkey      = 0 ;
  906. X    cmode         = BLACK_START ;
  907. X--- 833,841 ----
  908. X    DO_BESTMOVE   = FALSE ;
  909. X    DO_LAST       = FALSE ;
  910. X    DO_NUMBER     = FALSE ;
  911. X+   help_showing  = FALSE ;             /* Help window not visible. */
  912. X    processing    = FALSE ;             /* No computer move initially. */
  913. X!   props_showing = FALSE ;             /* Properties window not visible. */
  914. X    QUICKGAME     = FALSE ;
  915. X    validkey      = 0 ;
  916. X    cmode         = BLACK_START ;
  917. X***************
  918. X*** 751,757 ****
  919. X    isblack       = 0 ;
  920. X    iswhite       = 0 ;
  921. X    level         = INIT_DEPTH ;
  922. X!   items[(int) DIFF_CHOICE].value = level - 1 ;
  923. X  
  924. X    black_dpy = NULL ;              /* X11 black piece display information. */
  925. X    white_dpy = NULL ;              /* X11 white piece display information. */
  926. X--- 844,850 ----
  927. X    isblack       = 0 ;
  928. X    iswhite       = 0 ;
  929. X    level         = INIT_DEPTH ;
  930. X!   items[(int) DIFF_CHOICE].value = old_diffval = level - 1 ;
  931. X  
  932. X    black_dpy = NULL ;              /* X11 black piece display information. */
  933. X    white_dpy = NULL ;              /* X11 white piece display information. */
  934. X***************
  935. X*** 758,763 ****
  936. X--- 851,857 ----
  937. X    STRCPY(geometry[(int) DPY1], "") ;    /* X11 geometry information. */
  938. X    STRCPY(geometry[(int) DPY2], "") ;
  939. X    STRCPY(edgefile, EDGENAME) ;
  940. X+   STRCPY(helpfile, HELPNAME) ;
  941. X  }
  942. X  
  943. X  
  944. X***************
  945. X*** 765,770 ****
  946. X--- 859,865 ----
  947. X  read_resources()            /* Read all possible resources from database. */
  948. X  {
  949. X    int boolval, intval ;
  950. X+   char str[MAXLINE] ;
  951. X  
  952. X    if (get_bool_resource(R_ANIMATE,  &boolval)) ANIMATION   = boolval ;
  953. X    if (get_bool_resource(R_BESTMOVE, &boolval)) DO_BESTMOVE = boolval ;
  954. X***************
  955. X*** 773,779 ****
  956. X      {
  957. X        level = intval ;
  958. X        if (level < 1 || level > MAXDIFF) level = INIT_DEPTH ;
  959. X!       items[(int) DIFF_CHOICE].value = level - 1 ;
  960. X      }
  961. X  
  962. X    if (get_bool_resource(R_LAST,   &boolval)) DO_LAST = boolval ;
  963. X--- 868,874 ----
  964. X      {
  965. X        level = intval ;
  966. X        if (level < 1 || level > MAXDIFF) level = INIT_DEPTH ;
  967. X!       items[(int) DIFF_CHOICE].value = old_diffval = level - 1 ;
  968. X      }
  969. X  
  970. X    if (get_bool_resource(R_LAST,   &boolval)) DO_LAST = boolval ;
  971. X***************
  972. X*** 781,789 ****
  973. X--- 876,907 ----
  974. X    if (get_bool_resource(R_NOTES,  &boolval)) SHOW_NOTES = boolval ;
  975. X    if (get_bool_resource(R_NUMBER, &boolval)) DO_NUMBER = boolval ;
  976. X    if (get_bool_resource(R_QUICK,  &boolval)) QUICKGAME = boolval ;
  977. X+   if (get_bool_resource(R_PROPS,  &boolval)) props_showing = boolval ;
  978. X+   if (get_bool_resource(R_HELP,   &boolval)) help_showing  = boolval ;
  979. X+ 
  980. X+   if (get_str_resource(R_PANELC,  str)) read_str(&colstr[C_PANEL],  str) ;
  981. X+   if (get_str_resource(R_BOARDC,  str)) read_str(&colstr[C_SQUARE], str) ;
  982. X+   if (get_str_resource(R_BOARDBC, str)) read_str(&colstr[C_BORDER], str) ;
  983. X+   if (get_str_resource(R_GRIDC,   str)) read_str(&colstr[C_GRID],   str) ;
  984. X+   if (get_str_resource(R_TEXTC,   str)) read_str(&colstr[C_TEXT],   str) ;
  985. X+   if (get_str_resource(R_ITEMC,   str)) read_str(&colstr[C_ITEMS],  str) ;
  986. X  }
  987. X  
  988. X  
  989. X+ void
  990. X+ read_str(str, value)
  991. X+ char **str, *value ;
  992. X+ {
  993. X+   if (*str != NULL) (void) free(*str) ;
  994. X+   if (value != NULL && strlen(value))
  995. X+     {
  996. X+       *str = (char *) malloc((unsigned) (strlen(value) + 1)) ;
  997. X+       STRCPY(*str, value) ;
  998. X+     }
  999. X+   else *str = NULL ;
  1000. X+ }
  1001. X+ 
  1002. X+ 
  1003. X  /*  Setup the display information for the black and white displays.
  1004. X   *  There are a fair number of combinations allowed. This table hopefully
  1005. X   *  gives the setup information for each combination.
  1006. X***************
  1007. X*** 875,883 ****
  1008. X    FPRINTF(stderr, "%s version 1.1.%1d\n\n", progname, PATCHLEVEL) ;
  1009. X    FPRINTF(stderr, "Usage: %s: [-animate] [-bestmove]\n", progname) ;
  1010. X    FPRINTF(stderr, "\t[-black [display] ] [-c] [-d difficulty]\n") ;
  1011. X!   FPRINTF(stderr, "\t[-e edgefile] [-g geometry] [-last]\n") ;
  1012. X!   FPRINTF(stderr, "\t[-load gamefile] [-number] [-notes] [-v]\n") ;
  1013. X!   FPRINTF(stderr, "\t[-w [display] ] [-?] [-Wi] [-Wp x y] [-WP x y]\n") ;
  1014. X  }
  1015. X  
  1016. X  
  1017. X--- 993,1002 ----
  1018. X    FPRINTF(stderr, "%s version 1.1.%1d\n\n", progname, PATCHLEVEL) ;
  1019. X    FPRINTF(stderr, "Usage: %s: [-animate] [-bestmove]\n", progname) ;
  1020. X    FPRINTF(stderr, "\t[-black [display] ] [-c] [-d difficulty]\n") ;
  1021. X!   FPRINTF(stderr, "\t[-e edgefile] [-g geometry] [-h helpfile] [-help]\n") ;
  1022. X!   FPRINTF(stderr, "\t[-i] [-last] [-load gamefile] [-log] [-m] [-number]\n") ;
  1023. X!   FPRINTF(stderr, "\t[-notes] [-props] [-quick] [-v] [-w [display] ]\n") ;
  1024. X!   FPRINTF(stderr, "\t[-?] [-Wi] [-Wp x y] [-WP x y]\n") ;
  1025. X  }
  1026. X  
  1027. X  
  1028. X
  1029. X------- procs.c -------
  1030. X*** /tmp/da06888    Tue Dec 18 10:10:25 1990
  1031. X--- procs.c    Mon Dec 17 10:32:34 1990
  1032. X***************
  1033. X*** 29,39 ****
  1034. X  
  1035. X  
  1036. X  void
  1037. X  do_props()
  1038. X  {
  1039. X    props_showing = !props_showing ;
  1040. X!   if (props_showing == TRUE) open_frame(W_PROPS) ;
  1041. X!   else                       close_frame(W_PROPS) ;
  1042. X  }
  1043. X  
  1044. X  
  1045. X--- 29,78 ----
  1046. X  
  1047. X  
  1048. X  void
  1049. X+ display_help()
  1050. X+ {
  1051. X+   char str[4] ;
  1052. X+   int val ;
  1053. X+ 
  1054. X+   val = items[itemno].value ;
  1055. X+   if (direction == INCREMENT && help_offsets[++val] != -1)
  1056. X+     items[itemno].value++ ;
  1057. X+   else if (direction == DECREMENT && help_offsets[--val] != -1)
  1058. X+     items[itemno].value-- ;
  1059. X+   else return ;
  1060. X+   SPRINTF(str, "%d", items[itemno].value) ;
  1061. X+   set_cycle(W_HELP, HELP_PAGE, str) ;
  1062. X+   paint_help_text() ;
  1063. X+ }
  1064. X+ 
  1065. X+ 
  1066. X+ void
  1067. X+ do_edit()
  1068. X+ {
  1069. X+   message(PANEL_MES, "Not currently implemented.") ;
  1070. X+ }
  1071. X+ 
  1072. X+ 
  1073. X+ void
  1074. X+ do_help()
  1075. X+ {
  1076. X+   help_showing = !help_showing ;
  1077. X+   set_frame(W_HELP, help_showing) ;
  1078. X+ }
  1079. X+ 
  1080. X+ 
  1081. X+ void
  1082. X+ do_stop()
  1083. X+ {
  1084. X+   message(PANEL_MES, "Not currently implemented.") ;
  1085. X+ }
  1086. X+ 
  1087. X+ 
  1088. X+ void
  1089. X  do_props()
  1090. X  {
  1091. X    props_showing = !props_showing ;
  1092. X!   set_frame(W_PROPS, props_showing) ;
  1093. X  }
  1094. X  
  1095. X  
  1096. X***************
  1097. X*** 81,89 ****
  1098. X  
  1099. X    suggest_x = BBORDER + ((suggestion & 7)  + 1) * CELL_SIZE - CELL_SIZE / 2 ;
  1100. X    suggest_y = BBORDER + ((suggestion >> 3) + 1) * CELL_SIZE - CELL_SIZE / 2 ;
  1101. X!   if (state == IS_OFF)
  1102. X!     color = (iscolor[(int) cur_dpyno]) ? C_LBROWN : C_WHITE ;
  1103. X!   else color = C_BLACK ;
  1104. X  
  1105. X    draw_line(W_MAIN, suggest_x-5, CY+suggest_y-5,
  1106. X                      suggest_x+5, CY+suggest_y+5, RSRC, color) ;
  1107. X--- 120,127 ----
  1108. X  
  1109. X    suggest_x = BBORDER + ((suggestion & 7)  + 1) * CELL_SIZE - CELL_SIZE / 2 ;
  1110. X    suggest_y = BBORDER + ((suggestion >> 3) + 1) * CELL_SIZE - CELL_SIZE / 2 ;
  1111. X!   if (state == IS_OFF) color = W_COLOR(C_SQUARE) ;
  1112. X!   else                 color = C_BLACK ;
  1113. X  
  1114. X    draw_line(W_MAIN, suggest_x-5, CY+suggest_y-5,
  1115. X                      suggest_x+5, CY+suggest_y+5, RSRC, color) ;
  1116. X***************
  1117. X*** 94,99 ****
  1118. X--- 132,161 ----
  1119. X  
  1120. X  
  1121. X  void
  1122. X+ init_help_file(helpfile)     /* Load reve help page offsets. */
  1123. X+ char *helpfile ;
  1124. X+ {
  1125. X+   char buf[MAXLINE] ;
  1126. X+   int i, page ;
  1127. X+   long offset ;
  1128. X+ 
  1129. X+   for (i = 0; i < MAXPAGES; i++) help_offsets[i] = -1 ;
  1130. X+   if ((hfp = find_file(helpfile)) == NULL)
  1131. X+     {
  1132. X+       FPRINTF(stderr, "Cannot open online help file\n") ;
  1133. X+       return ;
  1134. X+     }
  1135. X+   page = 1 ;
  1136. X+   for (;;)
  1137. X+     {
  1138. X+       offset = ftell(hfp) ;
  1139. X+       if (fgets(buf, MAXLINE, hfp) == NULL) return ;
  1140. X+       if (EQUAL(buf, "REVE(6)")) help_offsets[page++] = offset ;
  1141. X+     }
  1142. X+ }
  1143. X+ 
  1144. X+ 
  1145. X+ void
  1146. X  make_move()
  1147. X  {
  1148. X    if (legal(move, next_player, &board) == FALSE)
  1149. X***************
  1150. X*** 129,135 ****
  1151. X    init_canvas() ;
  1152. X    message(EVAL_MES, "") ;
  1153. X    message(PANEL_MES, "Use left mouse button to move") ;
  1154. X!   draw_button(W_MAIN, NEW_GAME_BUT, C_LGREY, BUT_NORMAL) ;
  1155. X  }
  1156. X  
  1157. X  
  1158. X--- 191,197 ----
  1159. X    init_canvas() ;
  1160. X    message(EVAL_MES, "") ;
  1161. X    message(PANEL_MES, "Use left mouse button to move") ;
  1162. X!   draw_button(W_MAIN, NEW_GAME_BUT, C_ITEMS, BUT_NORMAL) ;
  1163. X  }
  1164. X  
  1165. X  
  1166. X***************
  1167. X*** 142,151 ****
  1168. X  
  1169. X  
  1170. X  void
  1171. X  set_computer(val)
  1172. X  int val ;
  1173. X  {
  1174. X!   int color, curi ;
  1175. X  
  1176. X    if (val == CP_WHITE)
  1177. X      {
  1178. X--- 204,294 ----
  1179. X  
  1180. X  
  1181. X  void
  1182. X+ redo()
  1183. X+ {
  1184. X+   enum panel_type p ;
  1185. X+ 
  1186. X+  /*  The amount we redo is dependant upon two things:
  1187. X+   *
  1188. X+   *  1/ Whether the opponent is the computer, in which case we redo
  1189. X+   *     two "moves". Otherwise we just redo one "move".
  1190. X+   *
  1191. X+   *  2/ A "move" is considered to be all consecutive moves by the opponent.
  1192. X+   */
  1193. X+ 
  1194. X+   redo_move(next_player) ;
  1195. X+   p = (next_player == BLACK) ? BLACK_PLAYS : WHITE_PLAYS ;
  1196. X+   if (items[(int) p].value == COMPUTER) redo_move(next_player) ;
  1197. X+ 
  1198. X+   set_score() ;
  1199. X+   set_turn(next_player) ;
  1200. X+ }
  1201. X+ 
  1202. X+ 
  1203. X+ void
  1204. X+ redo_move(player)
  1205. X+ int player ;
  1206. X+ {
  1207. X+   int i, limit, n, x, y ;
  1208. X+  
  1209. X+   n = 63 - board.moves_left ;
  1210. X+   while (moves[n].move != -1 && moves[n].player != player) n++ ;
  1211. X+  
  1212. X+   if (moves[n].move == -1 || n > 63) message(PANEL_MES, "No moves to redo.") ;
  1213. X+   else
  1214. X+     {
  1215. X+       if (DO_LAST) show_last(last_move, IS_OFF) ;
  1216. X+       if (DO_NUMBER) show_number(last_move, 60 - board.moves_left, IS_OFF) ;
  1217. X+       do_suggest(player, suggestion, note, IS_OFF) ;
  1218. X+       FOR_BOARD(i)
  1219. X+         {
  1220. X+           if (moves[n].square[i] != board.square[i])
  1221. X+             {
  1222. X+               get_xy(i, &x, &y) ;
  1223. X+               if (moves[n].square[i] == FREE)
  1224. X+                 color_area(W_MAIN, x, CY+y, PSIZE, PSIZE, W_COLOR(C_SQUARE)) ;
  1225. X+               else draw_piece(moves[n].square[i], x, CY+y, RSRC) ;
  1226. X+             }
  1227. X+           board.square[i] = moves[n].square[i] ;
  1228. X+         }
  1229. X+       board.moves_left = moves[n].moves_left ;
  1230. X+       board.player     = moves[n].player ;
  1231. X+       board.move       = moves[n].move ;
  1232. X+       board.note       = moves[n].note ;
  1233. X+       board.timeleft   = moves[n].timeleft ;
  1234. X+       last_move        = board.move ;
  1235. X+ 
  1236. X+       FOR_BOARD(i) old_board.square[i] = moves[n-1].square[i] ;
  1237. X+       old_board.moves_left = moves[n-1].moves_left ;
  1238. X+       old_board.player     = moves[n-1].player ;
  1239. X+       old_board.move       = moves[n-1].move ;
  1240. X+       old_board.note       = moves[n-1].note ;
  1241. X+       old_board.timeleft   = moves[n-1].timeleft ;
  1242. X+ 
  1243. X+       timeleft = board.timeleft ;
  1244. X+ 
  1245. X+ #ifdef XVIEW
  1246. X+       reset_time(timeleft) ;
  1247. X+ #endif /*XVIEW*/
  1248. X+ 
  1249. X+       if (OPPONENT(player) == BLACK) cmode = BLACK_START ;
  1250. X+       else                           cmode = WHITE_START ;
  1251. X+       message(PANEL_MES, "") ;
  1252. X+ 
  1253. X+       if (DO_LAST) show_last(last_move, IS_ON) ;
  1254. X+       if (DO_NUMBER) show_number(last_move, 60 - board.moves_left, IS_ON) ;
  1255. X+       if (SHOW_NOTES) set_eval(board.player, board.move, board.note) ;
  1256. X+       else message(EVAL_MES, "") ;
  1257. X+       next_player = OPPONENT(board.player) ;
  1258. X+     }
  1259. X+ }
  1260. X+ 
  1261. X+ 
  1262. X+ void
  1263. X  set_computer(val)
  1264. X  int val ;
  1265. X  {
  1266. X!   int curi ;
  1267. X  
  1268. X    if (val == CP_WHITE)
  1269. X      {
  1270. X***************
  1271. X*** 175,182 ****
  1272. X        STRCPY(items[(int) WHITE_PLAYS].text, player_values[HUMAN]) ; 
  1273. X      }
  1274. X  
  1275. X!   color = (iscolor[(int) cur_dpyno]) ? C_BEIGE : C_WHITE ;
  1276. X!   draw_choice(W_PROPS, COMP_CHOICE, color) ;
  1277. X  
  1278. X    val = items[(int) BLACK_PLAYS].value ;
  1279. X    val = items[(int) WHITE_PLAYS].value ;
  1280. X--- 318,326 ----
  1281. X        STRCPY(items[(int) WHITE_PLAYS].text, player_values[HUMAN]) ; 
  1282. X      }
  1283. X  
  1284. X!   draw_choice(W_PROPS, COMP_CHOICE, W_COLOR(C_PANEL)) ;
  1285. X!   make_message(W_MAIN, BLACK_PLAYS) ;
  1286. X!   make_message(W_MAIN, WHITE_PLAYS) ;
  1287. X  
  1288. X    val = items[(int) BLACK_PLAYS].value ;
  1289. X    val = items[(int) WHITE_PLAYS].value ;
  1290. X***************
  1291. X*** 194,202 ****
  1292. X  set_option()
  1293. X  {
  1294. X    char str[4] ;
  1295. X!   int color, d, maxw, n, val ;
  1296. X  
  1297. X-   d = (int) cur_dpyno ;
  1298. X    switch (itemno)
  1299. X      {
  1300. X        case COMP_CHOICE : maxw = items[itemno].width / items[itemno].nopts ;
  1301. X--- 338,345 ----
  1302. X  set_option()
  1303. X  {
  1304. X    char str[4] ;
  1305. X!   int maxw, n, val ;
  1306. X  
  1307. X    switch (itemno)
  1308. X      {
  1309. X        case COMP_CHOICE : maxw = items[itemno].width / items[itemno].nopts ;
  1310. X***************
  1311. X*** 214,233 ****
  1312. X                           val = (curx - items[itemno].x) / maxw ;
  1313. X                           level = val + 1 ;
  1314. X                           items[itemno].value = val ;
  1315. X!                          color = (iscolor[d]) ? C_BEIGE : C_WHITE ;
  1316. X!                          draw_choice(W_PROPS, DIFF_CHOICE, color) ;
  1317. X                           break ;
  1318. X  
  1319. X        case MAX_DEPTH   : val = items[itemno].value ;
  1320. X                           if (direction == INCREMENT && val < MAX_PROFMAX)
  1321. X                             items[itemno].value++ ;
  1322. X!                          else if (direction == DECREMENT && val > INIT_DEPTH)
  1323. X                             items[itemno].value-- ;
  1324. X!                          SPRINTF(str, "%d", items[itemno].value) ;
  1325. X!                          color = (iscolor[d]) ? C_LGREY : C_WHITE ;
  1326. X                           set_cycle(W_PROPS, MAX_DEPTH, str) ;
  1327. X!                          profmax = items[itemno].value ;
  1328. X!                          level = 1 ;
  1329. X                           break ;
  1330. X  
  1331. X        case OPT_ANIM    : ANIMATION   = !ANIMATION ;
  1332. X--- 357,390 ----
  1333. X                           val = (curx - items[itemno].x) / maxw ;
  1334. X                           level = val + 1 ;
  1335. X                           items[itemno].value = val ;
  1336. X!                          draw_choice(W_PROPS, DIFF_CHOICE, W_COLOR(C_PANEL)) ;
  1337. X! 
  1338. X!                          items[(int) MAX_DEPTH].value = 0 ;
  1339. X!                          set_cycle(W_PROPS, MAX_DEPTH, "off") ;
  1340. X                           break ;
  1341. X  
  1342. X        case MAX_DEPTH   : val = items[itemno].value ;
  1343. X                           if (direction == INCREMENT && val < MAX_PROFMAX)
  1344. X                             items[itemno].value++ ;
  1345. X!                          else if (direction == DECREMENT && val > 0)
  1346. X                             items[itemno].value-- ;
  1347. X!                          if (!items[(int) itemno].value) STRCPY(str, "off") ;
  1348. X!                          else SPRINTF(str, "%d", items[itemno].value) ;
  1349. X                           set_cycle(W_PROPS, MAX_DEPTH, str) ;
  1350. X! 
  1351. X!                          if (items[itemno].value)
  1352. X!                            {
  1353. X!                              items[(int) DIFF_CHOICE].value = -1 ;
  1354. X!                              level = 1 ;
  1355. X!                              max_depth = items[itemno].value ;
  1356. X!                            }
  1357. X!                          else
  1358. X!                            {
  1359. X!                              items[(int) DIFF_CHOICE].value = old_diffval ;
  1360. X!                              level = old_diffval + 1 ;
  1361. X!                              max_depth = 2 ;
  1362. X!                            }
  1363. X!                          draw_choice(W_PROPS, DIFF_CHOICE, W_COLOR(C_PANEL)) ;
  1364. X                           break ;
  1365. X  
  1366. X        case OPT_ANIM    : ANIMATION   = !ANIMATION ;
  1367. X***************
  1368. X*** 247,254 ****
  1369. X  
  1370. X        case OPT_NUM     : DO_NUMBER   = !DO_NUMBER ;
  1371. X                           n = 63 - board.moves_left ;
  1372. X!                          show_number(moves[n].move, 60 - board.moves_left,
  1373. X!                                      DO_NUMBER, DO_NUMBER) ;
  1374. X                           break ;
  1375. X  
  1376. X        case OPT_FLIP    : QUICKGAME   = !QUICKGAME ;
  1377. X--- 404,412 ----
  1378. X  
  1379. X        case OPT_NUM     : DO_NUMBER   = !DO_NUMBER ;
  1380. X                           n = 63 - board.moves_left ;
  1381. X!                          if (board.moves_left < 60)
  1382. X!                            show_number(moves[n].move, 60 - board.moves_left,
  1383. X!                                        DO_NUMBER) ;
  1384. X                           break ;
  1385. X  
  1386. X        case OPT_FLIP    : QUICKGAME   = !QUICKGAME ;
  1387. X***************
  1388. X*** 306,311 ****
  1389. X--- 464,470 ----
  1390. X  }
  1391. X  
  1392. X  
  1393. X+ void
  1394. X  undo_move(player)
  1395. X  int player ;
  1396. X  {
  1397. X***************
  1398. X*** 326,333 ****
  1399. X              {
  1400. X                get_xy(i, &x, &y) ;
  1401. X                if (moves[n].square[i] == FREE)
  1402. X!                 color_area(W_MAIN, x, CY+y, PSIZE, PSIZE,
  1403. X!                            (iscolor[(int) cur_dpyno]) ? C_LBROWN : C_WHITE) ;
  1404. X                else draw_piece(moves[n].square[i], x, CY+y, RSRC) ;
  1405. X              }
  1406. X            board.square[i] = moves[n].square[i] ;
  1407. X--- 485,491 ----
  1408. X              {
  1409. X                get_xy(i, &x, &y) ;
  1410. X                if (moves[n].square[i] == FREE)
  1411. X!                 color_area(W_MAIN, x, CY+y, PSIZE, PSIZE, W_COLOR(C_SQUARE)) ;
  1412. X                else draw_piece(moves[n].square[i], x, CY+y, RSRC) ;
  1413. X              }
  1414. X            board.square[i] = moves[n].square[i] ;
  1415. X***************
  1416. X*** 338,344 ****
  1417. X        board.note       = moves[n].note ;
  1418. X        board.timeleft   = moves[n].timeleft ;
  1419. X        last_move        = board.move ;
  1420. X-       moves[n+1].move  = -1 ;
  1421. X  
  1422. X        FOR_BOARD(i) old_board.square[i] = moves[n-1].square[i] ;
  1423. X        old_board.moves_left = moves[n-1].moves_left ;
  1424. X--- 496,501 ----
  1425. X
  1426. X
  1427. END_OF_FILE
  1428. if test 46589 -ne `wc -c <'patches04d'`; then
  1429.     echo shar: \"'patches04d'\" unpacked with wrong size!
  1430. fi
  1431. # end of 'patches04d'
  1432. fi
  1433. echo shar: End of archive 4 \(of 4\).
  1434. cp /dev/null ark4isdone
  1435. MISSING=""
  1436. for I in 1 2 3 4 ; do
  1437.     if test ! -f ark${I}isdone ; then
  1438.     MISSING="${MISSING} ${I}"
  1439.     fi
  1440. done
  1441. if test "${MISSING}" = "" ; then
  1442.     echo You have unpacked all 4 archives.
  1443.     rm -f ark[1-9]isdone
  1444. else
  1445.     echo You still need to unpack the following archives:
  1446.     echo "        " ${MISSING}
  1447. fi
  1448. ##  End of shell archive.
  1449. exit 0
  1450.