home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / games / volume15 / dinkum / part03 < prev    next >
Encoding:
Internet Message Format  |  1993-01-26  |  53.6 KB

  1. Path: uunet!news.tek.com!master!saab!billr
  2. From: billr@saab.CNA.TEK.COM (Bill Randle)
  3. Newsgroups: comp.sources.games
  4. Subject: v15i023:  dinkum - australian text adventure game, Part03/06
  5. Message-ID: <3981@master.CNA.TEK.COM>
  6. Date: 29 Nov 92 20:31:27 GMT
  7. Sender: news@master.CNA.TEK.COM
  8. Lines: 1543
  9. Approved: billr@saab.CNA.TEK.COM
  10. Xref: uunet comp.sources.games:1522
  11.  
  12. Submitted-by: Gary Allen <gary@sun.mech.uq.oz.au>
  13. Posting-number: Volume 15, Issue 23
  14. Archive-name: dinkum/Part03
  15. Environment: Unix, DOS
  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 3 (of 6)."
  26. # Contents:  describe.c taker.c
  27. # Wrapped by billr@saab on Sun Nov 29 12:25:49 1992
  28. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  29. if test -f 'describe.c' -a "${1}" != "-c" ; then 
  30.   echo shar: Will not clobber existing file \"'describe.c'\"
  31. else
  32. echo shar: Extracting \"'describe.c'\" \(23091 characters\)
  33. sed "s/^X//" >'describe.c' <<'END_OF_FILE'
  34. X#define DSCRB
  35. X#include "dink_sym.h"
  36. X#include "dink_glb.h"
  37. Xvoid describe(n)
  38. X/*********************************************************/
  39. X/*                                                       */
  40. X/*           --- Room Description and Path ---           */
  41. X/*                                                       */
  42. X/*      Program by Gary A. Allen, Jr.  6 June 1989       */
  43. X/*        (c) Copywrite 1989 by Gary A. Allen, Jr.       */
  44. X/*                                                       */
  45. X/*********************************************************/
  46. Xint n ;         
  47. X{
  48. X#ifdef __TURBOC__
  49. Xvoid ender(int) ;
  50. Xchar getch(void) ;
  51. X#endif
  52. X
  53. Xstatic int old_n, dark_count, sw_hint = FALSE ;
  54. Xchar chr ;
  55. X
  56. X/* room description */
  57. Xstatic char *descript[] = {
  58. X"are in a grassy meadow that stretches out in all directions",  /* 0 */
  59. X"are on a path next to the meadow.  To the east is a road.",    /* 1 */
  60. X"are approaching a thickly wooded forest full of gum trees.",   /* 2 */
  61. X"have hiked a short distance and then climbed up onto a river dike.",
  62. X"are next to a wide murky river that looks dangerous.",         /* 4 */
  63. X"--- marker for drowing in river",                              /* 5 */
  64. X"are next to a billabong with a stream feeding into it.",       /* 6 */
  65. X"feel something slimey under the water wraping itself around your leg.",
  66. X"--- marker for the bunyip",                                    /* 8 */
  67. X"are back on top of the dike next to a great meandering river.", 
  68. X"are waist deep in the stream, the water is cool and refreshing.",
  69. X"are in a thickly wooded forest. There is a rich eucalyptus smell",
  70. X"are deeper into the gum tree forest and getting disoriented.",
  71. X"are deep in a gum tree forest and appear to be ***lost***.",   /* 13 */
  72. X"are wading in the billabong.  The water is stagnant and smelly.",
  73. X"approach an area with high grass. There are grey kangaroos nearby.",
  74. X"are deep in the grass, which is waist high.",                  /* 16 */
  75. X"see snakes slither by in the grass.  Some are quite big.",     /* 17 */
  76. X"--- marker for the Taipan",                                    /* 18 */
  77. X"leave the grassy area and head towards the meadow.",           /* 19 */
  78. X"are on a road.  Far to the east are some deserted buildings.", /* 20 */
  79. X"are on a broad road that stretches out to the horizon.",       /* 21 */
  80. X"are west from the head gear of the abandoned ACME Gold Mine.", /* 22 */
  81. X"are in an orange desert with bulldust swirling about you.",    /* 23 */
  82. X"are in a desert full of high sand dunes.",                     /* 24 */
  83. X"are in between two sand dunes and can see only sand.",         /* 25 */
  84. X"are in a sandy desert with large thorny spinifexes rolling by you.",
  85. X"are west of the mine shaft lift.  The mine tower looms over head.",
  86. X"are walking away from a forest of sweet smelling gum trees. ", /* 28 */
  87. X"find yourself on a potholed bitumen road that seems to be endless.",
  88. X"are southwest of the mine lift.  To the south is desert.",     /* 30 */
  89. X"are southeast of the mine lift.  To the south is desert.",     /* 31 */
  90. X"are east of the mine tower between the lift and the office.",  /* 32 */
  91. X"are east of the mine office building.  There is no door here.",
  92. X"are at the north eastern corner of the office building.",      /* 34 */
  93. X"are at the north western corner of the office building.",      /* 35 */
  94. X"are west of the ACME Gold Mine office building entrance.",     /* 36 */
  95. X"are in the entry hall.  There are doors to the north, south and west.",
  96. X"are in the Site Manager's office.  The only exit is to the south.",
  97. X"are in the western section of the Geologist's Office.",        /* 39 */
  98. X"are in the store room. The only exit is to the south.",    /* 40 */
  99. X"are in the eastern section of the Geologist's Office.",        /* 41 */
  100. X"continue walking on the road, which seems to go nowhere.",     /* 42 */
  101. X"are inside the mine lift.  The doorway is to the west.",
  102. X"are in a dimly lit tunnel going west.  To the east is the lift.",
  103. X"are in a poorly lit tunnel going east, west and south.",       /* 45 */
  104. X"are in a dimly lit tunnel going north.  To the east is the lift.",
  105. X"are in a pasture.  To the east is a road and west is a billabong.",
  106. X"are in a T-section going north, south or east.",               /* 48 */
  107. X"are in a T-section going north, south or west.",               /* 49 */
  108. X"are in a T-section going north, west or east.",                /* 50 */
  109. X"are in a T-section going east, west or south.",                /* 51 */
  110. X"are in a T-section going northeast, northwest, or southwest.", /* 52 */
  111. X"are in a T-section going northeast, northwest, or southeast.", /* 53 */
  112. X"are in a T-section going northeast, southeast, or southwest.",
  113. X"are in a tunnel going north and south.",                       /* 55 */
  114. X"are in a tunnel going east and west.",                         /* 56 */
  115. X"are in a tunnel going northwest and southeast.",               /* 57 */
  116. X"are in a tunnel going northeast and southwest.",               /* 58 */
  117. X"are in a tunnel that has a hole in the ground and goes east/west.",
  118. X"are in an L-section going southeast or up through a hole in the roof.",
  119. X"are in an L-section that goes south or up through a hole in the roof.",
  120. X"are in an L-section that goes east or up through a hole in the roof.",
  121. X"are in an L-section that goes west or up through a hole in the roof.",
  122. X"are in a Y-section that goes north, southeast, or southwest.", /* 64 */
  123. X"are in a Y-section that goes south, northeast, or northwest.", /* 65 */
  124. X"are in a Y-section that goes west, northeast, or southeast.",  /* 66 */
  125. X"are in a Y-section that goes east, northwest, or southwest.",  /* 67 */
  126. X"are in a Y-section that goes north, south, or southwest.",     /* 68 */
  127. X"are in a Y-section that goes south, north, or northwest.",     /* 69 */
  128. X"are in a Y-section that goes west, east, or southeast.",       /* 70 */
  129. X"are in a Y-section that goes east, west, or southwest.",       /* 71 */
  130. X"are in a Y-section that goes north, south, or southeast.",     /* 72 */
  131. X"are in a Y-section that goes south, north, or northeast.",     /* 73 */
  132. X"are in a Y-section that goes west, east, or northeast.",       /* 74 */
  133. X"are in a Y-section that goes east, west, or northwest.",       /* 75 */
  134. X"are in a Y-section that goes down a manhole, northwest, or southwest.",
  135. X"are in a Y-section that goes down a manhole, northeast, or southeast.",
  136. X"are at a tunnel crossing.  You can go north, east, south, or west.",
  137. X"are at a tunnel crossing going nw, ne, sw, and se.",           /* 79 */
  138. X"are in a tunnel corner that goes south and west.",             /* 80 */
  139. X"are in a tunnel corner that goes south and east.",             /* 81 */
  140. X"are in a tunnel corner that goes north and west.",             /* 82 */
  141. X"are in a tunnel corner that goes north and east.",             /* 83 */
  142. X"are in a tunnel corner that goes southeast and southwest.",    /* 84 */
  143. X"are in a tunnel corner that goes southeast and northeast.",    /* 85 */
  144. X"are in a tunnel corner that goes northwest and southwest.",    /* 86 */
  145. X"are in a tunnel corner that goes northwest and northeast.",    /* 87 */
  146. X"are in a tunnel going southwest with a stairway going down.",  /* 88 */
  147. X"are in a tunnel going northeast with a stairway going up.",    /* 89 */
  148. X"are at a deadend.",                                            /* 90 */
  149. X"are in the ventilation equipment room. The exit is to the west.",
  150. X"are in the worker's lunch room. The exit is to the north.",
  151. X"are at the stope face with the hydraulic jacks still in place.",
  152. X"are in an ore storage area with exits to the south and west.",
  153. X"are in a T-section going northwest, southeast, or southwest.",
  154. X"are in a tunnel going northeast/southwest, with a hole in the roof.",
  155. X"are in a corner going north and east, with a manhole going down.",
  156. X"are in a tunnel going west with a stairway going up.",         /* 98 */
  157. X"are in a tunnel going east with a stairway going down.",       /* 99 */
  158. X"can go north or climb down a man hole.",                       /*100 */
  159. X"are at a caved in section of tunnel which is now a dead end.", /*101 */
  160. X"are in a bleak and forbidding desert of bare flat stone.",     /*102 */
  161. X"are on a two lane road with gum trees on either side.",        /*103 */
  162. X"are in a flat and boring desert.",                /*104 */
  163. X"are in front of Ned Kelly's desert hide out.",            /*105 */
  164. X"are in a vast desert of dry salt lakes shimmering with mirages.",
  165. X"are inside Ned Kelly's hide out.  The only way out is to the west.",
  166. X"are north of a grassy area and within the bend of a great river.", 
  167. X"are south of a grassy area and on the edge of a gum tree forest.",
  168. X"can go east or climb down a man hole.",            /*110 */
  169. X"can go east, west or climb up through a hole in the roof.",    /*111 */
  170. X"are at the Level #67 Shift Foreman's office. You can go west.",
  171. X"are at the spacecraft's end.  You can go north, south and west.",
  172. X"are near the spacecraft's fin. You can go south or north-east.",
  173. X"are next to the ship's wing.  You can go south-west or south-east.",
  174. X"are beside the ship's window.  You can go north-west or south.",
  175. X"are next to the spacecraft's Mach probe.  You can north or south.",
  176. X"are facing the access hatch.  You can go up, north, or south-west.",
  177. X"are beside the landing gear.  You can go north-east or north-west.",
  178. X"are beside the wing's edge.  You can go north or south-east.",
  179. X"are in the spacecraft's airlock.  You can go down or north.",
  180. X"are in the central access way.  You can east, west, or south.",
  181. X"are on the flight deck of an ancient spacecraft.  You can go west.",
  182. X"are at a mysterious control panel.  You can east or west.",    /*124 */
  183. X"are in the chamber with glowing hexagons. The only exit is east.",
  184. X"are in a room with a tank full of dark blue liquid.  You can go west.",
  185. X"are in a cavernous room with a huge silver gong in the middle.",
  186. X"are in a room with a warning on the wall going north, south and west.",
  187. X"are in a closet stinking of moth balls. The only exit is north.",
  188. X"are in the guard room. The closet is south, the main doorway is east.",
  189. X"are in the prayer room of the Iranian Parliament. To escape, go west.",
  190. X"are in a tunnel going east and west with a message on the wall."
  191. X}  ;
  192. X
  193. X/* give the short description */
  194. Xif (((object[O_torch][J_loc] == B_have)&&object[O_torch][J_property])|| 
  195. X    (n < 186)||(n > 202)) { 
  196. X/* Deal with the possibility of a hint for the safe */
  197. X    if (n == R_office_mang) {
  198. X        if ((!sw_active)&&(object[O_rifle][J_property] != 0)&&
  199. X(enemy[N_ned][E_location] == B_destroyed)&&(!sw_hint)) {
  200. X            sw_hint = TRUE ;
  201. Xprintf("For half of the bullets in your M-16 rifle I will\n") ;
  202. Xprintf("give you a hint on how to get into the safe.\n") ;
  203. Xprintf("             Are you interested? \n") ;
  204. X
  205. X            for (;;) {
  206. X
  207. X#ifndef __TURBOC__
  208. X                do {
  209. Xprintf("(Answer:  Yes or No) ") ; 
  210. X                } while ('\n' == (chr = getchar())) ;
  211. X
  212. X                while ('\n' != getchar()) ;
  213. X#endif
  214. X
  215. X#ifdef __TURBOC__
  216. X                printf("\n") ;
  217. X                do {
  218. Xprintf("(Answer:  Yes or No) ") ; 
  219. X                } while ('\n' == (chr = getch())) ;
  220. X                printf("\n") ;
  221. X#endif
  222. X
  223. X                if (('n' == chr)||
  224. X('N' == chr)||('y' == chr)||('Y' == chr)) {
  225. X                    if (('y' == chr)||
  226. X                        ('Y' == chr)) { 
  227. X                object[O_rifle][J_property] /= 2 ;
  228. Xprintf("\nTake the missing word in the sentence:\n") ;
  229. Xprintf("                      \"The Chook **** an egg.\"\n");
  230. Xprintf("and spell it backwards.  Then look very carefully at the\n") ;
  231. Xprintf("map which you found in the manager's office.  Also, you\n") ;
  232. Xprintf("now have %d bullets in your rifle.\n",
  233. X                object[O_rifle][J_property]) ;
  234. X                    }
  235. X                break ;
  236. X                }
  237. X            }
  238. X            printf("\n") ;
  239. X        }
  240. X    }
  241. Xprintf ("You %s \n",descript[room[n][M_descp]]);
  242. X    old_n = n;
  243. X    dark_count = 0 ;
  244. X
  245. X}
  246. X
  247. X/* deal with dark rooms */
  248. Xelse {
  249. X    if (n == 186) {
  250. Xprintf("You have entered a north/south passage which does not have\n") ;
  251. Xprintf("electric lighting.  There is some light coming in from the\n");
  252. Xprintf("north, but the tunnel to the south is completely dark.\n");
  253. X        return;
  254. X    }
  255. X    if (n == 187) {
  256. Xprintf("The tunnel you are in is pitch black.  There is a little\n");
  257. Xprintf("light coming in from the north.  If you keep going you will\n");
  258. Xprintf("probably fall down a hole.\n") ;
  259. X        return ;
  260. X    }
  261. X    if ((n >= 188)&&(n <= 202)) {
  262. X        if ((dark_count==0)||(old_n == n)) {
  263. Xprintf("You are in a mine tunnel in total darkness, which is \n") ;
  264. Xprintf("extremely dangerous.  I have no clue where we are going.\n") ;
  265. Xprintf("Let's go back to where there is some light!\n") ;
  266. X            ++dark_count ;
  267. X            old_n = n;
  268. X        }
  269. X        else {
  270. Xprintf("Twit!!  You have fallen down a hole and broken your neck!\n");
  271. X        ender(F_died) ;
  272. X        }
  273. X        return ;
  274. X    }
  275. X}
  276. X} /* end of the "describe" subroutine */
  277. Xvoid rdtxt(k)
  278. X/*********************************************************/
  279. X/*                                                       */
  280. X/*     --- Text for the "Read"/"Describe" Command ---    */
  281. X/*                                                       */
  282. X/*       Program by Gary A. Allen, Jr.  21 February 1989 */
  283. X/*         (c) Copywrite 1989 by Gary A. Allen, Jr.      */
  284. X/*                                                       */
  285. X/*********************************************************/
  286. Xint k;
  287. X{
  288. Xswitch(k) {
  289. X
  290. X/* text for the map fragment in the manager's office */
  291. Xcase O_map_frag:
  292. Xprintf("______________________________________________________ \n");
  293. Xprintf("|..................................................... \n");
  294. Xprintf("|...._______________________.......................... \n");
  295. Xprintf("|...|  Current Operational  |........................ \n");
  296. Xprintf("|...|  Levels are:          |......D--W--W--W--W--W- \n");
  297. Xprintf("|...|     0, 49, 67, 82     |......|................ \n");
  298. Xprintf("|...| Level #67 is depicted |......S................ \n");
  299. Xprintf("|...._______________________.......|................ \n");
  300. Xprintf("|..................................S............... \n");
  301. Xprintf("|..................................|............... \n");
  302. Xprintf("|......................S--W--W--D--W.............. \n");
  303. Xprintf("|......................|........|................. \n");
  304. Xprintf("|......................S........E--E--E--E--E--E- \n");
  305. Xprintf("|......................|.......................... \n");
  306. Xprintf("|.......[dead end]--W--*--E--[dead end].......... \n");
  307. Xprintf("|......................|........................ \n");
  308. Xprintf("|......................S......................");
  309. Xprintf("       The rest of the map\n");
  310. Xprintf("|......................|.....................");
  311. Xprintf("        has turned into dust.\n");
  312. Xprintf("|.........[false dead end (partition)]......\n");
  313. Xprintf("|...........^..........|................. \n");
  314. Xprintf("|.{use an explosive}...S.............. \n");
  315. Xprintf("|......................|.... \n");
  316. Xprintf("|.............. \n");
  317. X    break;
  318. X
  319. X/* Can of Fourex Beer */
  320. Xcase O_can:
  321. Xprintf("You see an aluminum beer can with a hole in the bottom. The\n");
  322. Xprintf("can is coloured yellow-orange.  Written in red letters\n");
  323. Xprintf("across the can's front is the following:\n\n") ;
  324. Xprintf("                  \"CASTLEMAINE\"\n") ;
  325. Xprintf("                      XXXX\n") ;
  326. Xprintf("                   BITTER ALE\n\n") ;
  327. Xprintf("There's a picture of Fourex's Milton brewery in the middle.\n");
  328. X    break ;
  329. X
  330. X/* Atropine pills */
  331. Xcase O_pills:
  332. Xprintf("You're holding a packet which once contained ") ;
  333. Xprintf("30 pills but now\nholds only") ;
  334. Xprintf(" %d pills.  On the back of the packet is written:\n\n",
  335. X    pill_count) ;
  336. Xprintf("                       ATROPINE PILLS\n");
  337. Xprintf("The pills in this packet will protect the user against ") ;
  338. Xprintf("poisoning\nby organo-phosphorous ") ;
  339. Xprintf("compounds, i.e. VX nerve gas.\n") ;
  340. Xprintf("    Dosage:  Take ONE pill when poisoning symptons occur.\n");
  341. Xprintf("    Warning:  Atropine is itself a poison.  An overdose can\n");
  342. Xprintf("              be lethal!\n\n") ;
  343. X    break ;
  344. X
  345. X
  346. X/* description of Qaddafi's letter bomb */
  347. Xcase O_letter:
  348. Xprintf("___________________________________________________________\n");
  349. Xprintf("|                                               +-----+   |\n");
  350. Xprintf("| Col. M. Gaddafi                               |Libya|   |\n");
  351. Xprintf("| Azizya Barracks                Postage Due    |5 zl.|   |\n");
  352. Xprintf("| Tripoli, Libya                   $1.50        | -o- |   |\n");
  353. Xprintf("|                                               +-----+   |\n");
  354. Xprintf("|                 Sam Cohen                               |\n");
  355. Xprintf("|                 Level #67 Shift Boss                    |\n");
  356. Xprintf("|                 ACME Mine Ltd.                          |\n");
  357. Xprintf("|                 Birdsville, Queensland 4123             |\n");
  358. Xprintf("|  AIR MAIL                   Australia                   |\n");
  359. Xprintf("|                                                         |\n");
  360. Xprintf("___________________________________________________________\n");
  361. Xprintf("\n\nThe envelope must be opened before the ");
  362. Xprintf("letter can be read.\n\n") ;
  363. X    break;
  364. X
  365. X/* text for the paper found in the safe */
  366. Xcase O_paper:
  367. Xprintf("                             Congratulations!!! \n");
  368. Xprintf("You got the safe open!  Now you can start scoring points for ");
  369. Xprintf("treasure.\n") ;
  370. Xprintf("Credit is awarded **only** for treasure put into the safe. ");
  371. Xprintf("Beware of fell\nbush ") ;
  372. Xprintf("rangers who steal treasure (and sometimes kill adventurers).") ;
  373. Xprintf("\n\n                        ---  Concerning Gleeps ---\n");
  374. Xprintf("Gleeps are potent adjuncts which are credited separately from");
  375. Xprintf(" treasure.  Gleeps\n") ;
  376. Xprintf("will reproduce if left undisturbed in special locations ") ;
  377. Xprintf("underground. However\n") ;
  378. Xprintf("in most locations they will remain dormant. Credit ");
  379. Xprintf("for gleeps is awarded \n") ;
  380. Xprintf("only for those placed in a \"gleep tank\". While anyone ");
  381. Xprintf("can gather treasure, the\n") ;
  382. Xprintf("ability to cultivate and collect gleeps is the mark of a ");
  383. Xprintf("fair dinkum master.\n") ;
  384. Xprintf("                               Have Fun !!\n");
  385. X    break;
  386. X
  387. X/* description of the rifle */
  388. Xcase O_rifle:
  389. Xprintf("--- You are looking at a Colt M16 infantry rifle. --- \n");
  390. Xprintf("This fully automatic weapon is supplied bullets from a \n") ;
  391. Xprintf("detachable magazine which can hold up to 200 rounds. \n") ;
  392. Xprintf("The rifle has a selector knob that can place the weapon \n") ;
  393. Xprintf("into one of four possible firing modes: \n\n") ;
  394. Xprintf("     SAFE = Rifle can't fire, even if dropped \n") ;
  395. Xprintf("     I    = Single fire mode. Shoots one bullet at a time \n");
  396. Xprintf("     III  = Triple fire mode. Shoots three bullets rapidly \n");
  397. Xprintf("            every time the trigger is pulled. \n") ;
  398. Xprintf("     AUTO = Fully automatic, firing bullets at a rate of \n") ;
  399. Xprintf("            660 rounds/min. when trigger is pulled. \n\n") ;
  400. Xif (rifle_flag == F_safety)
  401. Xprintf("The rifle is currently set in the SAFE mode. \n") ;
  402. Xif (rifle_flag == F_single)
  403. Xprintf
  404. X  ("The rifle is currently set in the \"I\" or single fire mode.\n");
  405. Xif (rifle_flag == F_triple)
  406. Xprintf("The rifle is now set in the \"III\" or triple fire mode.\n");
  407. Xif (rifle_flag == F_auto)
  408. Xprintf("The rifle is currently set in the AUTO mode. \n") ;
  409. Xif (clip_flag == F_no_clip)
  410. Xprintf("The rifle does not have an ammunition clip attached to it.\n") ;
  411. Xif (clip_flag == F_normal_clip) {
  412. X    printf("The rifle has a standard ammunition clip attached ") ;
  413. X    printf("which contains %d rounds.\n",
  414. X                object[O_rifle][J_property]) ;
  415. X}
  416. Xif (clip_flag == F_org_clip) {
  417. X    printf("The rifle has an orange ammunition clip attached ") ;
  418. X    printf("which contains %d rounds.\n",
  419. X                object[O_rifle][J_property]) ;
  420. X}
  421. X    break ;
  422. X/* description of the safe */
  423. Xcase O_safe:
  424. Xprintf("You see a conventional combination dial type wall safe \n");
  425. Xprintf("fixed immovably into the wall.  The dial is black with \n");
  426. Xprintf("white numbers written onto it.  The numbers range from \n");
  427. Xprintf("one to one hundred. Attached to the upper right hand \n");
  428. Xprintf("corner of the safe is a manufacturer's label which reads:\n\n");
  429. Xprintf("                     _____________________________  \n") ;
  430. Xprintf("                    |     Kryptonite Safe Co.     | \n") ;
  431. Xprintf("                    |  Model Number:  C-3283      | \n") ; 
  432. Xprintf("                    |  Serial Number: 10149167182 | \n") ;
  433. Xprintf("                    |      Made in Australia      | \n") ;
  434. Xprintf("                     _____________________________  \n") ;
  435. X    break ;
  436. X/* description of the Semtex detector*/
  437. Xcase O_detector:
  438. Xprintf("You see an olive green box with a yellow button in its\n");
  439. Xprintf("center, a yellow light in its upper right hand corner and\n");
  440. Xprintf("Cryllic writing all over it.  Below the Cryllic letters\n") ;
  441. Xprintf("is a translation in English which reads:\n\n") ;
  442. Xprintf("              Mk 5.12 Semtex Explosive Detector\n") ;
  443. Xprintf("This device is used in detecting explosive weapons such as\n");
  444. Xprintf("antipersonal mines which utilize the high velocity plastic\n") ;
  445. Xprintf("explosive Semtex.  To operate this device merely press the\n") ;
  446. Xprintf("yellow button and an air sample will be taken. If trace\n");
  447. Xprintf("amounts of Semtex are detected then a warning beeper will\n");
  448. Xprintf("be activated.   If there is no detectable Semtex then a\n") ;
  449. Xprintf("yellow light will flash.\n\n") ;
  450. Xprintf("               Made in the Czeckoslovak Socialist Republic\n") ;
  451. X    break ;
  452. X/* description of the normal ammunition clip */
  453. Xcase O_clip:
  454. Xprintf("You see a conventional M16 ammunition clip.  It is olive "); 
  455. Xprintf(" green\n") ;
  456. Xprintf("in colour and about 30 centimeters long.\n"); 
  457. Xbreak ;
  458. X/* description of the orange clip */
  459. Xcase O_org_clip:
  460. Xprintf("You see an M16 ammunition clip which has been painted bright");
  461. Xprintf(" orange.\n") ;
  462. Xprintf("A strange blue glow seems to be radiating from the clip. ");
  463. Xprintf("There is\n") ;
  464. Xprintf("a placard attached to the side of the clip which reads:\n\n") ;
  465. Xprintf("     ____________________________________________________ \n");
  466. Xprintf("    |    Hypertoxic 0.223 Caliber Ammunition Magazine    |\n");
  467. Xprintf("    |                                                    |\n");
  468. Xprintf("    | The ammunition contained in this magazine is       |\n");
  469. Xprintf("    | manufactured from spent nuclear fuel rods composed |\n");
  470. Xprintf("    | of uranium and plutonium metal.  The bullets have  |\n");
  471. Xprintf("    | been hollowed out and filled with mercury metal.   |\n");
  472. Xprintf("    | The exterior of each bullet has been striated and  |\n");
  473. Xprintf("    | impregnated with VX nerve gas and anthrax bacillus.|\n");
  474. Xprintf("    | The use of this ammunition violates the Geneva     |\n");
  475. Xprintf("    | Convention on the Rules of War, the International  |\n");
  476. Xprintf("    | Moratorium on Biological Weapons, and the United   |\n");
  477. Xprintf("    | Nations Charter.  Close proximity to this          |\n");
  478. Xprintf("    | ammunition can be harmful to your health.          |\n");
  479. Xprintf("    |                                                    |\n");
  480. Xprintf("    |    Developed under DOE Contract: LLNL 89-5632/Z    |\n");
  481. Xprintf("    |                  Patent Pending                    |\n");
  482. Xprintf("     ____________________________________________________ \n");
  483. X    break ;
  484. X}
  485. X} /* --- end of "rdtxt" subroutine --- */
  486. END_OF_FILE
  487. if test 23091 -ne `wc -c <'describe.c'`; then
  488.     echo shar: \"'describe.c'\" unpacked with wrong size!
  489. fi
  490. # end of 'describe.c'
  491. fi
  492. if test -f 'taker.c' -a "${1}" != "-c" ; then 
  493.   echo shar: Will not clobber existing file \"'taker.c'\"
  494. else
  495. echo shar: Extracting \"'taker.c'\" \(28165 characters\)
  496. sed "s/^X//" >'taker.c' <<'END_OF_FILE'
  497. X#define TAKER
  498. X#include "dink_sym.h"
  499. X#include "dink_glb.h"
  500. Xvoid taker(n)
  501. X/*********************************************************/
  502. X/*                                                       */
  503. X/*           --- Object Taking Subroutine ---            */
  504. X/*                                                       */
  505. X/*      Program by Gary A. Allen, Jr.   20 May 1990      */
  506. X/*        (c) Copywrite 1990 by Gary A. Allen, Jr.       */
  507. X/*                                                       */
  508. X/*********************************************************/
  509. Xint n ;
  510. X{
  511. X#ifdef __TURBOC__
  512. Xvoid clip_in(int), clip_out(int), ender(int), eater(int) ;
  513. X#endif
  514. X
  515. Xregister int i, j ;
  516. Xint  sw_done, gleep_holder, ammo_flag ;
  517. X
  518. X/* Alias in the object for the single word "take" command */
  519. Xif (tag[V_VERB_ONLY]) {
  520. X    j = 0 ;
  521. X    /* See if there is only one object on the floor */
  522. X    for (i = 0; i <= objcnt; i++) if (n == object[i][J_loc]) {
  523. X        j++ ;
  524. X        tag[object[i][J_parse_id]] = TRUE ;
  525. X    }
  526. X
  527. X    if (room[n][M_gleep] != 0) {
  528. X        j++ ;
  529. X        tag[V_gleep] = TRUE ;
  530. X        if (room[n][M_gleep] > 1) tag[V_PLURAL] = TRUE ;
  531. X    }
  532. X
  533. X    /* Complain if there isn't a single object on the ground */
  534. X    if (j > 1) {
  535. X        printf ("What exactly do you want me to take? \n");
  536. X        return ;
  537. X    }
  538. X}
  539. X
  540. Xammo_flag = F_no_clip ;
  541. Xif (tag[V_clip]) ammo_flag = F_normal_clip ;
  542. Xif (tag[V_org_clip]) ammo_flag = F_org_clip ;
  543. X
  544. X/* deal with special case of "orange clip" implied by its being alone */
  545. Xif (tag[V_clip]&&(object[O_clip][J_loc] != n)&&
  546. X   (object[O_org_clip][J_loc] == n)) {
  547. X    tag[V_org_clip] = TRUE ;
  548. X    tag[V_clip] = FALSE ;
  549. X    if (V_clip == sent[1]) sent[1] = V_org_clip ;
  550. X}
  551. X
  552. X/* deal with the verb "attach" */
  553. Xif (verb == V_attach) {
  554. X    if (tag[V_rifle]&&(ammo_flag != F_no_clip)) {
  555. X        clip_in(ammo_flag) ;
  556. X        return ;
  557. X    }
  558. X    if ((n != R_office_mang)&&(room[n][M_obj_cnt] <= 0)) {
  559. X        printf ("There is nothing here that I can attach!\n");
  560. X        return ;
  561. X    }
  562. X}
  563. X
  564. X/* Check to see if player already has the item */
  565. Xfor (i = 0; i <= objcnt; i++) { 
  566. X    if (object[i][J_parse_id] == sent[1]) {
  567. X        if (object[i][J_loc] == B_have) {
  568. Xprintf ("You already have a %s in your possession.\n",vocab[sent[1]-1]);
  569. X            return ;
  570. X        }
  571. X        else break ;
  572. X    }
  573. X}
  574. X
  575. Xsw_done = FALSE ;
  576. X
  577. Xif (tag[V_safe]) {
  578. X    if (n != R_office_mang) {
  579. X        printf("There is no safe here. \n") ;
  580. X        return ;
  581. X    }
  582. X    if (room[R_office_mang][M_rm_status] != S_open) {
  583. X        printf("I can't do it because the safe is closed. \n") ;
  584. X        return ;
  585. X    }
  586. X}
  587. X
  588. X/* Special case of "take pill" */
  589. Xif ((tag[V_pill])&&(object[O_pills][J_loc] == B_have)) {
  590. X    eater(n) ;
  591. X    return ;
  592. X}
  593. X
  594. X/* Reject "take" command when there is nothing to take */
  595. Xif ((n != R_office_mang)&&(verb != V_attach)&&(verb != V_remove)&&
  596. X    (room[n][M_obj_cnt] <= 0)&&(room[n][M_gleep] == 0)&&
  597. X    (!((n == R_gleep_tank)&&(gleep_score > 0)))&&
  598. X    (room[n][M_rm_type] != T_unmovable_obj)) {
  599. X    printf ("There is nothing here that you can take! \n");
  600. X    return ;
  601. X}
  602. X
  603. X/* player takes something from the gleep tank */
  604. Xif (tag[V_tank]) {
  605. X    if (n != R_gleep_tank) {
  606. Xprintf("I see no gleep tank to take anything from. \n") ;
  607. X        return ;
  608. X    }
  609. Xprintf("\nYou climb up onto the edge of the gleep tank and reach\n");
  610. Xprintf("into the dark blue fluid.  Suddenly the fluid begins a\n");
  611. Xprintf("furious boiling that instantly reduces your hand into\n") ;
  612. Xprintf("bleached white bones.  The shock and pain disturbs your\n");
  613. Xprintf("balance and you fall into the horrible stuff!!  There is\n");
  614. Xprintf("once again a furious boiling.  Eventually the fluid stills\n");
  615. Xprintf("and becomes clear again.  On the bottom of the tank can\n") ;
  616. Xprintf("be seen a white, clean, \"medical school quality\" human\n");
  617. Xprintf("skeleton.\n") ;
  618. X    ender(F_died) ;
  619. X}
  620. X/* gleep taking routine */
  621. Xif (tag[V_gleep]) {
  622. Xif (!tag[V_safe]) {
  623. X
  624. X    /* This block is for inaccessible or nonexistant gleeps */
  625. X    if ((room[n][M_gleep] == 0)&&(!((n == R_office_mang)&&
  626. X(room[R_office_mang][M_rm_status] == S_open)&&(gleep_safe != 0)))) {
  627. X
  628. X        if ((n != R_gleep_tank)||(gleep_score==0)) {
  629. Xprintf("There are no gleeps here to take!\n") ;
  630. X            return ;
  631. X        }
  632. X        else {
  633. Xprintf("There are no gleeps on the floor but I see ") ;
  634. X            if (gleep_score == 1) 
  635. X                printf("a gleep in the gleep tank.\n");
  636. X            else
  637. Xprintf("%d gleeps in the gleep tank.\n",gleep_score) ;
  638. X            return ;
  639. X        }
  640. X    }
  641. X
  642. X    /* This block is for accessible gleeps */
  643. X    if ((n == R_office_mang)&&
  644. X(room[R_office_mang][M_rm_status] == S_open)&&(gleep_safe != 0)) {
  645. X        gleep_holder = gleep_safe ;
  646. X    }
  647. X    else gleep_holder = 0 ;
  648. X
  649. X    if ((!tag[V_PLURAL])||
  650. X        (room[n][M_gleep]+gleep_holder == 1)) {
  651. X        printf("Gleep taken. \n") ; 
  652. X        ++gleep_count ;
  653. X        if (gleep_holder == 0) --room[n][M_gleep] ;
  654. X        else --gleep_holder ;
  655. X    }
  656. X    else {
  657. X        printf("Gleeps taken. \n") ; 
  658. X        gleep_count += room[n][M_gleep]+gleep_holder ;
  659. X        room[n][M_gleep] = 0 ;
  660. X        gleep_holder = 0 ;
  661. X    }
  662. X    gleep_safe = gleep_holder ;
  663. X    return ;
  664. X}
  665. Xelse {
  666. X    if ((n == R_office_mang)&&
  667. X(room[R_office_mang][M_rm_status] == S_open)&&(gleep_safe != 0)) { 
  668. X        if (tag[V_PLURAL]) {
  669. X            printf("Gleeps taken from safe. \n") ; 
  670. X            gleep_count += gleep_safe ;
  671. X            gleep_safe = 0 ;
  672. X        }
  673. X        else {
  674. X            printf("Gleep taken from safe. \n") ; 
  675. X            ++gleep_count ;
  676. X            --gleep_safe ;
  677. X        }
  678. X    }
  679. X    else printf("There are no gleeps in the safe!\n") ;
  680. X    return ;
  681. X}
  682. X} /* end of the gleep taking block */
  683. X
  684. X/* deal with the special case of the platypus picture */
  685. Xif ((n == R_office_mang) && tag[V_picture]) {
  686. Xprintf("The picture can not be removed.  It appears to be hinged ");
  687. Xprintf("to the wall. \n");
  688. X    return ;
  689. X}
  690. X
  691. X/* treat the verb "remove" in the context of "remove clip from rifle" */
  692. Xif (verb == V_remove) {
  693. X    if ((!tag[V_safe])&&(ammo_flag != F_no_clip)) {
  694. X        clip_out(n) ;
  695. X        return ;
  696. X    }
  697. X}
  698. X
  699. Xif (carry_count > 5) {
  700. Xprintf("I can't do it!\n") ;
  701. Xprintf("I'm holding so many things that I can't take anymore!\n") ;
  702. X    return ;
  703. X}
  704. X
  705. Xif (carry_weight >= 800) {
  706. Xprintf("I can't do it!\n") ;
  707. Xprintf("This junk I'm carrying is too heavy! I can't carry anymore!\n");
  708. X    return ;
  709. X}
  710. X
  711. X
  712. X/* find the object(s) in this room */
  713. Xfor (i = 0; i <= objcnt; i++) {
  714. X
  715. X    if ((carry_count > 5)||(carry_weight >= 800)) break ;
  716. X
  717. X    /* See if the object is in the safe and was requested */
  718. X    if ((n == R_office_mang)&&(object[i][J_loc] == B_in_safe)&&
  719. X        (tag[object[i][J_parse_id]]||tag[V_all])&&
  720. X    (room[R_office_mang][M_rm_status] == S_open)&&
  721. X    ((!tag[V_treasure])||(object[i][J_value] > 0))) {
  722. X        object[i][J_loc]= B_have; 
  723. X        carry_count++ ;
  724. X        carry_weight += object[i][J_weight] ; 
  725. X        sw_done = TRUE ;
  726. X    } 
  727. X    
  728. X    /* See if the object is in the room and was requested */
  729. X    if ((object[i][J_loc]==n)&&(tag[object[i][J_parse_id]]||
  730. X        tag[V_all])&&
  731. X        ((!tag[V_treasure])||(object[i][J_value] > 0))) {
  732. X        /* see if the object can be taken */
  733. X        if ((object[i][J_type] == Z_normal)||
  734. X            (object[i][J_type] == Z_alias)) {
  735. X            --room[n][M_obj_cnt] ;
  736. X            carry_count++ ;
  737. X            carry_weight += object[i][J_weight] ; 
  738. X            object[i][J_loc] = B_have; 
  739. X            sw_done = TRUE ;
  740. X        } 
  741. X
  742. X        /* see if this is a nonmovable, nonacting object */
  743. X        if ((object[i][J_type] == Z_unmovable) &&
  744. X            (object[i][J_loc]==n) && (!tag[V_all])) {
  745. X
  746. X            switch(object[i][J_parse_id]) {
  747. X            case V_bulldust:
  748. Xprintf("The bulldust is so fine that it wafts away with a touch.\n") ;
  749. X                return ;
  750. X
  751. X            /* Cockroach(es) */
  752. X            case V_cockroach:
  753. Xprintf("I will not touch the filthy things!\n") ;
  754. X                return ;
  755. X
  756. X            /* Kangaroo(s) */
  757. X            case V_kangaroo:
  758. Xprintf("You make a grab for the kangaroo but it leaps away!\n") ;
  759. X                return ;
  760. X
  761. X            case V_poster:
  762. Xprintf("I think this sort of poster is best left on the wall.\n") ;
  763. X                return ;
  764. X
  765. X            /* Spinifex(es) */
  766. X            case V_spinifex:
  767. Xprintf("The thorns on the spinifex are large and nasty.\n") ;
  768. Xprintf("I'll just leave them to roll about.\n") ;
  769. X                return ;
  770. X            } /* end of switch block */
  771. X        } /* end of nonmovable object block */ 
  772. X
  773. X        /* see if taking the object causes special action */
  774. X        if (object[i][J_type] == Z_transform) {
  775. X            switch(object[i][J_parse_id]) {
  776. X            /* ACME doormat */
  777. X            case V_mat:
  778. Xprintf("As you lift up the dirty old doormat, you find half \n") ;
  779. Xprintf("hidden in the dust....  a large brass key. \n") ;
  780. X                object[O_mat][J_type] = Z_normal ;
  781. X                carry_count++ ;
  782. X                carry_weight += object[O_mat][J_weight];
  783. X                object[O_mat][J_loc]= B_have;
  784. X                object[O_key][J_loc]=R_office_entr ;
  785. X                sw_done = TRUE ;
  786. X                return ;
  787. X
  788. X            /* Map of the ACME Mine */
  789. X            case V_map:
  790. Xprintf("As you picked up the old map from the floor, most of it");
  791. Xprintf(" crumbled into \ndust leaving only one small piece. \n") ;
  792. X                object[O_map][J_loc] = B_unmade ;
  793. X                object[O_map_frag][J_loc] = B_have ;
  794. X                carry_count++ ;
  795. X            carry_weight += object[O_map_frag][J_weight] ;
  796. X                --room[n][M_obj_cnt] ;
  797. X                sw_done = TRUE ;
  798. X                return ;
  799. X            }
  800. X        } /* end of the special action block */ 
  801. X    } 
  802. X} /* end of the object scan loop */
  803. X
  804. X/* take all gleeps if any */
  805. Xif (tag[V_all]&&(!tag[V_treasure])) {
  806. X    if (room[n][M_gleep] > 0) { 
  807. X        gleep_count += room[n][M_gleep] ;
  808. X        room[n][M_gleep] = 0 ;
  809. X        sw_done = TRUE ;
  810. X    }
  811. X    if ((gleep_safe != 0)&&(n == R_office_mang)&&
  812. X        (room[R_office_mang][M_rm_status] == S_open)) {
  813. X        gleep_count +=  gleep_safe ;
  814. X        gleep_safe = 0 ;
  815. X        sw_done = TRUE ;
  816. X    }
  817. X}
  818. X
  819. X/* Announce the "take" was successful */
  820. Xif (sw_done) {
  821. X    if (((carry_count > 5)||(carry_weight >= 800))&&(tag[V_all])) 
  822. X        printf("You've taken as much as you can.\n") ;
  823. X    else printf ("Done \n");
  824. X}
  825. X/* --or-- announce the "take" was unsuccessful */
  826. Xelse  {
  827. X    if (tag[V_all]) printf("I see nothing which I can take.\n") ;
  828. X    else { 
  829. X        if (tag[V_VERB_ONLY]) 
  830. X            printf("What exactly should I take?\n") ;
  831. X        else {
  832. X            printf ("I don't see a") ;
  833. X            if (tag[V_PLURAL]) printf("ny") ;
  834. X            printf (" %s around here. \n",vocab[sent[1]-1]);
  835. X        }
  836. X    }
  837. X}
  838. Xreturn ;
  839. X
  840. X} /* --- end of the "taker" subroutine --- */
  841. X
  842. Xvoid loader()
  843. X/*********************************************************/
  844. X/*                                                       */
  845. X/*           --- Rifle Loading Subroutine ---            */
  846. X/*                                                       */
  847. X/*      Program by Gary A. Allen, Jr.  29 April 1990     */
  848. X/*        (c) Copywrite 1990 by Gary A. Allen, Jr.       */
  849. X/*                                                       */
  850. X/*********************************************************/
  851. X{
  852. X
  853. X#ifdef __TURBOC__
  854. Xvoid clip_in(int) ;
  855. X#endif
  856. X
  857. Xint ammo_flag ;
  858. X
  859. X/* Reject single verb load command */
  860. Xif (tag[V_VERB_ONLY]) {
  861. Xprintf("What exactly do you want me to load?\n") ;
  862. X    return ;
  863. X}
  864. Xif (!tag[V_rifle]) {
  865. Xprintf("I don't know how I could load that.\n") ;
  866. X    return ;
  867. X}
  868. X
  869. X/* Deal with implied clip type command */
  870. Xif (!tag[V_clip]) {
  871. Xif ((object[O_clip][J_loc] != B_have)&&
  872. X    (object[O_org_clip][J_loc] == B_have)) ammo_flag = F_org_clip ;
  873. Xif ((object[O_clip][J_loc] == B_have)&&
  874. X     (object[O_org_clip][J_loc] != B_have)) ammo_flag = F_normal_clip ;
  875. X    /* the case were there is no clip is found in clip_in */
  876. X}
  877. X
  878. X/* Deal with specific "load [orange] clip" command */
  879. Xelse {
  880. X    if (tag[V_orange]) {
  881. X        if (object[O_org_clip][J_loc] == B_have) 
  882. X            ammo_flag = F_org_clip ;
  883. X        else {
  884. Xprintf("You don't possess the orange ammunition clip.\n") ;
  885. X            return ;
  886. X        }
  887. X    }
  888. X    else {
  889. X        if (object[O_clip][J_loc] == B_have)
  890. X            ammo_flag = F_normal_clip ;
  891. X
  892. X/* assume "load clip" with no normal clip implies orange clip */
  893. X        else {
  894. X            if (object[O_org_clip][J_loc] == B_have) 
  895. X                ammo_flag = F_org_clip ;
  896. X            else{
  897. Xprintf("You don't possess an ammunition clip to load.\n") ;
  898. X                return ;
  899. X            }
  900. X        }
  901. X    }
  902. X}
  903. X
  904. Xclip_in(ammo_flag) ;
  905. X} /* --- end of the "loader" subroutine --- */
  906. X
  907. Xvoid unloader(n)
  908. X/*********************************************************/
  909. X/*                                                       */
  910. X/*          --- Rifle Unloading Subroutine ---           */
  911. X/*                                                       */
  912. X/*      Program by Gary A. Allen, Jr.  29 April 1990     */
  913. X/*        (c) Copywrite 1990 by Gary A. Allen, Jr.       */
  914. X/*                                                       */
  915. X/*********************************************************/
  916. Xint n ;
  917. X{
  918. X#ifdef __TURBOC__
  919. Xvoid clip_out(int) ;
  920. X#endif
  921. X
  922. X/* Reject single verb load command */
  923. Xif (tag[V_VERB_ONLY]) {
  924. Xprintf("What exactly do you want me to unload?\n") ;
  925. X    return ;
  926. X}
  927. Xif (!tag[V_rifle]) {
  928. Xprintf("I don't know how I could unload that.\n") ;
  929. X    return ;
  930. X}
  931. Xclip_out(n) ;
  932. X} /* --- end of the "unloader" subroutine --- */
  933. X
  934. Xvoid dropper(n)
  935. X/*********************************************************/
  936. X/*                                                       */
  937. X/*          --- Object Dropping Subroutine ---           */
  938. X/*                                                       */
  939. X/*      Program by Gary A. Allen, Jr.  21 May 1990       */
  940. X/*        (c) Copywrite 1990 by Gary A. Allen, Jr.       */
  941. X/*                                                       */
  942. X/*********************************************************/
  943. Xint n ;
  944. X{
  945. X#ifdef __TURBOC__
  946. Xvoid clip_in(int), clip_out(int), boom(void) ;
  947. Xvoid objlooker(int), gleeper(int), unlocker(int) ;
  948. X#endif
  949. X
  950. Xregister int i, k ;
  951. Xint sw_possess, sw_done, ammo_flag, sw_object, i_10, i_fract, sw_shot ;
  952. X
  953. X/* respond to "verb only" command */
  954. Xif (tag[V_VERB_ONLY]) {
  955. X    printf ("You'll have to be more specific. \n");
  956. X    return ;
  957. X}
  958. X
  959. X/* deal with special case of "orange clip" implied by its being alone */
  960. Xif (tag[V_clip]&&(object[O_clip][J_loc] != B_have)&&
  961. X    (clip_flag != F_normal_clip)&&
  962. X   ((object[O_org_clip][J_loc] == B_have)||(clip_flag == F_org_clip))) {
  963. X    tag[V_org_clip] = TRUE ;
  964. X    tag[V_clip] = FALSE ;
  965. X    if (V_clip == sent[1]) sent[1] = V_org_clip ;
  966. X}
  967. X
  968. Xammo_flag = F_no_clip ;
  969. Xif (tag[V_clip])  ammo_flag = F_normal_clip ;
  970. Xif (tag[V_org_clip])  ammo_flag = F_org_clip ;
  971. X
  972. X/* deal with special cases of the verbs */
  973. Xswitch(verb) {
  974. Xcase V_put:
  975. X    /* special case of putting (destroying) an object in water */
  976. X    if (tag[V_tank]||tag[V_gleep]||tag[V_safe]||
  977. X        tag[V_river]||tag[V_billabong]||tag[V_stream]) break ;
  978. X
  979. X    /* special case of "put key in door(lock)" */
  980. X    if (tag[V_key] && tag[V_door]) {
  981. X        unlocker(n) ;
  982. X        return ;
  983. X    }
  984. X
  985. X    if (!tag[V_cap]) {
  986. X        if ((!tag[V_rifle])&&(ammo_flag != F_no_clip)) {
  987. X            printf("What am I to put the clip into? \n") ;
  988. X            return ;
  989. X        }
  990. X        if (tag[V_rifle]&&(ammo_flag != F_no_clip))  
  991. X                clip_in(ammo_flag) ;
  992. X        else 
  993. Xprintf("I don't understand what this is to be put into. \n") ;
  994. X        return ;
  995. X    }
  996. X
  997. Xcase V_insert:
  998. X    if (tag[V_safe]) break ;
  999. X    if (ammo_flag != F_no_clip) {
  1000. X        if (!tag[V_rifle]) {
  1001. Xprintf("What am I to insert the clip into? \n") ;
  1002. X        }
  1003. X        else {
  1004. X            clip_in(ammo_flag) ;
  1005. X        }
  1006. X        return ;
  1007. X    }
  1008. X    if (tag[V_cap]) {
  1009. X        if (!tag[V_dynamite]) {
  1010. Xprintf("I see no reason why I should put a blasting cap into that.\n") ;
  1011. X            return ;
  1012. X        }
  1013. X        else goto cap_in ;
  1014. X    }
  1015. Xprintf("I can think of some interesing places to insert this. \n") ;
  1016. Xprintf("However I shall not reduce myself to such vulgarity.\n");
  1017. X    return ;
  1018. X    
  1019. Xcase V_eject:
  1020. X/* Command "eject clip" ejects clip from rifle no matter what type*/
  1021. X    if ((ammo_flag == F_normal_clip)&&(clip_flag == F_org_clip)) 
  1022. X        ammo_flag = F_org_clip ; 
  1023. Xcase V_drop:
  1024. X    if (((ammo_flag == F_org_clip)&&(clip_flag == F_org_clip))|| 
  1025. X    ((ammo_flag == F_normal_clip)&&(clip_flag == F_normal_clip))) { 
  1026. X        clip_out(n) ;
  1027. X        return ;
  1028. X    }
  1029. X    break ;
  1030. X
  1031. X} /* end of switch */
  1032. X
  1033. X/* Deal with "drop" when user has no objects */
  1034. Xif (tag[V_all]&&(carry_count == 0)&&(gleep_count == 0)) {
  1035. X    printf("You dill!  You have nothing to drop!\n") ;
  1036. X    return ;
  1037. X}
  1038. X
  1039. X/* deal with "drop in safe ..." errors */
  1040. Xif (tag[V_safe]) {
  1041. X/* see if this is the managers office */
  1042. X    if (n != R_office_mang) {        
  1043. X        printf("There is no safe here! \n");
  1044. X        return ;
  1045. X    }
  1046. X/* See if the safe is open */
  1047. X    if (room[R_office_mang][M_rm_status] != S_open) {
  1048. X        printf ("I can't do it!  The safe is closed. \n");
  1049. X        return ;
  1050. X    }
  1051. X}
  1052. X/* gleep droping routine */
  1053. Xif (tag[V_gleep]||tag[V_tank]) {
  1054. X    /* drop gleeps in a normal way */
  1055. X    if (!tag[V_tank]) {
  1056. X        if (gleep_count == 0) { 
  1057. X            printf("You have no gleeps to drop! \n") ;
  1058. X            return ;
  1059. X        }
  1060. X        if ((!tag[V_PLURAL])||(gleep_count == 1)) {
  1061. X            if (tag[V_safe]) {
  1062. X                printf("Gleep put into safe.\n") ;
  1063. X                ++gleep_safe ;
  1064. X                --gleep_count ;
  1065. X            }
  1066. X            else {
  1067. X                printf("Gleep dropped. \n") ; 
  1068. X                --gleep_count ;
  1069. X                ++room[n][M_gleep] ;
  1070. X            }
  1071. X        }
  1072. X        else {
  1073. X            if (tag[V_safe]) {
  1074. X                printf("Gleeps put into safe.\n") ;
  1075. X                gleep_safe += gleep_count ;
  1076. X                gleep_count = 0 ;
  1077. X            }
  1078. X            else {
  1079. X                printf("Gleeps dropped. \n") ; 
  1080. X                room[n][M_gleep] += gleep_count ;
  1081. X                gleep_count = 0 ;
  1082. X            }
  1083. X        }
  1084. X        gleep_drop = TRUE ;
  1085. X        return ;
  1086. X    }
  1087. X    /* drop objects(including gleeps) into a gleep tank */
  1088. X    else {
  1089. X        if (n != R_gleep_tank) {
  1090. X            printf("I don't see a gleep tank here. \n") ;
  1091. X            return ;
  1092. X        }
  1093. X        if (tag[V_gleep]) {
  1094. X            if (gleep_count <= 0) {
  1095. Xprintf("You have no gleeps to put in the tank. \n") ; 
  1096. X                return ;
  1097. X            }
  1098. X            if ((!tag[V_PLURAL])||(gleep_count == 1)) {
  1099. Xprintf("Your gleep falls into the tank with a \"plonk\".\n") ;
  1100. X                ++gleep_score ;
  1101. X                --gleep_count ;
  1102. X            }
  1103. X            if (tag[V_PLURAL]&&(gleep_count > 1)) {
  1104. Xprintf("Your gleeps fall into the tank causing a splash.\n") ;
  1105. X                gleep_score += gleep_count ;
  1106. X                gleep_count = 0 ;
  1107. X            }
  1108. X        }
  1109. X        /* drop non-gleeps into the tank */
  1110. X
  1111. X        /* the "drop all" routine */
  1112. X        if (tag[V_all]) {
  1113. X            sw_possess = FALSE ;
  1114. X            for (i = 0; i <= objcnt; i++) {
  1115. X                if ((object[i][J_loc] == B_have)&&
  1116. X                    ((!tag[V_treasure])||
  1117. X                    (object[i][J_value] > 0))) {
  1118. X                    sw_possess = TRUE ;
  1119. X                    object[i][J_loc] = B_destroyed; 
  1120. X                    carry_count-- ;
  1121. X                carry_weight -= object[i][J_weight] ;
  1122. X                }
  1123. X            }
  1124. X            if (gleep_count == 0) {
  1125. X                if (sw_possess) {
  1126. Xprintf("You dump everything into the gleep tank. There is a furious\n");
  1127. Xprintf("bubbling as the corrosive fluid of the tank turns the\n");
  1128. Xprintf("objects into NOTHING.\n") ;
  1129. X                }
  1130. X                else 
  1131. Xprintf("You've got nothing to throw into the tank.\n") ;
  1132. X            }
  1133. X            else {
  1134. X                if (sw_possess) {
  1135. Xprintf("You fling everything into the gleep tank.  The gleep");
  1136. X                if (gleep_count > 1) {
  1137. Xprintf("s\nsplash into the tank and settle to the bottom of the\n") ;
  1138. X                }
  1139. X                else {
  1140. Xprintf("\nplonks into the tank and settles to the bottom of the\n") ;
  1141. X                }
  1142. Xprintf("tank.  However the other objects begin to dissolve the\n");
  1143. Xprintf("moment the tank's fluid touches them.  Time passes and\n");
  1144. Xprintf("the objects dissolve into NOTHING.\n") ;
  1145. X                }
  1146. X                /* you possess no non-gleeps */
  1147. X                else {
  1148. X                if (gleep_count == 1) 
  1149. Xprintf("Your gleep falls into the tank with a \"plonk\".\n") ;
  1150. X                else
  1151. Xprintf("Your gleeps fall into the tank causing a splash.\n") ;
  1152. X                }
  1153. X            gleep_score += gleep_count ;
  1154. X            gleep_count = 0 ;
  1155. X            return ;
  1156. X            }
  1157. X        } /* end of the "drop all" if block */
  1158. X        /* Individual non-gleeps are dropped into the tank */
  1159. X
  1160. X        /* see if your are holding the object(s) */
  1161. X        for (i=0; i <= objcnt; i++) {
  1162. X             if (tag[object[i][J_parse_id]]) {
  1163. X                if (object[i][J_loc]== B_have) {
  1164. Xprintf ("You fling the %s into the gleep tank.  As soon as it\n",
  1165. X    vocab[object[i][J_parse_id]-1]);
  1166. Xprintf ("touched the tank's fluid there was a furious effervescence\n");
  1167. Xprintf ("as it began to dissolve.  With the passage of time, the\n") ;
  1168. Xprintf ("fluid stills and there is NOTHING left.\n") ;
  1169. X                    carry_count-- ;
  1170. X                carry_weight -= object[i][J_weight] ;
  1171. X                    object[i][J_loc] = B_destroyed; 
  1172. X                    return ;
  1173. X                }
  1174. X                else {
  1175. Xprintf("You don't have a %s to toss into the gleep tank.\n",
  1176. X    vocab[object[i][J_parse_id]-1]);
  1177. X                    return ;
  1178. X                }
  1179. X            }
  1180. X        } /* object scan "for" loop */
  1181. X        return ;
  1182. X    }
  1183. X}
  1184. X
  1185. Xsw_done = FALSE ;
  1186. X
  1187. X/* the "drop all" routine */
  1188. Xif (tag[V_all]) {
  1189. X
  1190. X    /* Deal with throwing stuff into water */
  1191. X    if(tag[V_stream]) {
  1192. X        if (n == R_stream) {
  1193. Xprintf("You fling everything into the stream.\n");
  1194. X            goto destroy_all ;
  1195. X        }
  1196. X        else
  1197. Xprintf("I see no stream to toss stuff into.\n") ;
  1198. X        return ;
  1199. X    }
  1200. X    if(tag[V_billabong]) {
  1201. X        if ((n == R_stream)||(n == R_slime)||
  1202. X            (n == R_billabong)) { 
  1203. Xprintf("You fling everything into the billabong.\n");
  1204. X            goto destroy_all ;
  1205. X        }
  1206. X        else
  1207. Xprintf("I see no billabong to toss stuff into.\n") ;
  1208. X        return ;
  1209. X    }
  1210. X    if(tag[V_river]) {
  1211. X        if ((n == R_dike)||(n == R_river_edge)||
  1212. X            (n == R_river_exit)) {
  1213. Xprintf("You fling everything into the river.\n");
  1214. X            goto destroy_all ;
  1215. X        }
  1216. X        else
  1217. Xprintf("I see no river to toss stuff into.\n") ;
  1218. X        return ;
  1219. X    }
  1220. X
  1221. X    if (!tag[V_safe]) {
  1222. X        /* normal drop */
  1223. X        if (room[n][M_rm_type] != T_looping) {
  1224. X            /* normal room */
  1225. X            for (i = 0; i <= objcnt; i++) {
  1226. X                if ((object[i][J_loc] == B_have)&&
  1227. X                    ((!tag[V_treasure])||
  1228. X                    (object[i][J_value] > 0))) {
  1229. X
  1230. X                    sw_done = TRUE ;
  1231. X
  1232. X/* see if the blasting cap was hard dropped */
  1233. Xif ((i == O_cap)&&(verb != V_slow_drop)) {
  1234. Xcap_drop:
  1235. Xprintf("Bang!! The blasting cap you were carrying detonated when\n") ;
  1236. Xprintf("it hit the ground.  Fortunately no damage was caused.\n") ;  
  1237. X    object[O_cap][J_loc] = B_destroyed; 
  1238. X    carry_count-- ;
  1239. X    carry_weight -= object[O_cap][J_weight] ;
  1240. X    return ;
  1241. X}
  1242. X
  1243. X/* see if the dynamite with blasting cap was hard dropped */
  1244. Xif ((i == O_dynamite)&&(object[O_dynamite][J_type] == Z_alias)&&
  1245. X    (verb != V_slow_drop)) {
  1246. Xdynamite_drop:
  1247. X    boom () ;
  1248. Xprintf("Dropping a stick of dynamite with a blasting cap in it\n");
  1249. Xprintf("ranks high as one of the dumbest things a person can do.\n") ;
  1250. Xprintf("Needless to say you were blown to bits.\n") ;
  1251. X    ender(F_died) ;
  1252. X}
  1253. X                    ++room[n][M_obj_cnt] ;
  1254. X                    carry_count-- ;
  1255. X                carry_weight -= object[i][J_weight] ;
  1256. X                    object[i][J_loc] = n; 
  1257. X/* set valuable switch if valuable object dropped in Ned's area */
  1258. X                    if (object[i][J_value] > 0) {
  1259. X                    for (k = 22; k <= 41; k++) 
  1260. X                    if (k == n) sw_valuable = TRUE;
  1261. X                    for (k = 144; k <= 146; k++) 
  1262. X                     if (k == n) sw_valuable = TRUE;
  1263. X                    }
  1264. X                }
  1265. X            }
  1266. X            /* drop all gleeps */
  1267. X            if ((gleep_count > 0)&&
  1268. X                    (!tag[V_treasure])) {
  1269. X                room[n][M_gleep] += gleep_count ;
  1270. X                gleep_count = 0 ;
  1271. X                sw_done = TRUE ;
  1272. X                gleep_drop = TRUE ;
  1273. X            }
  1274. X
  1275. X            if (sw_done) {
  1276. X                printf ("Done\n");
  1277. X                objlooker(n) ;
  1278. X                gleeper(n) ; 
  1279. X            } 
  1280. X            else printf("Don't have it to drop.\n") ;
  1281. X            return ;
  1282. X        }
  1283. X        /* object destroyer room */
  1284. X        else {
  1285. X        /* Code assumes that user has something to drop */
  1286. Xprintf ("You dropped everything you had in a heap, which \n");
  1287. Xprintf ("promptly vaporized into a bright blue flash followed \n");
  1288. Xprintf ("by a low \"BOOM\". \n") ; 
  1289. Xprintf ("       --- You've blown it Bozo!! ---\n") ;
  1290. Xdestroy_all:
  1291. X            gleep_count = 0 ;
  1292. X            carry_count = 0 ;
  1293. X            carry_weight = 0 ;
  1294. X            for (i = 0; i <= objcnt; i++) {
  1295. X                if (object[i][J_loc] == B_have) 
  1296. X                    object[i][J_loc] = B_destroyed; 
  1297. X            }
  1298. X            return ;
  1299. X        }
  1300. X    }
  1301. X    /* "drop all into the safe" routine */
  1302. X    else {
  1303. X        for (i = 0; i <= objcnt; i++) {
  1304. X            if ((object[i][J_loc] == B_have) &&
  1305. X                ((!tag[V_treasure])||
  1306. X                (object[i][J_value] > 0))) {
  1307. X                object[i][J_loc] = B_in_safe ;    
  1308. X                carry_count-- ;
  1309. X                carry_weight -= object[i][J_weight] ;
  1310. X                sw_done = TRUE ;
  1311. X            }
  1312. X        }
  1313. X        if (!tag[V_treasure]) {
  1314. X            gleep_safe += gleep_count ;
  1315. X            gleep_count = 0 ;
  1316. X            sw_done = TRUE ;
  1317. X        }
  1318. X        if (sw_done) printf ("Done \n");
  1319. X        else printf("You don't have it to put in the safe!\n") ;
  1320. X        return ;
  1321. X    }
  1322. X}
  1323. X
  1324. X/* see if your are holding the object(s) */
  1325. Xfor (i=0; i <= objcnt; i++) {
  1326. X    sw_object = FALSE ;
  1327. X    if (tag[object[i][J_parse_id]]) {
  1328. X        sw_object = TRUE ;
  1329. X         if (object[i][J_loc] == B_have) {
  1330. X            /* Safe storage routine */
  1331. X            if (tag[V_safe]) {
  1332. X                object[i][J_loc] = B_in_safe ;    
  1333. Xprintf ("The %s is now inside the safe. \n", 
  1334. X    vocab[object[i][J_parse_id]-1]);
  1335. X                sw_done = TRUE ;
  1336. X                carry_count-- ;
  1337. X                carry_weight -= object[i][J_weight] ;
  1338. X                continue ;
  1339. X            }
  1340. X            /* Single 'drop' routine */
  1341. X            if (tag[V_river]||tag[V_billabong]||
  1342. X                tag[V_stream]) {
  1343. X        /* The object is to be dropped in water */
  1344. X                if(tag[V_stream]) {
  1345. X                    if (n == R_stream) {
  1346. Xprintf("You fling the %s into the stream.\n", 
  1347. X    vocab[object[i][J_parse_id]-1]);
  1348. X                    carry_count-- ;
  1349. X                carry_weight -= object[i][J_weight] ;
  1350. X                    object[i][J_loc] = B_destroyed; 
  1351. X                    return ;
  1352. X                    }
  1353. X                    else
  1354. Xprintf("I see no stream to toss it into.\n") ;
  1355. X                    return ;
  1356. X                }
  1357. X            if(tag[V_billabong]) {
  1358. X                if ((n == R_stream)||
  1359. X                (n == R_slime)||(n == R_billabong)) { 
  1360. Xprintf("You fling the %s into the billabong.\n",
  1361. X    vocab[object[i][J_parse_id]-1]);
  1362. X                    carry_count-- ;
  1363. X                carry_weight -= object[i][J_weight] ;
  1364. X                    object[i][J_loc] = B_destroyed; 
  1365. X                    return ;
  1366. X                }
  1367. X                else
  1368. Xprintf("I see no billabong to toss it into.\n") ;
  1369. X                return ;
  1370. X            }
  1371. X            if(tag[V_river]) {
  1372. X                if ((n == R_dike)||(n == R_river_edge)||
  1373. X                    (n == R_river_exit)) {
  1374. Xprintf("You fling the %s into the river.\n", 
  1375. X    vocab[object[i][J_parse_id]-1]);
  1376. X                    carry_count-- ;
  1377. X                carry_weight -= object[i][J_weight] ;
  1378. X                    object[i][J_loc] = B_destroyed; 
  1379. X                    return ;
  1380. X                }
  1381. X                else
  1382. Xprintf("I see no river to toss it into.\n") ;
  1383. X                return ;
  1384. X            }
  1385. X        }
  1386. X        /* Normal Drop */
  1387. X        else if (room[n][M_rm_type] != T_looping) {
  1388. X            if ((i == O_cap)&&(verb != V_slow_drop)) 
  1389. X                goto cap_drop ;
  1390. X            if ((i==O_dynamite)&&(verb != V_slow_drop)&&
  1391. X            (object[O_dynamite][J_type] == Z_alias)) 
  1392. X                goto dynamite_drop ;
  1393. X
  1394. X/* If the he rifle is dropped.  See if it kills the player */
  1395. Xif (i==O_rifle) {
  1396. X    sw_shot = FALSE ;
  1397. X    if ((clip_flag != F_no_clip) && 
  1398. X(object[O_rifle][J_property] > 0)) switch(rifle_flag) {
  1399. X    case F_safety:
  1400. X        break ;
  1401. X            
  1402. X    case F_single:
  1403. X        printf("\nBam!\n\n") ;
  1404. X        sw_shot = TRUE ;
  1405. X        break ;
  1406. X
  1407. X    case F_triple:
  1408. X        printf("\n") ;
  1409. X        if (object[O_rifle][J_property] >= 3) {
  1410. X            printf("Bam! Bam! Bam! \n\n") ;
  1411. X        }
  1412. X        else {
  1413. X        for (i = 1; i <= object[O_rifle][J_property]; i++) 
  1414. X            printf("Bam! ") ;
  1415. X        }
  1416. X        printf("\n") ;
  1417. X        sw_shot = TRUE ;
  1418. X        break ;
  1419. X
  1420. X    case F_auto:
  1421. X        printf("\n") ;
  1422. X        if (object[O_rifle][J_property] >= 30) {
  1423. X            for (i = 1; i <= 3; i++) 
  1424. Xprintf("Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! \n") ;
  1425. X        }
  1426. X        else {
  1427. X            i_10 = object[O_rifle][J_property]/10 ;
  1428. X        i_fract = object[O_rifle][J_property]-(i_10*10) ;
  1429. X            for (i = 1; i <= i_10; i++) 
  1430. Xprintf("Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! Bam! \n") ;
  1431. X            for (i = 1; i <= i_fract; i++) 
  1432. X                printf("Bam! ") ;
  1433. X        }
  1434. X        printf("\n") ;
  1435. X        sw_shot = TRUE ;
  1436. X        break ;
  1437. X    } /* end of the switch block */
  1438. X
  1439. X    if (sw_shot) {
  1440. Xprintf("Dropping a loaded and armed automatic rifle is a stupid way\n");
  1441. X        if ((object[O_rifle][J_property] == 1) || 
  1442. X            (rifle_flag == F_single)) {
  1443. Xprintf("to commit suicide.  Needless to say you were hit by the\n") ;
  1444. Xprintf("bullet after the rifle went off.\n") ;
  1445. X        }
  1446. X        else {
  1447. Xprintf("to commit suicide.  The bullets shot from the rifle fly\n") ;
  1448. Xprintf("around.  One of them bounces back and hits you!\n") ;
  1449. X        }
  1450. X        ender(F_died) ;
  1451. X    }
  1452. X} /* end of "drop rifle" block */
  1453. X
  1454. X            carry_count-- ;
  1455. X            carry_weight -= object[i][J_weight] ;
  1456. X            ++room[n][M_obj_cnt] ;
  1457. X            object[i][J_loc] = n; 
  1458. X            sw_done = TRUE ;
  1459. X/* set valuable switch if valuable object dropped in Ned's area */
  1460. X            if (object[i][J_value] > 0) {
  1461. X                for (k = 22; k <= 41; k++) 
  1462. X                    if (k == n) sw_valuable = TRUE ;
  1463. X                for (k = 144; k <= 146; k++) 
  1464. X                    if (k == n) sw_valuable = TRUE ;
  1465. X            }
  1466. X            continue ;
  1467. X        }
  1468. X        else {
  1469. Xprintf ("As the %s left your possession there was a bright \n",
  1470. X    vocab[object[i][J_parse_id]-1]);
  1471. Xprintf ("blue flash, followed by a low \"BOOM\" as it vaporized \n");
  1472. Xprintf ("into nonexistence. \n");
  1473. X            carry_count-- ;
  1474. X            carry_weight -= object[i][J_weight] ;
  1475. X            object[i][J_loc] = B_destroyed; 
  1476. X            return ;
  1477. X        }
  1478. X        }
  1479. X         if (object[i][J_loc] == B_unmade) continue ;
  1480. X    } /* end of the object requested block */
  1481. X    if ((!sw_done)&&sw_object) {
  1482. Xprintf("You do not possess a %s.\n", vocab[object[i][J_parse_id]-1]);
  1483. X        return ;
  1484. X    }
  1485. X} /* end of the object scan loop */
  1486. Xif (sw_done) {
  1487. X    printf ("Done \n");
  1488. X    objlooker(n) ;
  1489. X    gleeper(n) ; 
  1490. X} 
  1491. Xelse 
  1492. Xprintf("I don't understand what it is I'm supposed to drop.\n") ;
  1493. X
  1494. Xreturn ;
  1495. X
  1496. X/* cap insertion routine */
  1497. Xcap_in:
  1498. X/* see if your are holding the dynamite or the cap */
  1499. X    if ((object[O_cap][J_loc] != B_have)&&
  1500. X        (object[O_dynamite][J_loc] != B_have)) {
  1501. Xprintf("You bloody dill!  You have neither the dynamite or a ");
  1502. Xprintf("blasting cap.\n") ;
  1503. X        return ;
  1504. X    }
  1505. X    if (object[O_cap][J_loc] != B_have) {
  1506. Xprintf("You've got the dynamite but you need a blasing cap.\n") ;
  1507. X        return ;
  1508. X    }
  1509. X    if (object[O_dynamite][J_loc] != B_have) {
  1510. Xprintf("You've got the blasting cap but you need some dynamite.\n") ;
  1511. X        return ;
  1512. X    }
  1513. X/* transform the two objects into one */
  1514. Xprintf("With some trepidation, you slide the blasting cap into\n");
  1515. Xprintf("the dynamite.  What you are now holding is VERY dangerous.\n");
  1516. X    object[O_cap][J_loc] = B_unmade ; 
  1517. X    object[O_dynamite][J_type] = Z_alias ;
  1518. X    carry_weight -= object[O_cap][J_weight] ;
  1519. X    carry_count-- ;
  1520. X
  1521. X} /* --- end of the "dropper" subroutine --- */
  1522. END_OF_FILE
  1523. if test 28165 -ne `wc -c <'taker.c'`; then
  1524.     echo shar: \"'taker.c'\" unpacked with wrong size!
  1525. fi
  1526. # end of 'taker.c'
  1527. fi
  1528. echo shar: End of archive 3 \(of 6\).
  1529. cp /dev/null ark3isdone
  1530. MISSING=""
  1531. for I in 1 2 3 4 5 6 ; do
  1532.     if test ! -f ark${I}isdone ; then
  1533.     MISSING="${MISSING} ${I}"
  1534.     fi
  1535. done
  1536. if test "${MISSING}" = "" ; then
  1537.     echo You have unpacked all 6 archives.
  1538.     rm -f ark[1-9]isdone
  1539. else
  1540.     echo You still need to unpack the following archives:
  1541.     echo "        " ${MISSING}
  1542. fi
  1543. ##  End of shell archive.
  1544. exit 0
  1545.