home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / x / volume19 / xblckbst / patch02 < prev    next >
Encoding:
Text File  |  1993-04-27  |  37.8 KB  |  1,278 lines

  1. Newsgroups: comp.sources.x
  2. From: master@cats.UCSC.EDU (Mark Wedel)
  3. Subject: v19i079:  xblockbuster - a variation of the break-out type games, Patch02
  4. Message-ID: <1993Apr7.163442.3439@sparky.imd.sterling.com>
  5. X-Md4-Signature: 996b8fadedfa51df341db7c2d29d7ff4
  6. Date: Wed, 7 Apr 1993 16:34:42 GMT
  7. Approved: chris@sparky.imd.sterling.com
  8.  
  9. Submitted-by: master@cats.UCSC.EDU (Mark Wedel)
  10. Posting-number: Volume 19, Issue 79
  11. Archive-name: xblockbuster/patch02
  12. Environment: X11R5
  13. Patch-To: xblockbuster: Volume 19, Issue 44-49
  14.  
  15.  
  16.  
  17.  This is the second patch to XBlockBuster.  A list of changes is about 10
  18. lines below.
  19.  
  20.  This patch updates version 1.01 to version 1.02.  To apply this patch,
  21. first execute the shell archive.  After that, cd into the directory that
  22. contains the XBlockBuster *.c files, and do:
  23.  
  24.  patch < xbb.patch2
  25.  
  26.  and then your all set.
  27.  
  28.  Mark Wedel
  29. master@cats.ucsc.edu
  30.  
  31.  
  32.  
  33. #! /bin/sh
  34. # This is a shell archive.  Remove anything before this line, then unpack
  35. # it by saving it into a file and typing "sh file".  To overwrite existing
  36. # files, type "sh file -c".  You can also feed this as standard input via
  37. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  38. # will see the following message at the end:
  39. #        "End of shell archive."
  40. # Contents:  xbb.p2
  41. # Wrapped by master@sleipner on Fri Apr  2 21:07:31 1993
  42. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  43. if test -f 'xbb.p2' -a "${1}" != "-c" ; then 
  44.   echo shar: Will not clobber existing file \"'xbb.p2'\"
  45. else
  46. echo shar: Extracting \"'xbb.p2'\" \(35475 characters\)
  47. sed "s/^X//" >'xbb.p2' <<'END_OF_FILE'
  48. Xdiff -cr xblockbuster1.01/CHANGES xblockbuster1.02/CHANGES
  49. X*** xblockbuster1.01/CHANGES    Sat Mar 20 03:26:53 1993
  50. X--- xblockbuster1.02/CHANGES    Fri Apr  2 20:44:44 1993
  51. X***************
  52. X*** 1,3 ****
  53. X--- 1,49 ----
  54. X+ Changes from v1.01 to v1.02
  55. X+ 
  56. X+   rand and srand are now used as defaults on HP machines.
  57. X+ 
  58. X+   added whitepixel and blackpixel variables.  Will make changing the
  59. X+   foreground/background color easier.
  60. X+ 
  61. X+   cleaned up the code a bit so that it now compiles without any warnings
  62. X+   with gcc -Wall.  It does give one warning in stagemm.c, however.
  63. X+ 
  64. X+   added -display command line option.
  65. X+ 
  66. X+   added -playground to command line arguements.  Previously,
  67. X+   -playground was implicity assumed.  Now, if you want to use a different
  68. X+   playground, you must give the -playground option.
  69. X+ 
  70. X+   added -geometry command line option.  Only placement information is
  71. X+   used, not size information (The size XBB comes up in is pretty much
  72. X+   the mininum that can be used.  A larger window just has more white
  73. X+   area around it, so isn't useful either.)
  74. X+ 
  75. X+   'q' or 'Q' now quits the game immediately, without saving.
  76. X+ 
  77. X+   MotionHints can now be used.  I found little difference having it
  78. X+   turned on versus old style play (if running XBB on a remote host,
  79. X+   more packets were transmitted with motionhints on than before.)  Turning
  80. X+   it on may help performance on slow machines.  The definition is near
  81. X+   the top of the xblockbuster.h file. (Patches by Harvey J "Max" Thompson,
  82. X+   harveyt@sco.com)
  83. X+ 
  84. X+   Cleaned up the window redraw code.  It should not do extra refreshes
  85. X+   as it did before, and it should now re-write the top information also.
  86. X+ 
  87. X+   Fixed the horizontal shift that is used when the ball gets into an
  88. X+   infinite loop.  Under the previous method, it is possible that the
  89. X+   ball would not be shifted at all in loops.  Also, if the ball was
  90. X+   moving very slowly, the shift might be none.  Now, the ball will be
  91. X+   moved at least a certain amount if the ball is moving slowly.
  92. X+ 
  93. X+   Added -nopause command line option.  If this is selected, the game will
  94. X+   continue when the pointer is moved outside the window.  This feature can
  95. X+   also be toggled during the game with the 'p' key.
  96. X+ 
  97. X+   Better error messages are now in place.  It will now give you some
  98. X+   idea of what file it failed on.
  99. X+ 
  100. X  Changes from v1.00 to v1.01
  101. X  
  102. X    Fixed the Imakefile so StageDir now works properly.
  103. Xdiff -cr xblockbuster1.01/Imakefile xblockbuster1.02/Imakefile
  104. X*** xblockbuster1.01/Imakefile    Mon Mar 22 20:18:02 1993
  105. X--- xblockbuster1.02/Imakefile    Fri Apr  2 21:00:29 1993
  106. X***************
  107. X*** 1,4 ****
  108. X--- 1,9 ----
  109. X  XCOMM $XConsortium: Imakefile,v 1.9 91/07/16 23:06:01 gildea Exp $
  110. X+ /* Change BINDIR and MANDIR (uncomment them first) if you want to install
  111. X+  * XBlockBuster other than the standard BINDIR and MANDIR, as defined by
  112. X+  * X11, on your system.
  113. X+  */
  114. X+ 
  115. X  /*       BINDIR = /usr/games/
  116. X  */
  117. X  /*       MANDIR = /usr/local/man/man6
  118. X***************
  119. X*** 14,19 ****
  120. X--- 19,25 ----
  121. X  #endif
  122. X  
  123. X  STAGEDIR = StageDir
  124. X+ 
  125. X  /* If your on a system V machine, add -DSYSV to DEFINES below */
  126. X  
  127. X          DEFINES = -DSTAGEDIR=\"$(STAGEDIR)\"
  128. XOnly in xblockbuster1.01: MANIFEST.BAK
  129. Xdiff -cr xblockbuster1.01/README xblockbuster1.02/README
  130. X*** xblockbuster1.01/README    Mon Mar 22 20:07:43 1993
  131. X--- xblockbuster1.02/README    Tue Mar 30 20:19:06 1993
  132. X***************
  133. X*** 15,20 ****
  134. X--- 15,24 ----
  135. X      If you are on a System V machine, -DSYSV will need to be added to the
  136. X      DEFINES variable.
  137. X  
  138. X+     If XBlockBuster is seems slow, or is using a lot of network bandwidth,
  139. X+     try defining (uncommenting) the MOTION_HINTS line near the top
  140. X+     of xblockbuster.h. (see CHANGES file for more information.)
  141. X+ 
  142. X      XBlockbuster can use the same playground that Blockbuster (the sunview
  143. X      version) does.  If you want to use the same playground, set 
  144. X      StageDir (Imakefile) or LIBDIR (Makefile.noIm) appropriately.
  145. X***************
  146. X*** 24,33 ****
  147. X      If you have already installed the stages file for xblockbuster, and
  148. X      don't want to copy over them, change InstallLib in Imakefile to No.
  149. X  
  150. X!     The Imakefile, as distributed, should work fine (unless on System V).  You
  151. X!     may still want to edit the Imakefile to change where the files will
  152. X!     be installed.  Once you have edited the Imakefile to your satisfaction,
  153. X!     all that is needed is:
  154. X  
  155. X      1) xmkmf
  156. X      2) make
  157. X--- 28,37 ----
  158. X      If you have already installed the stages file for xblockbuster, and
  159. X      don't want to copy over them, change InstallLib in Imakefile to No.
  160. X  
  161. X!     The Imakefile, as distributed, should work fine (unless on System V, 
  162. X!     see above).  You may still want to edit the Imakefile to change where the
  163. X!     files will be installed.  Once you have edited the Imakefile to your
  164. X!     satisfaction, all that is needed is:
  165. X  
  166. X      1) xmkmf
  167. X      2) make
  168. X***************
  169. X*** 116,130 ****
  170. X   Fix the BUGS as listed in the man page.
  171. X  
  172. X  NOTES:
  173. X!     As far as I know, this should run on pretty much any system that
  174. X! has X installed.  However, I am limited to only running it on a sun 3/60,
  175. X! so that is all it has been tested under (X11R5).
  176. X  
  177. X      I will maintain it and release patches as required. 
  178. X  
  179. X      If you send me mail, please include a valid mail address as
  180. X  part of your signature.  I have gotten at least a few letters where
  181. X! the mail address in the header was incorrect.
  182. X  
  183. X  Mark Wedel
  184. X  master@cats.ucsc.edu
  185. X--- 120,141 ----
  186. X   Fix the BUGS as listed in the man page.
  187. X  
  188. X  NOTES:
  189. X!     I have personally verified it works on the following:
  190. X  
  191. X+     sun 3/60, sunos 4.1.1 (both color and black & white)
  192. X+ 
  193. X+     I have gotten reports it works on the following:
  194. X+ 
  195. X+     SGI with IRIS 4.0.x
  196. X+ 
  197. X+ 
  198. X      I will maintain it and release patches as required. 
  199. X  
  200. X      If you send me mail, please include a valid mail address as
  201. X  part of your signature.  I have gotten at least a few letters where
  202. X! the mail address in the header was incorrect.  Also, please be
  203. X! sure to state the version you are using (this should appear
  204. X! in both the window header, and the file patchlevel.h)
  205. X  
  206. X  Mark Wedel
  207. X  master@cats.ucsc.edu
  208. XCommon subdirectories: xblockbuster1.01/SKELS and xblockbuster1.02/SKELS
  209. XCommon subdirectories: xblockbuster1.01/STAGES and xblockbuster1.02/STAGES
  210. XCommon subdirectories: xblockbuster1.01/STAGES.try and xblockbuster1.02/STAGES.try
  211. XCommon subdirectories: xblockbuster1.01/STAGES.wacko and xblockbuster1.02/STAGES.wacko
  212. Xdiff -cr xblockbuster1.01/balls_pallet.c xblockbuster1.02/balls_pallet.c
  213. X*** xblockbuster1.01/balls_pallet.c    Fri Mar 19 02:12:30 1993
  214. X--- xblockbuster1.02/balls_pallet.c    Fri Apr  2 17:48:36 1993
  215. X***************
  216. X*** 52,59 ****
  217. X          (int)( (ball)->x ) - 8, (int)( (ball)->y ) - 8, 1)
  218. X  
  219. X  /* Procedure to draw the pallet */
  220. X! void
  221. X! draw_pallet( gc )
  222. X  GC gc;
  223. X  {
  224. X      XDrawLine( display, win, gc, pallet_xI - pallet_lengthI + 2, pallet_yI,
  225. X--- 52,58 ----
  226. X          (int)( (ball)->x ) - 8, (int)( (ball)->y ) - 8, 1)
  227. X  
  228. X  /* Procedure to draw the pallet */
  229. X! void draw_pallet( gc )
  230. X  GC gc;
  231. X  {
  232. X      XDrawLine( display, win, gc, pallet_xI - pallet_lengthI + 2, pallet_yI,
  233. X***************
  234. X*** 85,92 ****
  235. X  
  236. X  /* Procedure to show the speeds */
  237. X  #define SX     OFFSET_SPEED + 70
  238. X! void
  239. X! show_speeds(  )
  240. X  {
  241. X      int             sp;
  242. X  
  243. X--- 84,90 ----
  244. X  
  245. X  /* Procedure to show the speeds */
  246. X  #define SX     OFFSET_SPEED + 70
  247. X! void show_speeds(  )
  248. X  {
  249. X      int             sp;
  250. X  
  251. X***************
  252. X*** 202,212 ****
  253. X      case 'U':        /* because it may undo another one */
  254. X      case 'W':
  255. X      case '%':
  256. X!         if ( !( ++loop_nhits % LOOP_MAX ) )
  257. X!             ball->x -=
  258. X!                 ball->x_speed * ( double ) ( loop_nhits / LOOP_MAX ) + 1;
  259. X!         /* horizontal shift, trying to get out of a bounce loop */
  260. X!         /* negative to try to avoid leaving the stage */
  261. X          break;
  262. X      default:        /* non-solid brick */
  263. X          loop_nhits = 0;
  264. X--- 200,220 ----
  265. X      case 'U':        /* because it may undo another one */
  266. X      case 'W':
  267. X      case '%':
  268. X!         if ( !( ++loop_nhits % LOOP_MAX ) ) {
  269. X!             double shift =  ( double ) ( loop_nhits / LOOP_MAX ) + 2.0;
  270. X! 
  271. X!             if (fabs(ball->x_speed)>1.0)
  272. X!                     ball->x -= ball->x_speed * shift;
  273. X!             else if (ball->x_speed<0) 
  274. X!                 ball->x += shift;
  275. X!             else ball->x -= shift;
  276. X!         }
  277. X! 
  278. X!         /* horizontal shift, trying to get out of a bounce loop
  279. X!          * The shift should be the opposite direction the ball
  280. X!          * is moving, which hopefully will prevent it from leaving
  281. X!          * the stage
  282. X!          */
  283. X          break;
  284. X      default:        /* non-solid brick */
  285. X          loop_nhits = 0;
  286. X***************
  287. X*** 510,517 ****
  288. X      }
  289. X  }
  290. X  
  291. X! void
  292. X! check_deflections(old_pallet_y )
  293. X  double old_pallet_y;
  294. X  {
  295. X      if (ball1.quadrant) check_ball(&ball1,old_pallet_y);
  296. X--- 518,524 ----
  297. X      }
  298. X  }
  299. X  
  300. X! void check_deflections(old_pallet_y )
  301. X  double old_pallet_y;
  302. X  {
  303. X      if (ball1.quadrant) check_ball(&ball1,old_pallet_y);
  304. Xdiff -cr xblockbuster1.01/bricks.c xblockbuster1.02/bricks.c
  305. X*** xblockbuster1.01/bricks.c    Tue Nov 17 22:39:17 1992
  306. X--- xblockbuster1.02/bricks.c    Fri Apr  2 20:38:19 1993
  307. X***************
  308. X*** 86,93 ****
  309. X      char        option[30],*value;
  310. X  
  311. X      for (count=0; count<=NUM_BRICK_TYPES; count++) {
  312. X!         brick_color[count].bg = WhitePixel(display, screen_num);
  313. X!         brick_color[count].fg = BlackPixel(display, screen_num);
  314. X      }
  315. X  
  316. X  
  317. X--- 86,93 ----
  318. X      char        option[30],*value;
  319. X  
  320. X      for (count=0; count<=NUM_BRICK_TYPES; count++) {
  321. X!         brick_color[count].bg = whitepixel;
  322. X!         brick_color[count].fg = blackpixel;
  323. X      }
  324. X  
  325. X  
  326. X***************
  327. X*** 101,107 ****
  328. X  
  329. X      cursor_pr = XCreateBitmapFromData(display,win,cursor_bits, 
  330. X          cursor_width, cursor_height);
  331. X!     exact_def.pixel = WhitePixel(display, screen_num);
  332. X      XQueryColor(display, def_cmap, &exact_def);
  333. X      cursor = XCreatePixmapCursor(display, cursor_pr, cursor_pr,
  334. X          &exact_def, &exact_def, 0, 0);
  335. X--- 101,107 ----
  336. X  
  337. X      cursor_pr = XCreateBitmapFromData(display,win,cursor_bits, 
  338. X          cursor_width, cursor_height);
  339. X!     exact_def.pixel = whitepixel;
  340. X      XQueryColor(display, def_cmap, &exact_def);
  341. X      cursor = XCreatePixmapCursor(display, cursor_pr, cursor_pr,
  342. X          &exact_def, &exact_def, 0, 0);
  343. X***************
  344. X*** 282,288 ****
  345. X      case 'X':return ( brick_X_pr );
  346. X  
  347. X      default:
  348. X!         perror( "Illegal map code" );
  349. X          exit( 1 );
  350. X      }
  351. X  }
  352. X--- 282,288 ----
  353. X      case 'X':return ( brick_X_pr );
  354. X  
  355. X      default:
  356. X!         fprintf(stderr, "Illegal map code, stage %s\n",stage_name );
  357. X          exit( 1 );
  358. X      }
  359. X  }
  360. X***************
  361. X*** 297,303 ****
  362. X      case '\\':return ( launchNW0_pr );
  363. X  
  364. X      default:
  365. X!         perror( "Illegal map code" );
  366. X          exit( 1 );
  367. X      };
  368. X  }
  369. X--- 297,303 ----
  370. X      case '\\':return ( launchNW0_pr );
  371. X  
  372. X      default:
  373. X!         fprintf(stderr, "Illegal map code, stage %s\n",stage_name );
  374. X          exit( 1 );
  375. X      };
  376. X  }
  377. X***************
  378. X*** 350,356 ****
  379. X      case 'X':return(37);
  380. X  
  381. X      default:
  382. X!         perror( "Illegal map code" );
  383. X          exit( 1 );
  384. X      }
  385. X  }
  386. X--- 350,356 ----
  387. X      case 'X':return(37);
  388. X  
  389. X      default:
  390. X!         fprintf(stderr, "Illegal map code, stage %s\n",stage_name );
  391. X          exit( 1 );
  392. X      }
  393. X  }
  394. Xdiff -cr xblockbuster1.01/deflection.c xblockbuster1.02/deflection.c
  395. X*** xblockbuster1.01/deflection.c    Fri Oct 23 00:20:03 1992
  396. X--- xblockbuster1.02/deflection.c    Wed Mar 24 17:42:12 1993
  397. X***************
  398. X*** 15,22 ****
  399. X  
  400. X  #include "xblockbuster.h"
  401. X  
  402. X! void
  403. X! brick_deflection( hit, ball )
  404. X      register int    hit;    /* enumeration { HORIZONTAL, VERTICAL } */
  405. X      register struct Ball *ball;
  406. X  {
  407. X--- 15,21 ----
  408. X  
  409. X  #include "xblockbuster.h"
  410. X  
  411. X! void brick_deflection( hit, ball )
  412. X      register int    hit;    /* enumeration { HORIZONTAL, VERTICAL } */
  413. X      register struct Ball *ball;
  414. X  {
  415. X***************
  416. X*** 53,60 ****
  417. X      }
  418. X  }
  419. X  
  420. X! void
  421. X! pallet_deflection( ball )
  422. X      register struct Ball *ball;
  423. X  {
  424. X      double          excentricity, true_angle;
  425. X--- 52,58 ----
  426. X      }
  427. X  }
  428. X  
  429. X! void pallet_deflection( ball )
  430. X      register struct Ball *ball;
  431. X  {
  432. X      double          excentricity, true_angle;
  433. X***************
  434. X*** 111,117 ****
  435. X              ball1.x < -pallet_length || ball1.x > pallet_length )
  436. X                  break;
  437. X              ball1.angle = ( ball1.angle / 45 ) * M_PI_4;
  438. X!             pallet_deflection( &ball1 );
  439. X              ball1.angle = ( ball1.angle * 45 ) / M_PI_4;
  440. X              printf( "==> quadrant: %d  angle: %f\n", ball1.quadrant, ball1.angle );
  441. X          };
  442. X--- 109,115 ----
  443. X              ball1.x < -pallet_length || ball1.x > pallet_length )
  444. X                  break;
  445. X              ball1.angle = ( ball1.angle / 45 ) * M_PI_4;
  446. X!             pallet_deflection( ball1 );
  447. X              ball1.angle = ( ball1.angle * 45 ) / M_PI_4;
  448. X              printf( "==> quadrant: %d  angle: %f\n", ball1.quadrant, ball1.angle );
  449. X          };
  450. XCommon subdirectories: xblockbuster1.01/icons and xblockbuster1.02/icons
  451. Xdiff -cr xblockbuster1.01/patchlevel.h xblockbuster1.02/patchlevel.h
  452. X*** xblockbuster1.01/patchlevel.h    Thu Mar 18 01:34:39 1993
  453. X--- xblockbuster1.02/patchlevel.h    Fri Mar 26 01:21:39 1993
  454. X***************
  455. X*** 1 ****
  456. X! #define VERSION    "XBlockBuster 1.01"
  457. X--- 1 ----
  458. X! #define VERSION    "XBlockBuster 1.02"
  459. Xdiff -cr xblockbuster1.01/save.c xblockbuster1.02/save.c
  460. X*** xblockbuster1.01/save.c    Thu Mar 18 16:22:53 1993
  461. X--- xblockbuster1.02/save.c    Fri Mar 26 01:10:59 1993
  462. X***************
  463. X*** 9,16 ****
  464. X  
  465. X  #include "xblockbuster.h"
  466. X  
  467. X! void
  468. X! start_up(  )
  469. X  {
  470. X      FILE           *fd;
  471. X      char            sve[SAVEFILE_LENGTH];
  472. X--- 9,15 ----
  473. X  
  474. X  #include "xblockbuster.h"
  475. X  
  476. X! void start_up(  )
  477. X  {
  478. X      FILE           *fd;
  479. X      char            sve[SAVEFILE_LENGTH];
  480. X***************
  481. X*** 47,54 ****
  482. X      }
  483. X  }
  484. X  
  485. X! void
  486. X! save(  )
  487. X  {
  488. X      FILE           *fd;
  489. X      char            sve[SAVEFILE_LENGTH];
  490. X--- 46,52 ----
  491. X      }
  492. X  }
  493. X  
  494. X! void save(  )
  495. X  {
  496. X      FILE           *fd;
  497. X      char            sve[SAVEFILE_LENGTH];
  498. X***************
  499. X*** 65,71 ****
  500. X           pallet_modif, launch_speed );
  501. X      for ( stage_nb_tmp = 0; stage_nb_tmp < MAX_NB_STAGES; )
  502. X          fprintf( fd, "%1d", stages[stage_nb_tmp++] );
  503. X!     close( fd );
  504. X  
  505. X      show_score_board(  );    /* BYE !! */
  506. X  }
  507. X--- 63,69 ----
  508. X           pallet_modif, launch_speed );
  509. X      for ( stage_nb_tmp = 0; stage_nb_tmp < MAX_NB_STAGES; )
  510. X          fprintf( fd, "%1d", stages[stage_nb_tmp++] );
  511. X!     fclose( fd );
  512. X  
  513. X      show_score_board(  );    /* BYE !! */
  514. X  }
  515. Xdiff -cr xblockbuster1.01/score.c xblockbuster1.02/score.c
  516. X*** xblockbuster1.01/score.c    Thu Mar 18 16:49:56 1993
  517. X--- xblockbuster1.02/score.c    Wed Mar 24 18:46:51 1993
  518. X***************
  519. X*** 34,44 ****
  520. X  }
  521. X  
  522. X  
  523. X! void
  524. X! show_score_board(  )
  525. X  {
  526. X      register int    lows, s, ns,scorenum=0;
  527. X!     int        update = FALSE,made_it = FALSE,width;
  528. X      FILE           *fd;
  529. X      char            buf[PATH_LENGTH];
  530. X  
  531. X--- 34,43 ----
  532. X  }
  533. X  
  534. X  
  535. X! void show_score_board(  )
  536. X  {
  537. X      register int    lows, s, ns,scorenum=0;
  538. X!     int        update = FALSE,made_it = FALSE,width=0;
  539. X      FILE           *fd;
  540. X      char            buf[PATH_LENGTH];
  541. X  
  542. X***************
  543. X*** 124,130 ****
  544. X              else if (abs(score_board[s].balls_left)>0) width=1;
  545. X  
  546. X          
  547. X!             sprintf( buf, "%7d %*.s(%*d) %c %8s ",
  548. X                  score_board[s].score, (3-width),"    ",
  549. X                  width, abs(score_board[s].balls_left),
  550. X                  score_board[s].balls_left>0 ? ' ' : '+',
  551. X--- 123,129 ----
  552. X              else if (abs(score_board[s].balls_left)>0) width=1;
  553. X  
  554. X          
  555. X!             sprintf( buf, "%7d %.*s(%*d) %c %8s ",
  556. X                  score_board[s].score, (3-width),"    ",
  557. X                  width, abs(score_board[s].balls_left),
  558. X                  score_board[s].balls_left>0 ? ' ' : '+',
  559. X***************
  560. X*** 150,156 ****
  561. X              else if (balls_left >9) width=2;
  562. X              else if (balls_left >0) width=1;
  563. X          
  564. X!             sprintf( buf, "%7d %*.s(%*d)   %8s ",
  565. X                  score, (3-width),"    ",
  566. X                  width, balls_left, login);
  567. X          }
  568. X--- 149,155 ----
  569. X              else if (balls_left >9) width=2;
  570. X              else if (balls_left >0) width=1;
  571. X          
  572. X!             sprintf( buf, "%7d %.*s(%*d)   %8s ",
  573. X                  score, (3-width),"    ",
  574. X                  width, balls_left, login);
  575. X          }
  576. Xdiff -cr xblockbuster1.01/stage.c xblockbuster1.02/stage.c
  577. X*** xblockbuster1.01/stage.c    Sat Mar 20 03:27:18 1993
  578. X--- xblockbuster1.02/stage.c    Fri Apr  2 20:42:25 1993
  579. X***************
  580. X*** 8,20 ****
  581. X  
  582. X  #include "xblockbuster.h"
  583. X  
  584. X! void
  585. X! get_stage(  )
  586. X  {
  587. X      FILE           *fd;
  588. X      char            buf[MAX_COL + 3], stg[STAGEFILE_LENGTH];
  589. X      register int    row, col, tmp;
  590. X      register char   code;
  591. X  
  592. X      nbricks = 0;
  593. X      score_incr = 1;
  594. X--- 8,21 ----
  595. X  
  596. X  #include "xblockbuster.h"
  597. X  
  598. X! void get_stage(  )
  599. X  {
  600. X      FILE           *fd;
  601. X      char            buf[MAX_COL + 3], stg[STAGEFILE_LENGTH];
  602. X      register int    row, col, tmp;
  603. X      register char   code;
  604. X+     extern int errno;
  605. X+     extern char *sys_errlist[];
  606. X  
  607. X      nbricks = 0;
  608. X      score_incr = 1;
  609. X***************
  610. X*** 24,30 ****
  611. X      /* open next stage file */
  612. X      sprintf( stg, STAGEFILE, playground, stage_nb );
  613. X      if ( !( fd = fopen(stg, "r"))) {
  614. X!         perror( "Can't open stage" );
  615. X          exit( 1 );
  616. X      }
  617. X      /* clear msg, but leave the top line so the bonus remains on screen */
  618. X--- 25,32 ----
  619. X      /* open next stage file */
  620. X      sprintf( stg, STAGEFILE, playground, stage_nb );
  621. X      if ( !( fd = fopen(stg, "r"))) {
  622. X!         fprintf(stderr, "Can't open stage %d, error %s\n",
  623. X!             stage_nb, sys_errlist[errno]);
  624. X          exit( 1 );
  625. X      }
  626. X      /* clear msg, but leave the top line so the bonus remains on screen */
  627. X***************
  628. X*** 118,125 ****
  629. X  
  630. X  }
  631. X  
  632. X! void
  633. X! new_stage(  )
  634. X  {
  635. X      FILE           *fd;
  636. X      register int    stage_index, stage_nb_tmp;
  637. X--- 120,126 ----
  638. X  
  639. X  }
  640. X  
  641. X! void new_stage(  )
  642. X  {
  643. X      FILE           *fd;
  644. X      register int    stage_index, stage_nb_tmp;
  645. Xdiff -cr xblockbuster1.01/stagemm.c xblockbuster1.02/stagemm.c
  646. X*** xblockbuster1.01/stagemm.c    Sat Mar 13 00:55:57 1993
  647. X--- xblockbuster1.02/stagemm.c    Wed Mar 24 19:53:04 1993
  648. X***************
  649. X*** 32,38 ****
  650. X      }
  651. X      /* read stage name */
  652. X      fscanf( fd, "%s\n", stage_name );
  653. X!     printf( "%>>> %s:", stage_name );
  654. X  
  655. X      /* read pallet dimensions */
  656. X      fscanf( fd, "%d%d\n", &pallet_lengthI, &pallet_heightI );
  657. X--- 32,38 ----
  658. X      }
  659. X      /* read stage name */
  660. X      fscanf( fd, "%s\n", stage_name );
  661. X!     printf( ">>> %s:", stage_name );
  662. X  
  663. X      /* read pallet dimensions */
  664. X      fscanf( fd, "%d%d\n", &pallet_lengthI, &pallet_heightI );
  665. XOnly in xblockbuster1.02: stagemm.o
  666. Xdiff -cr xblockbuster1.01/xblockbuster.c xblockbuster1.02/xblockbuster.c
  667. X*** xblockbuster1.01/xblockbuster.c    Mon Mar 22 01:02:53 1993
  668. X--- xblockbuster1.02/xblockbuster.c    Wed Mar 31 19:27:01 1993
  669. X***************
  670. X*** 26,36 ****
  671. X  #include "icons/blockbuster.icon"
  672. X  #include "patchlevel.h"
  673. X  
  674. X! int timer_active=FALSE,    /* has the user started the ball? */
  675. X! window_active=FALSE;    /* is the pointer in the window? */
  676. X  
  677. X- 
  678. X- 
  679. X  void event_handler()
  680. X  {
  681. X      XEvent    e;
  682. X--- 26,35 ----
  683. X  #include "icons/blockbuster.icon"
  684. X  #include "patchlevel.h"
  685. X  
  686. X! int timer_active=FALSE;    /* has the user started the ball? */
  687. X! static char *disp=NULL, *play="default";
  688. X! static int winposx=0, winposy=0,geomask,no_pause=FALSE;
  689. X  
  690. X  void event_handler()
  691. X  {
  692. X      XEvent    e;
  693. X***************
  694. X*** 39,44 ****
  695. X--- 38,44 ----
  696. X      char    keystr[2],str[10];
  697. X      struct    timeval    tp,oldtp;
  698. X      struct     timezone tzp;
  699. X+     int    window_active=FALSE;    /* is the pointer in the window? */
  700. X  
  701. X      gettimeofday(&oldtp,&tzp);
  702. X      draw_pallet(gc_xor);
  703. X***************
  704. X*** 129,141 ****
  705. X--- 129,164 ----
  706. X                      "Not Saved...          ",
  707. X                      23);
  708. X              }
  709. X+             else if ((keystr[0] == 'q' ) || (keystr[0]=='Q')) {
  710. X+                 XCloseDisplay(display);
  711. X+                 exit(0);
  712. X+             }
  713. X+             else if ((keystr[0] == 'p') || (keystr[0] =='P')) {
  714. X+                 if (no_pause) no_pause=FALSE;
  715. X+                 else no_pause=TRUE;
  716. X+             }
  717. X          break;
  718. X  
  719. X          case MotionNotify:
  720. X+ #ifdef MOTION_HINTS
  721. X+             {
  722. X+                 Window rw, cw;
  723. X+                 int xw, yw, xr, yr, keys_buttons;
  724. X+                 XQueryPointer(display,e.xmotion.window,
  725. X+                     &rw, &cw, &xr, &yr, &xw, &yw,
  726. X+                     &keys_buttons);
  727. X+                 draw_pallet(gc_xor);        /* erase old pallet */
  728. X+                 pallet_x = (double)(pallet_xI=xw);
  729. X+                 mouse_yI = yw;
  730. X+                 draw_pallet(gc_xor);        /* draw new one */
  731. X+             }
  732. X+ #else
  733. X+ 
  734. X              draw_pallet(gc_xor);    /* erase old pallet */
  735. X              pallet_x = (double) (pallet_xI =e.xmotion.x);
  736. X              mouse_yI = e.xmotion.y;
  737. X              draw_pallet(gc_xor);    /* draw new one */
  738. X+ #endif
  739. X              break;
  740. X  
  741. X          case EnterNotify:
  742. X***************
  743. X*** 143,149 ****
  744. X              break;
  745. X  
  746. X          case LeaveNotify:
  747. X!             window_active = FALSE;
  748. X              break;
  749. X  
  750. X          case Expose:
  751. X--- 166,173 ----
  752. X              break;
  753. X  
  754. X          case LeaveNotify:
  755. X!             if (!no_pause)
  756. X!                 window_active = FALSE;
  757. X              break;
  758. X  
  759. X          case Expose:
  760. X***************
  761. X*** 182,249 ****
  762. X  }
  763. X  
  764. X  
  765. X! void get_playground( argc, argv )
  766. X! int argc;
  767. X! char *argv[];
  768. X  {
  769. X      DIR        *dirp;
  770. X      struct direct    *dp;
  771. X      struct stat    st;
  772. X!     int        len, found;
  773. X  
  774. X- 
  775. X      /* set default playground directory */
  776. X      strcpy( playground, STAGEDIR );
  777. X      strcat( playground, "/" );
  778. X      /* check for additional arguments (specific playground) */
  779. X!     if ( argc > 1 ) {
  780. X!         if ( argv[1][0] == '-' ) {
  781. X!             /* list available playgrounds */
  782. X!             printf( "available playgrounds are:\n" );
  783. X!             printf( "\tdefault\n" );
  784. X!             dirp = opendir(STAGEDIR);
  785. X!             for( dp=readdir( dirp ); dp!=NULL; dp=readdir( dirp ) ) {
  786. X!                 if ( !strncmp( dp->d_name, "STAGES.", 7 ) )
  787. X!                     printf( "\t%s\n", (dp->d_name)+7 );
  788. X!             }
  789. X!             closedir( dirp );
  790. X!             exit( 0 );
  791. X!         }
  792. X!         /* it's a playground name or private directory */
  793. X!         if( !strcmp( argv[1], "default" ) ) {
  794. X!             /* just in case someone used default */
  795. X!             strcat( playground, "STAGES" );
  796. X!             return;
  797. X!         }
  798. X!         found = 0;
  799. X!         len = strlen( argv[1] );
  800. X!         dirp = opendir( STAGEDIR );
  801. X          for( dp=readdir( dirp ); dp!=NULL; dp=readdir( dirp ) ) {
  802. X!             if ( dp->d_namlen == len+7 &&
  803. X!                  !strcmp( (dp->d_name)+7, argv[1] ) ) {
  804. X!                 found++;
  805. X!                 break;
  806. X!             }
  807. X          }
  808. X          closedir( dirp );
  809. X!         if ( found )
  810. X!             strcat( playground, dp->d_name );
  811. X!         else {
  812. X!             /* private dir */
  813. X!             strcpy( playground, argv[1] );
  814. X!             stat( playground, &st );
  815. X!             if( !(st.st_mode & S_IFDIR) ) {
  816. X!                 printf( "private playground <%s> not a directory.\n",
  817. X!                     playground );
  818. X!                 exit( 1 );
  819. X!             }
  820. X!         }
  821. X!     } else {
  822. X          strcat( playground, "STAGES" );
  823. X      }
  824. X  }
  825. X-                 
  826. X  
  827. X  /*** xblockbuster ***/
  828. X  void main( argc, argv )
  829. X      int             argc;
  830. X--- 206,299 ----
  831. X  }
  832. X  
  833. X  
  834. X! void get_playground()
  835. X  {
  836. X      DIR        *dirp;
  837. X      struct direct    *dp;
  838. X      struct stat    st;
  839. X!     char        path[PATH_LENGTH];
  840. X!     
  841. X  
  842. X      /* set default playground directory */
  843. X      strcpy( playground, STAGEDIR );
  844. X      strcat( playground, "/" );
  845. X+     
  846. X      /* check for additional arguments (specific playground) */
  847. X!     if ((!strcmp(play,"list")) || (!strcmp(play,"help"))) {
  848. X!         /* list available playgrounds */
  849. X!         printf( "available playgrounds are:\n" );
  850. X!         printf( "\tdefault\n" );
  851. X!         dirp = opendir(STAGEDIR);
  852. X          for( dp=readdir( dirp ); dp!=NULL; dp=readdir( dirp ) ) {
  853. X!             if ( !strncmp( dp->d_name, "STAGES.", 7 ) )
  854. X!                 printf( "\t%s\n", (dp->d_name)+7 );
  855. X          }
  856. X          closedir( dirp );
  857. X!         exit( 0 );
  858. X!     }
  859. X!     /* it's a playground name or private directory */
  860. X!     if( !strcmp( play, "default" ) ) {
  861. X!         /* just in case someone used default */
  862. X          strcat( playground, "STAGES" );
  863. X+         return;
  864. X      }
  865. X+     sprintf(path,"%s/STAGES.%s",STAGEDIR,play);
  866. X+     stat(path, &st);
  867. X+     if (S_ISDIR(st.st_mode))
  868. X+         strcpy(playground, path);
  869. X+     else {    /* private dir */
  870. X+         stat(play, &st);
  871. X+         if (!S_ISDIR(st.st_mode)) {
  872. X+             printf("Was not able to open playground %s.\n",play);
  873. X+             exit(1);
  874. X+         }
  875. X+         else strcpy(playground,play);
  876. X+     }
  877. X  }
  878. X  
  879. X+ void usage()
  880. X+ {
  881. X+     printf("Valid option command line arguements are:\n\n");
  882. X+     printf("   -display dispname     - destination display\n");
  883. X+     printf("-playground playground   - playground to use\n\n");
  884. X+     exit(0);
  885. X+ }
  886. X+ 
  887. X+ void parse_args(argc, argv)
  888. X+ int argc;
  889. X+ char *argv[];
  890. X+ {
  891. X+ 
  892. X+     int    i,tmp;
  893. X+ 
  894. X+     for (i=1; i<argc; i++) {
  895. X+         if (!strcmp(argv[i],"-display"))
  896. X+             if (++i==argc) usage();
  897. X+             else disp = argv[i];
  898. X+         else if (!strcmp(argv[i],"-playground"))
  899. X+             if (++i==argc) usage();
  900. X+             else play = argv[i];
  901. X+         else if (!strcmp(argv[i],"-geometry")) {
  902. X+             if (++i==argc) usage();
  903. X+             else geomask = XParseGeometry(argv[i], &winposx,
  904. X+                 &winposy, &tmp, &tmp);
  905. X+         }
  906. X+         else if (!strcmp(argv[i],"-nopause"))
  907. X+             no_pause=TRUE;
  908. X+         else usage();
  909. X+     }
  910. X+ }
  911. X+ 
  912. X+ void do_geometry()
  913. X+ {
  914. X+     if (geomask & XNegative) 
  915. X+         winposx += WidthOfScreen(ScreenOfDisplay(display,screen_num))
  916. X+              - STAGE_WIDTH_IN_PIXELS - BORDER_WIDTH*2;
  917. X+     if (geomask & YNegative)
  918. X+         winposy += HeightOfScreen(ScreenOfDisplay(display,screen_num))
  919. X+              - STAGE_HEIGHT_IN_PIXELS - BORDER_WIDTH*2;
  920. X+ }
  921. X+ 
  922. X  /*** xblockbuster ***/
  923. X  void main( argc, argv )
  924. X      int             argc;
  925. X***************
  926. X*** 261,267 ****
  927. X      /* who am i ? ['cuserid(3S)' is fooled by 'su(1)'] */
  928. X      login = getpwuid( getuid(  ) )->pw_name;
  929. X  
  930. X!     if ((display=XOpenDisplay(NULL))==NULL) {
  931. X          fprintf(stderr, "Unable to open display: %s\n",
  932. X              XDisplayName(NULL));
  933. X          exit(1);
  934. X--- 311,320 ----
  935. X      /* who am i ? ['cuserid(3S)' is fooled by 'su(1)'] */
  936. X      login = getpwuid( getuid(  ) )->pw_name;
  937. X  
  938. X!     parse_args(argc, argv);
  939. X!     get_playground();
  940. X! 
  941. X!     if ((display=XOpenDisplay(disp))==NULL) {
  942. X          fprintf(stderr, "Unable to open display: %s\n",
  943. X              XDisplayName(NULL));
  944. X          exit(1);
  945. X***************
  946. X*** 268,279 ****
  947. X      }
  948. X  
  949. X      screen_num = DefaultScreen(display);
  950. X      win = XCreateSimpleWindow(display, RootWindow(display, screen_num),
  951. X!         0, 0, STAGE_WIDTH_IN_PIXELS, STAGE_HEIGHT_IN_PIXELS,
  952. X!         0, 2, WhitePixel(display, screen_num));
  953. X  
  954. X      XSelectInput(display, win, ExposureMask | ButtonPressMask |
  955. X          LeaveWindowMask | EnterWindowMask | KeyPressMask |
  956. X          PointerMotionMask);
  957. X  
  958. X  
  959. X--- 321,342 ----
  960. X      }
  961. X  
  962. X      screen_num = DefaultScreen(display);
  963. X+ 
  964. X+     do_geometry();
  965. X+ 
  966. X+     whitepixel = WhitePixel(display, screen_num);
  967. X+     blackpixel = BlackPixel(display, screen_num);
  968. X+ 
  969. X      win = XCreateSimpleWindow(display, RootWindow(display, screen_num),
  970. X!         winposx, winposy, STAGE_WIDTH_IN_PIXELS,
  971. X!          STAGE_HEIGHT_IN_PIXELS, BORDER_WIDTH, blackpixel,
  972. X!          whitepixel);
  973. X  
  974. X      XSelectInput(display, win, ExposureMask | ButtonPressMask |
  975. X          LeaveWindowMask | EnterWindowMask | KeyPressMask |
  976. X+ #ifdef MOTION_HINTS
  977. X+         PointerMotionHintMask |
  978. X+ #endif
  979. X          PointerMotionMask);
  980. X  
  981. X  
  982. X***************
  983. X*** 285,292 ****
  984. X      font_height=font_info->max_bounds.ascent + font_info->max_bounds.descent +1;
  985. X  
  986. X  
  987. X!     xgcvalues.foreground = BlackPixel(display, screen_num);
  988. X!     xgcvalues.background = WhitePixel(display, screen_num);
  989. X  
  990. X      
  991. X      xgcvalues.graphics_exposures = False;
  992. X--- 348,355 ----
  993. X      font_height=font_info->max_bounds.ascent + font_info->max_bounds.descent +1;
  994. X  
  995. X  
  996. X!     xgcvalues.foreground = blackpixel;
  997. X!     xgcvalues.background = whitepixel;
  998. X  
  999. X      
  1000. X      xgcvalues.graphics_exposures = False;
  1001. X***************
  1002. X*** 341,348 ****
  1003. X      }
  1004. X  
  1005. X      size_hints.flags = PMinSize;
  1006. X!     size_hints.x = 0;
  1007. X!     size_hints.y = 0;
  1008. X      size_hints.height = STAGE_HEIGHT_IN_PIXELS;
  1009. X      size_hints.min_height = STAGE_HEIGHT_IN_PIXELS;
  1010. X      size_hints.width = STAGE_WIDTH_IN_PIXELS;
  1011. X--- 404,412 ----
  1012. X      }
  1013. X  
  1014. X      size_hints.flags = PMinSize;
  1015. X!     if (geomask!=0) size_hints.flags |= USPosition;
  1016. X!     size_hints.x = winposx;
  1017. X!     size_hints.y = winposy;
  1018. X      size_hints.height = STAGE_HEIGHT_IN_PIXELS;
  1019. X      size_hints.min_height = STAGE_HEIGHT_IN_PIXELS;
  1020. X      size_hints.width = STAGE_WIDTH_IN_PIXELS;
  1021. X***************
  1022. X*** 364,370 ****
  1023. X      /* initialize random (used to determine next stage) */
  1024. X      SRAND( time( 0 ) );
  1025. X  
  1026. X-     get_playground( argc, argv );
  1027. X  
  1028. X      /* and off we go */
  1029. X      bricks_init();
  1030. X--- 428,433 ----
  1031. X***************
  1032. X*** 382,388 ****
  1033. X  /* Most SysV's don't have a usleep.  Sone of them have select. */
  1034. X  
  1035. X  usleep( usecs )
  1036. X! int usecs;
  1037. X      {
  1038. X      struct timeval timeout;
  1039. X  
  1040. X--- 445,451 ----
  1041. X  /* Most SysV's don't have a usleep.  Sone of them have select. */
  1042. X  
  1043. X  usleep( usecs )
  1044. X! unsigned usecs;
  1045. X      {
  1046. X      struct timeval timeout;
  1047. X  
  1048. Xdiff -cr xblockbuster1.01/xblockbuster.h xblockbuster1.02/xblockbuster.h
  1049. X*** xblockbuster1.01/xblockbuster.h    Sat Mar 20 03:27:34 1993
  1050. X--- xblockbuster1.02/xblockbuster.h    Tue Mar 30 20:11:59 1993
  1051. X***************
  1052. X*** 27,34 ****
  1053. X--- 27,42 ----
  1054. X  
  1055. X  #define FONT    "10x20"
  1056. X  
  1057. X+ /* define if you want pointer motion hints used (read CHANGES file) */
  1058. X+ /*#define MOTION_HINTS*/
  1059. X+ 
  1060. X+ #ifdef hpux
  1061. X+ #define RAND() rand()
  1062. X+ #define SRAND(n) srand(n)
  1063. X+ #else
  1064. X  #define RAND() random()
  1065. X  #define SRAND(n) srandom(n)
  1066. X+ #endif
  1067. X  
  1068. X  /* You may need to uncomment some of these if your system does not have
  1069. X   * them.  If you need to do so, please let me know, so I can put them
  1070. X***************
  1071. X*** 51,58 ****
  1072. X--- 59,68 ----
  1073. X  GC        gc, gc_erase, gc_color,gc_xor;
  1074. X  XFontStruct    *font_info;
  1075. X  int        screen_num, font_width, font_height,extra_draw;
  1076. X+ unsigned long    whitepixel, blackpixel;
  1077. X  
  1078. X  /*** windowing objects ***/
  1079. X+ #define BORDER_WIDTH    2    /* borderwidth X puts around the window */
  1080. X  
  1081. X  #define BORDER         50
  1082. X  #define MSG_HEIGHT     font_height*2 + 4
  1083. X***************
  1084. X*** 219,221 ****
  1085. X--- 229,267 ----
  1086. X  
  1087. X  #define ITIMER_DELAY    5000
  1088. X  
  1089. X+ /* Prototype some functions here */
  1090. X+ #ifdef __GNUC__
  1091. X+ void fclose(FILE *);                    /* system */
  1092. X+ void fprintf(FILE*, char *, ...);            /* system */
  1093. X+ void fscanf(FILE *, char *, ...);            /* system */
  1094. X+ int  gettimeofday(struct timeval*, struct timezone*);    /* system */
  1095. X+ void perror(char *);                    /* system */
  1096. X+ void printf(char *, ...);                /* system */
  1097. X+ void rewind(FILE *);                    /* system */
  1098. X+ int  strcasecmp(char *, char*);                /* system */
  1099. X+ time_t time(time_t*);                    /* system */
  1100. X+ void usleep(unsigned);                    /* system */
  1101. X+ 
  1102. X+ int  RAND();                        /* system */
  1103. X+ void SRAND(int);                    /* system */
  1104. X+ 
  1105. X+ void ball_init();                    /* balls_pallet.c */
  1106. X+ void check_deflections(double );            /* balls_pallet.c */
  1107. X+ void draw_all_balls();                    /* balls_pallet.c */
  1108. X+ void draw_pallet(GC);                    /* balls_pallet.c */
  1109. X+ void move_balls();                    /* balls_pallet.c */
  1110. X+ void print_balls();                    /* balls_pallet.c */
  1111. X+ void print_score();                    /* balls_pallet.c */
  1112. X+ void show_speeds();                    /* balls_paller.c */
  1113. X+ void bricks_init();                    /* bricks.c */
  1114. X+ void draw_brick(int, int ) ;                /* bricks.c */
  1115. X+ void draw_brick0(int, int ) ;                /* bricks.c */
  1116. X+ void brick_deflection( int, struct Ball* );        /* deflection.c */
  1117. X+ void pallet_deflection(struct Ball * );            /* deflection.c */
  1118. X+ void save();                        /* save.c */
  1119. X+ void start_up();                    /* save.c */
  1120. X+ void get_stage();                    /* stage.c */
  1121. X+ void new_stage(  );                    /* stage.c */
  1122. X+ void show_score_board(  );                /* score.c */
  1123. X+ 
  1124. X+ #endif
  1125. Xdiff -cr xblockbuster1.01/xblockbuster.man xblockbuster1.02/xblockbuster.man
  1126. X*** xblockbuster1.01/xblockbuster.man    Tue Mar 23 00:32:13 1993
  1127. X--- xblockbuster1.02/xblockbuster.man    Wed Mar 31 19:43:21 1993
  1128. X***************
  1129. X*** 3,15 ****
  1130. X  .SH NAME
  1131. X  xblockbuster \- game
  1132. X  .SH SYNOPSIS
  1133. X! .B xblockbuster
  1134. X! .I [play_ground]
  1135. X  .SH DESCRIPTION
  1136. X! The play ground is either the anonymous public play ground (no argument),
  1137. X! a named public playground or a privately owned directory.
  1138. X! The list of available named public play grounds is obtained by giving "-"
  1139. X! as the play ground argument.
  1140. X  .LP
  1141. X  The object of the game is to collect as many points as possible by
  1142. X  .I busting
  1143. X--- 3,19 ----
  1144. X  .SH NAME
  1145. X  xblockbuster \- game
  1146. X  .SH SYNOPSIS
  1147. X! .B xblockbuster -playground
  1148. X! .I play_ground
  1149. X! .B -display
  1150. X! .I display
  1151. X! .B -geometry
  1152. X! .I geometry
  1153. X! .B -nopause
  1154. X  .SH DESCRIPTION
  1155. X! XBlockbuster is a variation of the break-out type games, only a bit more
  1156. X! complex in the type of bricks it has and effects the bricks have.  It is
  1157. X! X11 based.
  1158. X  .LP
  1159. X  The object of the game is to collect as many points as possible by
  1160. X  .I busting
  1161. X***************
  1162. X*** 45,54 ****
  1163. X  LEFT moves it up one row, MIDDLE moves it all the way down again.
  1164. X  Each ball is launched with the RIGHT mouse button.
  1165. X  .LP
  1166. X! A stage can be halted by closing the window, or moving the pointer out
  1167. X! of the window.
  1168. X  Be advised however, that the game will resume immediately upon opening the
  1169. X  window.
  1170. X  .LP
  1171. X  During a game, the score, number of balls left and speeds are shown.
  1172. X  The speeds are represented by up to 3 thin lines (one for each ball),
  1173. X--- 49,60 ----
  1174. X  LEFT moves it up one row, MIDDLE moves it all the way down again.
  1175. X  Each ball is launched with the RIGHT mouse button.
  1176. X  .LP
  1177. X! A stage can be halted by closing the window.
  1178. X  Be advised however, that the game will resume immediately upon opening the
  1179. X  window.
  1180. X+ If no-pause has not
  1181. X+ been selected (see below), moving the pointer out 
  1182. X+ of the XBlockBuster window will also stop the action.
  1183. X  .LP
  1184. X  During a game, the score, number of balls left and speeds are shown.
  1185. X  The speeds are represented by up to 3 thin lines (one for each ball),
  1186. X***************
  1187. X*** 63,68 ****
  1188. X--- 69,111 ----
  1189. X  The score board shows scores, number of balls left between parentheses if any
  1190. X  and user name.
  1191. X  Finally, an indication of your current pallet shrinkage is given.
  1192. X+ .LP
  1193. X+ At any time, 'q' or 'Q' may be pressed to quit the present game.  This quits
  1194. X+ the game immediately, so may be useful if your boss is closing in.  Also
  1195. X+ useful if you mess up on the first stage, and thus, continuing play of that
  1196. X+ game is no longer worth it.
  1197. X+ .LP
  1198. X+ \'P' or 'p' may be pressed during the game to toggle the no-pause option.
  1199. X+ When no-pause is active, the game will continue even when the mouse pointer
  1200. X+ is outside the window.  With it turned off, action stops once the mouse
  1201. X+ pointer is outside the window.
  1202. X+ .SH COMMAND LINE OPTIONS
  1203. X+ .TP 8
  1204. X+ -playground \fIplayground\fR
  1205. X+ This determines the playground to use.  Either the directory containing
  1206. X+ the score file, stages, and save directory can be given, or only the
  1207. X+ final part after the STAGES name can be given for public play grounds.
  1208. X+ 
  1209. X+ By default, the standard playground will be used if this option is
  1210. X+ not given.
  1211. X+ 
  1212. X+ To see a list of the public play grounds, enter \fIlist\fB as the 
  1213. X+ playground name.
  1214. X+ .TP
  1215. X+ -display \fIdisplay\fR
  1216. X+ This is the display to run XBlockBuster on.  If not otherwise specified,
  1217. X+ the DISPLAY environmental variable will be used to determine the 
  1218. X+ display to use.
  1219. X+ .TP
  1220. X+ -geometry \fIgeometry\fR
  1221. X+ This is the geometry to use for the XBlockBuster window.  Only the
  1222. X+ positioning, and not size, information is used.  If size information
  1223. X+ is given, it is just ignored.
  1224. X+ .TP
  1225. X+ -nopause
  1226. X+ Determines if no-pause mode is on by default when the game is started up.
  1227. X+ When no-pause mode is on, action continues if the mouse pointer is outside
  1228. X+ the XBlockBuster window.
  1229. X  .SH NOTES
  1230. X  .LP
  1231. X  In order to avoid infinite loops
  1232. X***************
  1233. X*** 93,99 ****
  1234. X  during play.
  1235. X  .SH "CREATION OF PLAY GROUNDS"
  1236. X  A private play ground can be created in any directory.
  1237. X! The stages can be defined from the ascii map codes using any text editor
  1238. X  They must be numbered consecutively from 0 with the total number
  1239. X  (i.e., one more than the highest number) available in the file nb_stages.
  1240. X  Furthermore a directory 'save' and an empty file 'scores' must be created.
  1241. X--- 136,142 ----
  1242. X  during play.
  1243. X  .SH "CREATION OF PLAY GROUNDS"
  1244. X  A private play ground can be created in any directory.
  1245. X! The stages can be defined from the ascii map codes using any text editor.
  1246. X  They must be numbered consecutively from 0 with the total number
  1247. X  (i.e., one more than the highest number) available in the file nb_stages.
  1248. X  Furthermore a directory 'save' and an empty file 'scores' must be created.
  1249. X***************
  1250. X*** 230,237 ****
  1251. X  .SH BUGS
  1252. X  When two balls hit the same brick simultaneously,
  1253. X  one may leave a shadow on the stage.
  1254. X- .LP
  1255. X- Sometimes a ball image is left when the window is re-opened.
  1256. X  .LP
  1257. X  If the ball hits the bottom corners of the playing area, they will at times
  1258. X  reflect back in a reverse direction, instead of reflecting downward and
  1259. X--- 273,278 ----
  1260. XCommon subdirectories: xblockbuster1.01/STAGES/save and xblockbuster1.02/STAGES/save
  1261. XCommon subdirectories: xblockbuster1.01/STAGES.try/save and xblockbuster1.02/STAGES.try/save
  1262. XCommon subdirectories: xblockbuster1.01/STAGES.wacko/save and xblockbuster1.02/STAGES.wacko/save
  1263. END_OF_FILE
  1264. if test 35475 -ne `wc -c <'xbb.p2'`; then
  1265.     echo shar: \"'xbb.p2'\" unpacked with wrong size!
  1266. fi
  1267. # end of 'xbb.p2'
  1268. fi
  1269. echo shar: End of shell archive.
  1270. exit 0
  1271.  
  1272. exit 0 # Just in case...
  1273. -- 
  1274.   // chris@IMD.Sterling.COM            | Send comp.sources.x submissions to:
  1275. \X/  Amiga - The only way to fly!      |
  1276.  "It's intuitively obvious to the most |    sources-x@imd.sterling.com
  1277.   casual observer..."                  |
  1278.