From 78e16127e5673dba104619df36ff2c7d92343f35 Mon Sep 17 00:00:00 2001 From: joey Date: Sun, 18 Nov 2001 22:12:53 +0000 Subject: [PATCH] Initial revision git-svn-id: file:///srv/svn/joey/bsdgames-trunk@5170 a4a2c43b-8ac3-0310-8836-e0e880c912e2 --- battlestar/command1.c | 273 ++++++ battlestar/command2.c | 353 ++++++++ battlestar/command3.c | 321 +++++++ battlestar/command4.c | 421 +++++++++ battlestar/command5.c | 380 ++++++++ battlestar/command6.c | 274 ++++++ battlestar/command7.c | 267 ++++++ fortune/datfiles/farber | 1856 +++++++++++++++++++++++++++++++++++++++ 8 files changed, 4145 insertions(+) create mode 100644 battlestar/command1.c create mode 100644 battlestar/command2.c create mode 100644 battlestar/command3.c create mode 100644 battlestar/command4.c create mode 100644 battlestar/command5.c create mode 100644 battlestar/command6.c create mode 100644 battlestar/command7.c create mode 100644 fortune/datfiles/farber diff --git a/battlestar/command1.c b/battlestar/command1.c new file mode 100644 index 0000000..5ece500 --- /dev/null +++ b/battlestar/command1.c @@ -0,0 +1,273 @@ +/* $NetBSD: command1.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com1.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command1.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +int +moveplayer(thataway, token) + int thataway, token; +{ + wordnumber++; + if ((!notes[CANTMOVE] && !notes[LAUNCHED]) || + testbit(location[position].objects, LAND) || + (fuel > 0 && notes[LAUNCHED])) { + if (thataway) { + position = thataway; + newway(token); + ourtime++; + } else { + puts("You can't go this way."); + newway(token); + whichway(location[position]); + return (0); + } + } else { + if (notes[CANTMOVE] && !notes[LAUNCHED]) + puts("You aren't able to move; you better drop something."); + else + puts("You are out of fuel; now you will rot in space forever!"); + } + return (1); +} + +void +convert(tothis) /* Converts day to night and vice versa. */ + int tothis; /* Day objects are permanent. Night objects + * are added */ +{ /* at dusk, and subtracted at dawn. */ + const struct objs *p; + unsigned int i, j; + + if (tothis == TONIGHT) { + for (i = 1; i <= NUMOFROOMS; i++) + for (j = 0; j < NUMOFWORDS; j++) + nightfile[i].objects[j] = dayfile[i].objects[j]; + for (p = nightobjs; p->room != 0; p++) + setbit(nightfile[p->room].objects, p->obj); + location = nightfile; + } else { + for (i = 1; i <= NUMOFROOMS; i++) + for (j = 0; j < NUMOFWORDS; j++) + dayfile[i].objects[j] = nightfile[i].objects[j]; + for (p = nightobjs; p->room != 0; p++) + clearbit(dayfile[p->room].objects, p->obj); + location = dayfile; + } +} + +void +news() +{ + int n; + int hurt; + + if (ourtime > 30 && position < 32) { + puts("An explosion of shuddering magnitude splinters bulkheads and"); + puts("ruptures the battlestar's hull. You are sucked out into the"); + puts("frozen void of space and killed."); + die(); + } + if (ourtime > 20 && position < 32) + puts("Explosions rock the battlestar."); + if (ourtime > snooze) { + puts("You drop from exhaustion..."); + zzz(); + } + if (ourtime > snooze - 5) + puts("You're getting tired."); + if (ourtime > (rythmn + CYCLE)) { + if (location == nightfile) { + convert(TODAY); + if (OUTSIDE && ourtime - rythmn - CYCLE < 10) { + puts("Dew lit sunbeams stretch out from a watery sunrise and herald the dawn."); + puts("You awake from a misty dream-world into stark reality."); + puts("It is day."); + } + } else { + convert(TONIGHT); + clearbit(location[POOLS].objects, BATHGOD); + if (OUTSIDE && ourtime - rythmn - CYCLE < 10) { + puts("The dying sun sinks into the ocean, leaving a blood-stained sunset."); + puts("The sky slowly fades from orange to violet to black. A few stars"); + puts("flicker on, and it is night."); + puts("The world seems completely different at night."); + } + } + rythmn = ourtime - ourtime % CYCLE; + } + if (!wiz && !tempwiz) + if ((testbit(inven, TALISMAN) || testbit(wear, TALISMAN)) && (testbit(inven, MEDALION) || testbit(wear, MEDALION)) && (testbit(inven, AMULET) || testbit(wear, AMULET))) { + tempwiz = 1; + puts("The three amulets glow and reenforce each other in power.\nYou are now a wizard."); + } + if (testbit(location[position].objects, ELF)) { + printf("%s\n", objdes[ELF]); + fight(ELF, rnd(30)); + } + if (testbit(location[position].objects, DARK)) { + printf("%s\n", objdes[DARK]); + fight(DARK, 100); + } + if (testbit(location[position].objects, WOODSMAN)) { + printf("%s\n", objdes[WOODSMAN]); + fight(WOODSMAN, 50); + } + switch (position) { + + case 267: + case 257: /* entering a cave */ + case 274: + case 246: + notes[CANTSEE] = 1; + break; + case 160: + case 216: /* leaving a cave */ + case 230: + case 231: + case 232: + notes[CANTSEE] = 0; + break; + } + if (testbit(location[position].objects, GIRL)) + meetgirl = 1; + if (meetgirl && CYCLE * 1.5 - ourtime < 10) { + setbit(location[GARDEN].objects, GIRLTALK); + setbit(location[GARDEN].objects, LAMPON); + setbit(location[GARDEN].objects, ROPE); + } + if (position == DOCK && (beenthere[position] || ourtime > CYCLE)) { + clearbit(location[DOCK].objects, GIRL); + clearbit(location[DOCK].objects, MAN); + } + if (meetgirl && ourtime - CYCLE * 1.5 > 10) { + clearbit(location[GARDEN].objects, GIRLTALK); + clearbit(location[GARDEN].objects, LAMPON); + clearbit(location[GARDEN].objects, ROPE); + meetgirl = 0; + } + if (testbit(location[position].objects, CYLON)) { + puts("Oh my God, you're being shot at by an alien spacecraft!"); + printf("The targeting computer says we have %d seconds to attack!\n", + ourclock); + fflush(stdout); + sleep(1); + if (!visual()) { + hurt = rnd(NUMOFINJURIES); + injuries[hurt] = 1; + puts("Laser blasts sear the cockpit, and the alien veers off in a victory roll."); + puts("The viper shudders under a terrible explosion."); + printf("I'm afraid you have suffered %s.\n", ouch[hurt]); + } else + clearbit(location[position].objects, CYLON); + } + if (injuries[SKULL] && injuries[INCISE] && injuries[NECK]) { + puts("I'm afraid you have suffered fatal injuries."); + die(); + } + for (n = 0; n < NUMOFINJURIES; n++) + if (injuries[n] == 1) { + injuries[n] = 2; + if (WEIGHT > 5) + WEIGHT -= 5; + else + WEIGHT = 0; + } + if (injuries[ARM] == 2) { + if (CUMBER > 5) + CUMBER -= 5; + else + CUMBER = 0; + injuries[ARM]++; + } + if (injuries[RIBS] == 2) { + if (CUMBER > 2) + CUMBER -= 2; + else + CUMBER = 0; + injuries[RIBS]++; + } + if (injuries[SPINE] == 2) { + WEIGHT = 0; + injuries[SPINE]++; + } + if (carrying > WEIGHT || encumber > CUMBER) + notes[CANTMOVE] = 1; + else + notes[CANTMOVE] = 0; +} + +void +crash() +{ + int hurt1, hurt2; + + fuel--; + if (!location[position].flyhere || + (testbit(location[position].objects, LAND) && fuel <= 0)) { + if (!location[position].flyhere) + puts("You're flying too low. We're going to crash!"); + else { + puts("You're out of fuel. We'll have to crash land!"); + if (!location[position].down) { + puts("Your viper strikes the ground and explodes into fiery fragments."); + puts("Thick black smoke billows up from the wreckage."); + die(); + } + position = location[position].down; + } + notes[LAUNCHED] = 0; + setbit(location[position].objects, CRASH); + ourtime += rnd(CYCLE / 4); + puts("The viper explodes into the ground and you lose consciousness..."); + zzz(); + hurt1 = rnd(NUMOFINJURIES - 2) + 2; + hurt2 = rnd(NUMOFINJURIES - 2) + 2; + injuries[hurt1] = 1; + injuries[hurt2] = 1; + injuries[0] = 1;/* abrasions */ + injuries[1] = 1;/* lacerations */ + printf("I'm afraid you have suffered %s and %s.\n", + ouch[hurt1], ouch[hurt2]); + } +} diff --git a/battlestar/command2.c b/battlestar/command2.c new file mode 100644 index 0000000..aac5b0e --- /dev/null +++ b/battlestar/command2.c @@ -0,0 +1,353 @@ +/* $NetBSD: command2.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com2.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command2.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +int +wearit() +{ /* synonyms = {sheathe, sheath} */ + int firstnumber, value; + + firstnumber = wordnumber; + wordnumber++; + while (wordnumber <= wordcount && (wordtype[wordnumber] == OBJECT || + wordtype[wordnumber] == NOUNS) && wordvalue[wordnumber] != DOOR) { + value = wordvalue[wordnumber]; + if (value >= 0 && objsht[value] == NULL) + break; + switch (value) { + + case -1: + puts("Wear what?"); + return (firstnumber); + + default: + printf("You can't wear %s%s!\n", + A_OR_AN_OR_BLANK(value), objsht[value]); + return (firstnumber); + + case KNIFE: + /* case SHIRT: */ + case ROBE: + case LEVIS: /* wearable things */ + case SWORD: + case MAIL: + case HELM: + case SHOES: + case PAJAMAS: + case COMPASS: + case LASER: + case AMULET: + case TALISMAN: + case MEDALION: + case ROPE: + case RING: + case BRACELET: + case GRENADE: + + if (testbit(inven, value)) { + clearbit(inven, value); + setbit(wear, value); + carrying -= objwt[value]; + encumber -= objcumber[value]; + ourtime++; + printf("You are now wearing %s%s.\n", + A_OR_AN_OR_THE(value), objsht[value]); + } else + if (testbit(wear, value)) + printf("You are already wearing the %s.\n", + objsht[value]); + else + printf("You aren't holding the %s.\n", + objsht[value]); + if (wordnumber < wordcount - 1 && + wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (firstnumber); + } /* end switch */ + } /* end while */ + puts("Don't be ridiculous."); + return (firstnumber); +} + +int +put() +{ /* synonyms = {buckle, strap, tie} */ + if (wordvalue[wordnumber + 1] == ON) { + wordvalue[++wordnumber] = PUTON; + wordtype[wordnumber] = VERB; + return (cypher()); + } + if (wordvalue[wordnumber + 1] == DOWN) { + wordvalue[++wordnumber] = DROP; + wordtype[wordnumber] = VERB; + return (cypher()); + } + puts("I don't understand what you want to put."); + return (-1); + +} + +int +draw() +{ /* synonyms = {pull, carry} */ + return (take(wear)); +} + +int +use() +{ + wordnumber++; + if (wordvalue[wordnumber] == AMULET && testbit(inven, AMULET) && + position != FINAL) { + puts("The amulet begins to glow."); + if (testbit(inven, MEDALION)) { + puts("The medallion comes to life too."); + if (position == 114) { + location[position].down = 160; + whichway(location[position]); + puts("The waves subside and it is possible to descend to the sea cave now."); + ourtime++; + return (-1); + } + } + puts("A light mist falls over your eyes and the sound of purling water trickles in"); + puts("your ears. When the mist lifts you are standing beside a cool stream."); + if (position == 229) + position = 224; + else + position = 229; + ourtime++; + notes[CANTSEE] = 0; + return (0); + } else if (position == FINAL) + puts("The amulet won't work in here."); + else if (wordvalue[wordnumber] == COMPASS && testbit(inven, COMPASS)) + printf("Your compass points %s.\n", truedirec(NORTH, '-')); + else if (wordvalue[wordnumber] == COMPASS) + puts("You aren't holding the compass."); + else if (wordvalue[wordnumber] == AMULET) + puts("You aren't holding the amulet."); + else + puts("There is no apparent use."); + return (-1); +} + +void +murder() +{ + int n; + + for (n = 0; !((n == SWORD || n == KNIFE || n == TWO_HANDED || n == MACE || n == CLEAVER || n == BROAD || n == CHAIN || n == SHOVEL || n == HALBERD) && testbit(inven, n)) && n < NUMOFOBJECTS; n++); + if (n == NUMOFOBJECTS) { + if (testbit(inven, LASER)) { + printf("Your laser should do the trick.\n"); + wordnumber++; + switch(wordvalue[wordnumber]) { + case NORMGOD: + case TIMER: + case NATIVE: + case MAN: + wordvalue[--wordnumber] = SHOOT; + cypher(); + break; + case -1: + puts("Kill what?"); + break; + default: + if (wordtype[wordnumber] != OBJECT || + wordvalue[wordnumber] == EVERYTHING) + puts("You can't kill that!"); + else + printf("You can't kill %s%s!\n", + A_OR_AN_OR_BLANK(wordvalue[wordnumber]), + objsht[wordvalue[wordnumber]]); + break; + } + } else + puts("You don't have suitable weapons to kill."); + } else { + printf("Your %s should do the trick.\n", objsht[n]); + wordnumber++; + switch (wordvalue[wordnumber]) { + + case NORMGOD: + if (testbit(location[position].objects, BATHGOD)) { + puts("The goddess's head slices off. Her corpse floats in the water."); + clearbit(location[position].objects, BATHGOD); + setbit(location[position].objects, DEADGOD); + power += 5; + notes[JINXED]++; + } else + if (testbit(location[position].objects, NORMGOD)) { + puts("The goddess pleads but you strike her mercilessly. Her broken body lies in a\npool of blood."); + clearbit(location[position].objects, NORMGOD); + setbit(location[position].objects, DEADGOD); + power += 5; + notes[JINXED]++; + if (wintime) + live(); + } else + puts("I don't see her anywhere."); + break; + case TIMER: + if (testbit(location[position].objects, TIMER)) { + puts("The old man offers no resistance."); + clearbit(location[position].objects, TIMER); + setbit(location[position].objects, DEADTIME); + power++; + notes[JINXED]++; + } else + puts("Who?"); + break; + case NATIVE: + if (testbit(location[position].objects, NATIVE)) { + puts("The girl screams as you cut her body to shreds. She is dead."); + clearbit(location[position].objects, NATIVE); + setbit(location[position].objects, DEADNATIVE); + power += 5; + notes[JINXED]++; + } else + puts("What girl?"); + break; + case MAN: + if (testbit(location[position].objects, MAN)) { + puts("You strike him to the ground, and he coughs up blood."); + puts("Your fantasy is over."); + die(); + } + case -1: + puts("Kill what?"); + break; + + default: + if (wordtype[wordnumber] != OBJECT || + wordvalue[wordnumber] == EVERYTHING) + puts("You can't kill that!"); + else + printf("You can't kill the %s!\n", + objsht[wordvalue[wordnumber]]); + } + } +} + +void +ravage() +{ + while (wordtype[++wordnumber] != NOUNS && wordnumber <= wordcount) + continue; + if (wordtype[wordnumber] == NOUNS && (testbit(location[position].objects, wordvalue[wordnumber]) + || (wordvalue[wordnumber] == NORMGOD && testbit(location[position].objects, BATHGOD)))) { + ourtime++; + switch (wordvalue[wordnumber]) { + case NORMGOD: + puts("You attack the goddess, and she screams as you beat her. She falls down"); + if (testbit(location[position].objects, BATHGOD)) + puts("crying and tries to cover her nakedness."); + else + puts("crying and tries to hold her torn and bloodied dress around her."); + power += 5; + pleasure += 8; + ego -= 10; + wordnumber--; + godready = -30000; + murder(); + win = -30000; + break; + case NATIVE: + puts("The girl tries to run, but you catch her and throw her down. Her face is"); + puts("bleeding, and she screams as you tear off her clothes."); + power += 3; + pleasure += 5; + ego -= 10; + wordnumber--; + murder(); + if (rnd(100) < 50) { + puts("Her screams have attracted attention. I think we are surrounded."); + setbit(location[ahead].objects, WOODSMAN); + setbit(location[ahead].objects, DEADWOOD); + setbit(location[ahead].objects, MALLET); + setbit(location[back].objects, WOODSMAN); + setbit(location[back].objects, DEADWOOD); + setbit(location[back].objects, MALLET); + setbit(location[left].objects, WOODSMAN); + setbit(location[left].objects, DEADWOOD); + setbit(location[left].objects, MALLET); + setbit(location[right].objects, WOODSMAN); + setbit(location[right].objects, DEADWOOD); + setbit(location[right].objects, MALLET); + } + break; + default: + puts("You are perverted."); + } + } else + puts("Who?"); +} + +int +follow() +{ + if (followfight == ourtime) { + puts("The Dark Lord leaps away and runs down secret tunnels and corridors."); + puts("You chase him through the darkness and splash in pools of water."); + puts("You have cornered him. His laser sword extends as he steps forward."); + position = FINAL; + fight(DARK, 75); + setbit(location[position].objects, TALISMAN); + setbit(location[position].objects, AMULET); + return (0); + } else + if (followgod == ourtime) { + puts("The goddess leads you down a steamy tunnel and into a high, wide chamber."); + puts("She sits down on a throne."); + position = 268; + setbit(location[position].objects, NORMGOD); + notes[CANTSEE] = 1; + return (0); + } else + puts("There is no one to follow."); + return (-1); +} diff --git a/battlestar/command3.c b/battlestar/command3.c new file mode 100644 index 0000000..f8a0110 --- /dev/null +++ b/battlestar/command3.c @@ -0,0 +1,321 @@ +/* $NetBSD: command3.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com3.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command3.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +void +dig() +{ + if (testbit(inven, SHOVEL)) { + puts("OK"); + ourtime++; + switch (position) { + case 144: /* copse near beach */ + if (!notes[DUG]) { + setbit(location[position].objects, DEADWOOD); + setbit(location[position].objects, COMPASS); + setbit(location[position].objects, KNIFE); + setbit(location[position].objects, MACE); + notes[DUG] = 1; + } + break; + + default: + puts("Nothing happens."); + } + } else + puts("You don't have a shovel."); +} + +int +jump() +{ + int n; + + switch (position) { + default: + puts("Nothing happens."); + return (-1); + + case 242: + position = 133; + break; + case 214: + case 215: + case 162: + case 159: + position = 145; + break; + case 232: + position = FINAL; + break; + case 3: + position = 1; + break; + case 172: + position = 201; + } + puts("Ahhhhhhh..."); + injuries[12] = injuries[8] = injuries[7] = injuries[6] = 1; + for (n = 0; n < NUMOFOBJECTS; n++) + if (testbit(inven, n)) { + clearbit(inven, n); + setbit(location[position].objects, n); + } + carrying = 0; + encumber = 0; + return (0); +} + +void +bury() +{ + int value; + + if (testbit(inven, SHOVEL)) { + while (wordtype[++wordnumber] != OBJECT && wordtype[wordnumber] != NOUNS && wordnumber < wordcount) + continue; + value = wordvalue[wordnumber]; + if (wordtype[wordnumber] == NOUNS && (testbit(location[position].objects, value) || value == BODY)) + switch (value) { + case BODY: + wordtype[wordnumber] = OBJECT; + if (testbit(inven, MAID) || testbit(location[position].objects, MAID)) + value = MAID; + if (testbit(inven, DEADWOOD) || testbit(location[position].objects, DEADWOOD)) + value = DEADWOOD; + if (testbit(inven, DEADGOD) || testbit(location[position].objects, DEADGOD)) + value = DEADGOD; + if (testbit(inven, DEADTIME) || testbit(location[position].objects, DEADTIME)) + value = DEADTIME; + if (testbit(inven, DEADNATIVE) || testbit(location[position].objects, DEADNATIVE)) + value = DEADNATIVE; + break; + + case NATIVE: + case NORMGOD: + puts("She screams as you wrestle her into the hole."); + case TIMER: + power += 7; + ego -= 10; + case AMULET: + case MEDALION: + case TALISMAN: + wordtype[wordnumber] = OBJECT; + break; + + default: + puts("Wha..?"); + } + if (wordtype[wordnumber] == OBJECT && position > 88 && (testbit(inven, value) || testbit(location[position].objects, value))) { + puts("Buried."); + if (testbit(inven, value)) { + clearbit(inven, value); + carrying -= objwt[value]; + encumber -= objcumber[value]; + } + clearbit(location[position].objects, value); + switch (value) { + case MAID: + case DEADWOOD: + case DEADNATIVE: + case DEADTIME: + case DEADGOD: + ego += 2; + printf("The %s should rest easier now.\n", objsht[value]); + } + } else + puts("It doesn't seem to work."); + } else + puts("You aren't holding a shovel."); +} + +void +drink() +{ + int n; + + if (testbit(inven, POTION)) { + puts("The cool liquid runs down your throat but turns to fire and you choke."); + puts("The heat reaches your limbs and tingles your spirit. You feel like falling"); + puts("asleep."); + clearbit(inven, POTION); + WEIGHT = MAXWEIGHT; + CUMBER = MAXCUMBER; + for (n = 0; n < NUMOFINJURIES; n++) + injuries[n] = 0; + ourtime++; + zzz(); + } else + puts("I'm not thirsty."); +} + +int +shoot() +{ + int firstnumber, value; + + firstnumber = wordnumber; + if (!testbit(inven, LASER)) + puts("You aren't holding a blaster."); + else { + wordnumber++; + while (wordnumber <= wordcount && wordtype[wordnumber] == OBJECT) { + value = wordvalue[wordnumber]; + printf("%s:\n", objsht[value]); + if (testbit(location[position].objects, value)) { + clearbit(location[position].objects, value); + ourtime++; + printf("The %s explode%s\n", objsht[value], + (is_plural_object(value) ? "." : "s.")); + if (value == BOMB) + die(); + } else + printf("I don't see any %s around here.\n", objsht[value]); + if (wordnumber < wordcount - 1 && wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (firstnumber); + } + /* special cases with their own return()'s */ + + if (wordnumber <= wordcount && wordtype[wordnumber] == NOUNS) { + ourtime++; + switch (wordvalue[wordnumber]) { + + case DOOR: + switch (position) { + case 189: + case 231: + puts("The door is unhinged."); + location[189].north = 231; + location[231].south = 189; + whichway(location[position]); + break; + case 30: + puts("The wooden door splinters."); + location[30].west = 25; + whichway(location[position]); + break; + case 31: + puts("The laser blast has no effect on the door."); + break; + case 20: + puts("The blast hits the door and it explodes into flame. The magnesium burns"); + puts("so rapidly that we have no chance to escape."); + die(); + default: + puts("Nothing happens."); + } + break; + + case NORMGOD: + if (testbit(location[position].objects, BATHGOD)) { + puts("The goddess is hit in the chest and splashes back against the rocks."); + puts("Dark blood oozes from the charred blast hole. Her naked body floats in the"); + puts("pools and then off downstream."); + clearbit(location[position].objects, BATHGOD); + setbit(location[180].objects, DEADGOD); + power += 5; + ego -= 10; + notes[JINXED]++; + } else + if (testbit(location[position].objects, NORMGOD)) { + puts("The blast catches the goddess in the stomach, knocking her to the ground."); + puts("She writhes in the dirt as the agony of death taunts her."); + puts("She has stopped moving."); + clearbit(location[position].objects, NORMGOD); + setbit(location[position].objects, DEADGOD); + power += 5; + ego -= 10; + notes[JINXED]++; + if (wintime) + live(); + break; + } else + puts("I don't see any goddess around here."); + break; + + case TIMER: + if (testbit(location[position].objects, TIMER)) { + puts("The old man slumps over the bar."); + power++; + ego -= 2; + notes[JINXED]++; + clearbit(location[position].objects, TIMER); + setbit(location[position].objects, DEADTIME); + } else + puts("What old-timer?"); + break; + case MAN: + if (testbit(location[position].objects, MAN)) { + puts("The man falls to the ground with blood pouring all over his white suit."); + puts("Your fantasy is over."); + die(); + } else + puts("What man?"); + break; + case NATIVE: + if (testbit(location[position].objects, NATIVE)) { + puts("The girl is blown backwards several feet and lies in a pool of blood."); + clearbit(location[position].objects, NATIVE); + setbit(location[position].objects, DEADNATIVE); + power += 5; + ego -= 2; + notes[JINXED]++; + } else + puts("There is no girl here."); + break; + case -1: + puts("Shoot what?"); + break; + + default: + printf("You can't shoot the %s.\n", objsht[wordvalue[wordnumber]]); + } + } else + puts("You must be a looney."); + } + return (firstnumber); +} diff --git a/battlestar/command4.c b/battlestar/command4.c new file mode 100644 index 0000000..2ae5bd0 --- /dev/null +++ b/battlestar/command4.c @@ -0,0 +1,421 @@ +/* $NetBSD: command4.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com4.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command4.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +int +take(from) + unsigned int from[]; +{ + int firstnumber, heavy, bulky, value; + + firstnumber = wordnumber; + if (wordnumber < wordcount && wordvalue[wordnumber + 1] == OFF) { + wordnumber++; + wordvalue[wordnumber] = TAKEOFF; + wordtype[wordnumber] = VERB; + return (cypher()); + } else { + wordnumber++; + while (wordnumber <= wordcount && wordtype[wordnumber] == OBJECT) { + value = wordvalue[wordnumber]; + printf("%s:\n", objsht[value]); + heavy = (carrying + objwt[value]) <= WEIGHT; + bulky = (encumber + objcumber[value]) <= CUMBER; + if ((testbit(from, value) || wiz || tempwiz) && heavy && bulky && !testbit(inven, value)) { + setbit(inven, value); + carrying += objwt[value]; + encumber += objcumber[value]; + ourtime++; + if (testbit(from, value)) + printf("Taken.\n"); + else + printf("Zap! Taken from thin air.\n"); + clearbit(from, value); + if (value == MEDALION) + win--; + } else if (testbit(inven, value)) + printf("You're already holding %s%s.\n", + A_OR_AN_OR_BLANK(value), + objsht[value]); + else if (!testbit(from, value)) + printf("I don't see any %s around here.\n", objsht[value]); + else if (!heavy) + printf("The %s %stoo heavy.\n", objsht[value], + IS_OR_ARE(value)); + else + printf("The %s %stoo cumbersome to hold.\n", + objsht[value], IS_OR_ARE(value)); + if (wordnumber < wordcount - 1 && wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (firstnumber); + } + } + /* special cases with their own return()'s */ + + if (wordnumber <= wordcount && wordtype[wordnumber] == NOUNS) + switch (wordvalue[wordnumber]) { + + case SWORD: + if (testbit(from, SWORD)) { + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } + if (testbit(from, TWO_HANDED)) { + wordvalue[wordnumber] = TWO_HANDED; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } + wordvalue[wordnumber] = BROAD; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + + case BODY: + if (testbit(from, MAID)) { + wordvalue[wordnumber] = MAID; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } else if (testbit(from, DEADWOOD)) { + wordvalue[wordnumber] = DEADWOOD; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } else if (testbit(from, DEADNATIVE)) { + wordvalue[wordnumber] = DEADNATIVE; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } else { + if (testbit(from, DEADGOD)) { + wordvalue[wordnumber] = DEADGOD; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } else { + wordvalue[wordnumber] = DEADTIME; + wordtype[wordnumber--] = OBJECT; + return (take(from)); + } + } + break; + + case AMULET: + if (testbit(location[position].objects, AMULET)) { + puts("The amulet is warm to the touch, and its beauty catches your breath."); + puts("A mist falls over your eyes, but then it is gone. Sounds seem clearer"); + puts("and sharper but far away as if in a dream. The sound of purling water"); + puts("reaches you from afar. The mist falls again, and your heart leaps in horror."); + puts("The gold freezes your hands and fathomless darkness engulfs your soul."); + } + wordtype[wordnumber--] = OBJECT; + return (take(from)); + + case MEDALION: + if (testbit(location[position].objects, MEDALION)) { + puts("The medallion is warm, and it rekindles your spirit with the warmth of life."); + puts("Your amulet begins to glow as the medallion is brought near to it, and together\nthey radiate."); + } + wordtype[wordnumber--] = OBJECT; + return (take(from)); + + case TALISMAN: + if (testbit(location[position].objects, TALISMAN)) { + puts("The talisman is cold to the touch, and it sends a chill down your spine."); + } + wordtype[wordnumber--] = OBJECT; + return (take(from)); + + case NORMGOD: + if (testbit(location[position].objects, BATHGOD) && (testbit(wear, AMULET) || testbit(inven, AMULET))) { + puts("She offers a delicate hand, and you help her out of the sparkling springs."); + puts("Water droplets like liquid silver bedew her golden skin, but when they part"); + puts("from her, they fall as teardrops. She wraps a single cloth around her and"); + puts("ties it at the waist. Around her neck hangs a golden amulet."); + puts("She bids you to follow her, and walks away."); + pleasure++; + followgod = ourtime; + clearbit(location[position].objects, BATHGOD); + } else + if (!testbit(location[position].objects, BATHGOD)) + puts("You're in no position to take her."); + else + puts("She moves away from you."); + break; + + default: + puts("It doesn't seem to work."); + } + else + puts("You've got to be kidding."); + return (firstnumber); +} + +int +throw(name) + const char *name; +{ + unsigned int n; + int deposit = 0; + int first, value; + + first = wordnumber; + if (drop(name) != -1) { + switch (wordvalue[wordnumber]) { + + case AHEAD: + deposit = ahead; + break; + + case BACK: + deposit = back; + break; + + case LEFT: + deposit = left; + break; + + case RIGHT: + deposit = right; + break; + + case UP: + deposit = location[position].up * (location[position].access || position == FINAL); + break; + + case DOWN: + deposit = location[position].down; + break; + } + wordnumber = first + 1; + while (wordnumber <= wordcount) { + value = wordvalue[wordnumber]; + if (deposit && testbit(location[position].objects, value)) { + clearbit(location[position].objects, value); + if (value != GRENADE) + setbit(location[deposit].objects, value); + else { + puts("A thundering explosion nearby sends up a cloud of smoke and shrapnel."); + for (n = 0; n < NUMOFWORDS; n++) + location[deposit].objects[n] = 0; + setbit(location[deposit].objects, CHAR); + } + if (value == ROPE && position == FINAL) + location[position].access = 1; + switch (deposit) { + case 189: + case 231: + puts("The stone door is unhinged."); + location[189].north = 231; + location[231].south = 189; + break; + case 30: + puts("The wooden door is blown open."); + location[30].west = 25; + break; + case 31: + puts("The door is not damaged."); + } + } else + if (value == GRENADE && testbit(location[position].objects, value)) { + puts("You are blown into shreds when your grenade explodes."); + die(); + } + if (wordnumber < wordcount - 1 && wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (first); + } + return (first); + } + return (first); +} + +int +drop(name) + const char *name; +{ + + int firstnumber, value; + + firstnumber = wordnumber; + wordnumber++; + while (wordnumber <= wordcount && (wordtype[wordnumber] == OBJECT || wordtype[wordnumber] == NOUNS)) { + value = wordvalue[wordnumber]; + if (value == BODY) { /* special case */ + wordtype[wordnumber] = OBJECT; + if (testbit(inven, MAID) || testbit(location[position].objects, MAID)) + value = MAID; + else if (testbit(inven, DEADWOOD) || testbit(location[position].objects, DEADWOOD)) + value = DEADWOOD; + else if (testbit(inven, DEADGOD) || testbit(location[position].objects, DEADGOD)) + value = DEADGOD; + else if (testbit(inven, DEADTIME) || testbit(location[position].objects, DEADTIME)) + value = DEADTIME; + else if (testbit(inven, DEADNATIVE) || testbit(location[position].objects, DEADNATIVE)) + value = DEADNATIVE; + } + if (wordtype[wordnumber] == NOUNS && value == DOOR) { + if (*name == 'K') + puts("You hurt your foot."); + else + puts("You're not holding a door."); + } else if (objsht[value] == NULL) { + if (*name == 'K') + puts("That's not for kicking!"); + else + puts("You don't have that."); + } else { + printf("%s:\n", objsht[value]); + if (testbit(inven, value)) { + clearbit(inven, value); + carrying -= objwt[value]; + encumber -= objcumber[value]; + if (value == BOMB) { + puts("The bomb explodes. A blinding white light and immense concussion obliterate us."); + die(); + } + if (value != AMULET && value != MEDALION && value != TALISMAN) + setbit(location[position].objects, value); + else + tempwiz = 0; + ourtime++; + if (*name == 'K') + puts("Drop kicked."); + else + printf("%s.\n", name); + } else { + if (*name != 'K') { + printf("You aren't holding the %s.\n", objsht[value]); + if (testbit(location[position].objects, value)) { + if (*name == 'T') + puts("Kicked instead."); + else if (*name == 'G') + puts("Given anyway."); + } + } else if (testbit(location[position].objects, value)) + puts("Kicked."); + else if (testbit(wear, value)) + puts("Not while it's being worn."); + else + puts("Not found."); + } + } + if (wordnumber < wordcount - 1 && wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (firstnumber); + } + puts("Do what?"); + return (-1); +} + +int +takeoff() +{ + wordnumber = take(wear); + return (drop("Dropped")); +} + +int +puton() +{ + wordnumber = take(location[position].objects); + return (wearit()); +} + +int +eat() +{ + int firstnumber, value; + + firstnumber = wordnumber; + wordnumber++; + while (wordnumber <= wordcount) { + value = wordvalue[wordnumber]; + if (wordtype[wordnumber] != OBJECT || objsht[value] == NULL) + value = -2; + switch (value) { + + case -2: + puts("You can't eat that!"); + return (firstnumber); + + case -1: + puts("Eat what?"); + return (firstnumber); + + default: + printf("You can't eat %s%s!\n", + A_OR_AN_OR_BLANK(value), objsht[value]); + return (firstnumber); + + case PAPAYAS: + case PINEAPPLE: + case KIWI: + case COCONUTS: /* eatable things */ + case MANGO: + + printf("%s:\n", objsht[value]); + if (testbit(inven, value) && + ourtime > ate - CYCLE && + testbit(inven, KNIFE)) { + clearbit(inven, value); + carrying -= objwt[value]; + encumber -= objcumber[value]; + ate = max(ourtime, ate) + CYCLE / 3; + snooze += CYCLE / 10; + ourtime++; + puts("Eaten. You can explore a little longer now."); + } else if (!testbit(inven, value)) + printf("You aren't holding the %s.\n", objsht[value]); + else if (!testbit(inven, KNIFE)) + puts("You need a knife."); + else + puts("You're stuffed."); + if (wordnumber < wordcount - 1 && wordvalue[++wordnumber] == AND) + wordnumber++; + else + return (firstnumber); + } /* end switch */ + } /* end while */ + return (firstnumber); +} diff --git a/battlestar/command5.c b/battlestar/command5.c new file mode 100644 index 0000000..22aa3c4 --- /dev/null +++ b/battlestar/command5.c @@ -0,0 +1,380 @@ +/* $NetBSD: command5.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com5.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command5.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +void +kiss() +{ + while (wordtype[++wordnumber] != NOUNS && wordnumber <= wordcount) + continue; + /* The goddess must be "taken" first if bathing. */ + if (wordtype[wordnumber] == NOUNS && wordvalue[wordnumber] == NORMGOD + && testbit(location[position].objects, BATHGOD)) { + wordvalue[--wordnumber] = TAKE; + cypher(); + return; + } + if (wordtype[wordnumber] == NOUNS) { + if (testbit(location[position].objects, wordvalue[wordnumber])) { + pleasure++; + printf("Kissed.\n"); + switch (wordvalue[wordnumber]) { + case NORMGOD: + switch (godready++) { + case 0: + puts("She squirms and avoids your advances."); + break; + case 1: + puts("She is coming around; she didn't fight it as much."); + break; + case 2: + puts("She's beginning to like it."); + break; + default: + puts("She's gone limp."); + + } + break; + case NATIVE: + puts("Her lips are warm and her body robust. She pulls you down to the ground."); + break; + case TIMER: + puts("The old man blushes."); + break; + case MAN: + puts("The dwarf punches you in the kneecap."); + break; + default: + pleasure--; + } + } else + puts("I see nothing like that here."); + } else + puts("I'd prefer not to."); +} + +void +love() +{ + int n; + + while (wordtype[++wordnumber] != NOUNS && wordnumber <= wordcount) + continue; + if (wordtype[wordnumber] == NOUNS) { + if ((testbit(location[position].objects, BATHGOD) || + testbit(location[position].objects, NORMGOD)) && + wordvalue[wordnumber] == NORMGOD) { + if (loved) { + printf("Loved.\n"); + return; + } + if (godready >= 2) { + puts("She cuddles up to you, and her mouth starts to work:\n'That was my sister's amulet. The lovely goddess, Purl, was she. The Empire\ncaptured her just after the Darkness came. My other sister, Vert, was killed\nby the Dark Lord himself. He took her amulet and warped its power.\nYour quest was foretold by my father before he died, but to get the Dark Lord's\namulet you must use cunning and skill. I will leave you my amulet,"); + puts("which you may use as you wish. As for me, I am the last goddess of the\nwaters. My father was the Island King, and the rule is rightfully mine.'\n\nShe pulls the throne out into a large bed."); + power++; + pleasure += 15; + ego++; + if (card(injuries, NUMOFINJURIES)) { + puts("Her kisses revive you; your wounds are healed.\n"); + for (n = 0; n < NUMOFINJURIES; n++) + injuries[n] = 0; + WEIGHT = MAXWEIGHT; + CUMBER = MAXCUMBER; + } + printf("Goddess:\n"); + if (!loved) + setbit(location[position].objects, MEDALION); + loved = 1; + ourtime += 10; + printf("Loved.\n"); + zzz(); + return; + } else { + puts("You wish!"); + return; + } + } + if (testbit(location[position].objects, wordvalue[wordnumber])) { + if (wordvalue[wordnumber] == NATIVE) { + puts("The girl is easy prey. She peels off her sarong and indulges you."); + power++; + pleasure += 5; + printf("Girl:\n"); + ourtime += 10; + printf("Loved.\n"); + zzz(); + } + if (wordvalue[wordnumber] == MAN || + wordvalue[wordnumber] == BODY || + wordvalue[wordnumber] == ELF || + wordvalue[wordnumber] == TIMER) + puts("Kinky!"); + else + puts("It doesn't seem to work."); + } else + puts("Where's your lover?"); + } else + puts("It doesn't seem to work."); +} + +int +zzz() +{ + int oldtime; + int n; + + oldtime = ourtime; + if ((snooze - ourtime) < (0.75 * CYCLE)) { + ourtime += 0.75 * CYCLE - (snooze - ourtime); + printf(""); + for (n = 0; n < ourtime - oldtime; n++) + printf("."); + printf("\n"); + snooze += 3 * (ourtime - oldtime); + if (notes[LAUNCHED]) { + fuel -= (ourtime - oldtime); + if (location[position].down) { + position = location[position].down; + crash(); + } else + notes[LAUNCHED] = 0; + } + if (OUTSIDE && rnd(100) < 50) { + puts("You are awakened abruptly by the sound of someone nearby."); + switch (rnd(4)) { + case 0: + if (ucard(inven)) { + n = rnd(NUMOFOBJECTS); + while (!testbit(inven, n)) + n = rnd(NUMOFOBJECTS); + clearbit(inven, n); + if (n != AMULET && n != MEDALION && n != TALISMAN) + setbit(location[position].objects, n); + carrying -= objwt[n]; + encumber -= objcumber[n]; + } + puts("A fiendish little Elf is stealing your treasures!"); + fight(ELF, 10); + break; + case 1: + setbit(location[position].objects, DEADWOOD); + break; + case 2: + setbit(location[position].objects, HALBERD); + break; + default: + break; + } + } + } else + return (0); + return (1); +} + +void +chime() +{ + if ((ourtime / CYCLE + 1) % 2 && OUTSIDE) + switch ((ourtime % CYCLE) / (CYCLE / 7)) { + case 0: + puts("It is just after sunrise."); + break; + case 1: + puts("It is early morning."); + break; + case 2: + puts("It is late morning."); + break; + case 3: + puts("It is near noon."); + break; + case 4: + puts("It is early afternoon."); + break; + case 5: + puts("It is late afternoon."); + break; + case 6: + puts("It is near sunset."); + break; + } + else if (OUTSIDE) + switch ((ourtime % CYCLE) / (CYCLE / 7)) { + case 0: + puts("It is just after sunset."); + break; + case 1: + puts("It is early evening."); + break; + case 2: + puts("The evening is getting old."); + break; + case 3: + puts("It is near midnight."); + break; + case 4: + puts("These are the wee hours of the morning."); + break; + case 5: + puts("The night is waning."); + break; + case 6: + puts("It is almost morning."); + break; + } + else + puts("I can't tell the time in here."); +} + +int +give() +{ + int obj = -1, result = -1, person = 0, firstnumber, last1, last2; + + last1 = last2 = 0; + firstnumber = wordnumber; + while (wordtype[++wordnumber] != OBJECT && wordvalue[wordnumber] != AMULET && wordvalue[wordnumber] != MEDALION && wordvalue[wordnumber] != TALISMAN && wordnumber <= wordcount) + continue; + if (wordnumber <= wordcount) { + obj = wordvalue[wordnumber]; + if (obj == EVERYTHING) + wordtype[wordnumber] = -1; + last1 = wordnumber; + } + wordnumber = firstnumber; + while ((wordtype[++wordnumber] != NOUNS || wordvalue[wordnumber] == obj) && wordnumber <= wordcount); + if (wordtype[wordnumber] == NOUNS) { + person = wordvalue[wordnumber]; + last2 = wordnumber; + } + /* Setting wordnumber to last1 - 1 looks wrong if last1 is 0, e.g., + * plain `give'. However, detecting this case is liable to detect + * `give foo' as well, which would give a confusing error. We + * need to make sure the -1 value can cause no problems if it arises. + * If in the below we get to the drop("Given") then drop will look + * at word 0 for an object to give, and fail, which is OK; then + * result will be -1 and we get to the end, where wordnumber gets + * set to something more sensible. If we get to "I don't think + * that is possible" then again wordnumber is set to something + * sensible. The wordnumber we leave with still isn't right if + * you include words the game doesn't know in your command, but + * that's no worse than what other commands than give do in + * the same place. */ + wordnumber = last1 - 1; + if (person && testbit(location[position].objects, person)) { + if (person == NORMGOD && godready < 2 && !(obj == RING || obj == BRACELET)) + puts("The goddess won't look at you."); + else + result = drop("Given"); + } else { + puts("I don't think that is possible."); + wordnumber = max(last1, last2) + 1; + return (0); + } + if (result != -1 && (testbit(location[position].objects, obj) || obj == AMULET || obj == MEDALION || obj == TALISMAN)) { + clearbit(location[position].objects, obj); + ourtime++; + ego++; + switch (person) { + case NATIVE: + puts("She accepts it shyly."); + ego += 2; + break; + case NORMGOD: + if (obj == RING || obj == BRACELET) { + puts("She takes the charm and puts it on. A little kiss on the cheek is"); + puts("your reward."); + ego += 5; + godready += 3; + } + if (obj == AMULET || obj == MEDALION || obj == TALISMAN) { + win++; + ego += 5; + power -= 5; + if (win >= 3) { + puts("The powers of the earth are now legitimate. You have destroyed the Darkness"); + puts("and restored the goddess to her throne. The entire island celebrates with"); + puts("dancing and spring feasts. As a measure of her gratitude, the goddess weds you"); + puts("in the late summer and crowns you Prince Liverwort, Lord of Fungus."); + puts("\nBut, as the year wears on and autumn comes along, you become restless and"); + puts("yearn for adventure. The goddess, too, realizes that the marriage can't last."); + puts("She becomes bored and takes several more natives as husbands. One evening,"); + puts("after having been out drinking with the girls, she kicks the throne particularly"); + puts("hard and wakes you up. (If you want to win this game, you're going to have to\nshoot her!)"); + clearbit(location[position].objects, MEDALION); + wintime = ourtime; + } + } + break; + case TIMER: + if (obj == COINS) { + puts("He fingers the coins for a moment and then looks up agape. `Kind you are and"); + puts("I mean to repay you as best I can.' Grabbing a pencil and cocktail napkin...\n"); + printf("+-----------------------------------------------------------------------------+\n"); + printf("| xxxxxxxx\\ |\n"); + printf("| xxxxx\\ CLIFFS |\n"); + printf("| FOREST xxx\\ |\n"); + printf("| \\\\ x\\ OCEAN |\n"); + printf("| || x\\ |\n"); + printf("| || ROAD x\\ |\n"); + printf("| || x\\ |\n"); + printf("| SECRET || ......... |\n"); + printf("| - + - || ........ |\n"); + printf("| ENTRANCE || ... BEACH |\n"); + printf("| || ... E |\n"); + printf("| || ... | |\n"); + printf("| // ... N <-- + --- S |\n"); + printf("| PALM GROVE // ... | |\n"); + printf("| // ... W |\n"); + printf("+-----------------------------------------------------------------------------+\n"); + puts("\n`This map shows a secret entrance to the catacombs."); + puts("You will know when you arrive because I left an old pair of shoes there.'"); + } + break; + } + } + wordnumber = max(last1, last2) + 1; + return (firstnumber); +} diff --git a/battlestar/command6.c b/battlestar/command6.c new file mode 100644 index 0000000..ce9f853 --- /dev/null +++ b/battlestar/command6.c @@ -0,0 +1,274 @@ +/* $NetBSD: command6.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com6.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command6.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" +#include "pathnames.h" + +int +launch() +{ + if (testbit(location[position].objects, VIPER) && !notes[CANTLAUNCH]) { + if (fuel > 4) { + clearbit(location[position].objects, VIPER); + position = location[position].up; + notes[LAUNCHED] = 1; + ourtime++; + fuel -= 4; + puts("You climb into the viper and prepare for launch."); + puts("With a touch of your thumb the turbo engines ignite, thrusting you back into\nyour seat."); + return (1); + } else + puts("Not enough fuel to launch."); + } else + puts("Can't launch."); + return (0); +} + +int +land() +{ + if (notes[LAUNCHED] && testbit(location[position].objects, LAND) && + location[position].down) { + notes[LAUNCHED] = 0; + position = location[position].down; + setbit(location[position].objects, VIPER); + fuel -= 2; + ourtime++; + puts("You are down."); + return (1); + } else + puts("You can't land here."); + return (0); +} + +void +die() +{ /* endgame */ + printf("bye.\nYour rating was %s.\n", rate()); + post(' '); + exit(0); +} + +void +diesig(dummy) + int dummy __attribute__((__unused__)); +{ + die(); +} + +void +live() +{ + puts("\nYou win!"); + post('!'); + exit(0); +} + +static FILE *score_fp; + +void +open_score_file() +{ + score_fp = fopen(_PATH_SCORE, "a"); + if (score_fp == NULL && getenv("BATTLESTAR_QUIET") == NULL) + warn("open %s for append", _PATH_SCORE); + if (score_fp != NULL && fileno(score_fp) < 3) + exit(1); +} + +void +post(ch) + char ch; +{ + time_t tv; + char *date; + sigset_t sigset, osigset; + + sigemptyset(&sigset); + sigaddset(&sigset, SIGINT); + sigprocmask(SIG_BLOCK, &sigset, &osigset); + tv = time(NULL); + date = ctime(&tv); + date[24] = '\0'; + if (score_fp != NULL) { + fprintf(score_fp, "%s %8s %c%20s", date, username, ch, rate()); + if (wiz) + fprintf(score_fp, " wizard\n"); + else + if (tempwiz) + fprintf(score_fp, " WIZARD!\n"); + else + fprintf(score_fp, "\n"); + } + sigprocmask(SIG_SETMASK, &osigset, (sigset_t *) 0); +} + +const char * +rate() +{ + int score; + + score = max(max(pleasure, power), ego); + if (score == pleasure) { + if (score < 5) + return ("novice"); + else if (score < 20) + return ("junior voyeur"); + else if (score < 35) + return ("Don Juan"); + else + return ("Marquis De Sade"); + } else if (score == power) { + if (score < 5) + return ("serf"); + else if (score < 8) + return ("Samurai"); + else if (score < 13) + return ("Klingon"); + else if (score < 22) + return ("Darth Vader"); + else + return ("Sauron the Great"); + } else { + if (score < 5) + return ("Polyanna"); + else if (score < 10) + return ("philanthropist"); + else if (score < 20) + return ("Tattoo"); + else + return ("Mr. Roarke"); + } +} + +int +drive() +{ + if (testbit(location[position].objects, CAR)) { + puts("You hop in the car and turn the key. There is a perceptible grating noise,"); + puts("and an explosion knocks you unconscious..."); + clearbit(location[position].objects, CAR); + setbit(location[position].objects, CRASH); + injuries[5] = injuries[6] = injuries[7] = injuries[8] = 1; + ourtime += 15; + zzz(); + return (0); + } else + puts("There is nothing to drive here."); + return (-1); +} + +int +ride() +{ + if (testbit(location[position].objects, HORSE)) { + puts("You climb onto the stallion and kick it in the guts. The stupid steed launches"); + puts("forward through bush and fern. You are thrown and the horse gallops off."); + clearbit(location[position].objects, HORSE); + while (!(position = rnd(NUMOFROOMS + 1)) || !OUTSIDE || !beenthere[position] || location[position].flyhere) + continue; + setbit(location[position].objects, HORSE); + if (location[position].north) + position = location[position].north; + else if (location[position].south) + position = location[position].south; + else if (location[position].east) + position = location[position].east; + else + position = location[position].west; + return (0); + } else + puts("There is no horse here."); + return (-1); +} + +void +light() +{ /* synonyms = {strike, smoke} *//* for + * matches, cigars */ + if (testbit(inven, MATCHES) && matchcount) { + puts("Your match splutters to life."); + ourtime++; + matchlight = 1; + matchcount--; + if (position == 217) { + puts("The whole bungalow explodes with an intense blast."); + die(); + } + } else + puts("You're out of matches."); +} + +void +dooropen() +{ /* synonyms = {open, unlock} */ + wordnumber++; + if (wordnumber <= wordcount && wordtype[wordnumber] == NOUNS + && wordvalue[wordnumber] == DOOR) { + switch(position) { + case 189: + case 231: + if (location[189].north == 231) + puts("The door is already open."); + else + puts("The door does not budge."); + break; + case 30: + if (location[30].west == 25) + puts("The door is gone."); + else + puts("The door is locked tight."); + break; + case 31: + puts("That's one immovable door."); + break; + case 20: + puts("The door is already ajar."); + break; + default: + puts("What door?"); + } + } else + puts("That doesn't open."); +} diff --git a/battlestar/command7.c b/battlestar/command7.c new file mode 100644 index 0000000..633d41f --- /dev/null +++ b/battlestar/command7.c @@ -0,0 +1,267 @@ +/* $NetBSD: command7.c,v 1.1 2001/10/19 03:06:11 tv Exp $ */ + +/* + * Copyright (c) 1983, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#ifndef lint +#if 0 +static char sccsid[] = "@(#)com7.c 8.2 (Berkeley) 4/28/95"; +#else +__RCSID("$NetBSD: command7.c,v 1.1 2001/10/19 03:06:11 tv Exp $"); +#endif +#endif /* not lint */ + +#include "extern.h" + +int +fight(enemy, strength) + int enemy, strength; +{ + int lifeline = 0; + int hurt; + char auxbuf[LINELENGTH]; + char *next; + int i; + int exhaustion; + + exhaustion = 0; +fighton: + ourtime++; + snooze -= 5; + if (snooze > ourtime) + exhaustion = CYCLE / (snooze - ourtime); + else { + puts("You collapse exhausted, and he pulverizes your skull."); + die(); + } + if (snooze - ourtime < 20) + puts("You look tired! I hope you're able to fight."); + next = getcom(auxbuf, LINELENGTH, "-: ", 0); + for (i = 0; next && i < 10; i++) + next = getword(next, words[i], -1); + parse(); + switch (wordvalue[wordnumber]) { + + case KILL: + case SMITE: + if (testbit(inven, TWO_HANDED)) + hurt = rnd(70) - 2 * card(injuries, NUMOFINJURIES) - ucard(wear) - exhaustion; + else if (testbit(inven, SWORD) || testbit(inven, BROAD)) + hurt = rnd(50) % (WEIGHT - carrying) - card(injuries, NUMOFINJURIES) - encumber - exhaustion; + else if (testbit(inven, KNIFE) || testbit(inven, MALLET) || testbit(inven, CHAIN) || testbit(inven, MACE) || testbit(inven, HALBERD)) + hurt = rnd(15) - card(injuries, NUMOFINJURIES) - exhaustion; + else + hurt = rnd(7) - encumber; + if (hurt < 5) + switch (rnd(3)) { + + case 0: + puts("You swung wide and missed."); + break; + case 1: + puts("He checked your blow. CLASH! CLANG!"); + break; + case 2: + puts("His filthy tunic hangs by one less thread."); + break; + } + else if (hurt < 10) { + switch (rnd(3)) { + case 0: + puts("He's bleeding."); + break; + case 1: + puts("A trickle of blood runs down his face."); + break; + case 2: + puts("A huge purple bruise is forming on the side of his face."); + break; + } + lifeline++; + } else if (hurt < 20) { + switch (rnd(3)) { + case 0: + puts("He staggers back quavering."); + break; + case 1: + puts("He jumps back with his hand over the wound."); + break; + case 2: + puts("His shirt falls open with a swath across the chest."); + break; + } + lifeline += 5; + } else if (hurt < 30) { + switch (rnd(3)) { + case 0: + printf("A bloody gash opens up on his %s side.\n", (rnd(2) ? "left" : "right")); + break; + case 1: + puts("The steel bites home and scrapes along his ribs."); + break; + case 2: + puts("You pierce him, and his breath hisses through clenched teeth."); + break; + } + lifeline += 10; + } else if (hurt < 40) { + switch (rnd(3)) { + case 0: + puts("You smite him to the ground."); + if (strength - lifeline > 20) + puts("But in a flurry of steel he regains his feet!"); + break; + case 1: + puts("The force of your blow sends him to his knees."); + puts("His arm swings lifeless at his side."); + break; + case 2: + puts("Clutching his blood drenched shirt, he collapses stunned."); + break; + } + lifeline += 20; + } else { + switch (rnd(3)) { + case 0: + puts("His ribs crack under your powerful swing, flooding his lungs with blood."); + break; + case 1: + puts("You shatter his upheld arm in a spray of blood. The blade continues deep"); + puts("into his back, severing the spinal cord."); + lifeline += 25; + break; + case 2: + puts("With a mighty lunge the steel slides in, and gasping, he falls to the ground."); + lifeline += 25; + break; + } + lifeline += 30; + } + break; + + case BACK: + if (enemy == DARK && lifeline > strength * 0.33) { + puts("He throws you back against the rock and pummels your face."); + if (testbit(inven, AMULET) || testbit(wear, AMULET)) { + printf("Lifting the amulet from you, "); + if (testbit(inven, MEDALION) || testbit(wear, MEDALION)) { + puts("his power grows and the walls of\nthe earth tremble."); + puts("When he touches the medallion, your chest explodes and the foundations of the\nearth collapse."); + puts("The planet is consumed by darkness."); + die(); + } + if (testbit(inven, AMULET)) { + clearbit(inven, AMULET); + carrying -= objwt[AMULET]; + encumber -= objcumber[AMULET]; + } else + clearbit(wear, AMULET); + puts("he flees down the dark caverns."); + clearbit(location[position].objects, DARK); + injuries[SKULL] = 1; + followfight = ourtime; + return (0); + } else { + puts("I'm afraid you have been killed."); + die(); + } + } else { + puts("You escape stunned and disoriented from the fight."); + puts("A victorious bellow echoes from the battlescene."); + if (back && position != back) + moveplayer(back, BACK); + else if (ahead && position != ahead) + moveplayer(ahead, AHEAD); + else if (left && position != left) + moveplayer(left, LEFT); + else if (right && position != right) + moveplayer(right, RIGHT); + else + moveplayer(location[position].down, AHEAD); + return (0); + } + + case SHOOT: + if (testbit(inven, LASER)) { + if (strength - lifeline <= 50) { + printf("The %s took a direct hit!\n", objsht[enemy]); + lifeline += 50; + } else { + puts("With his bare hand he deflects the laser blast and whips the pistol from you!"); + clearbit(inven, LASER); + setbit(location[position].objects, LASER); + carrying -= objwt[LASER]; + encumber -= objcumber[LASER]; + } + } else + puts("Unfortunately, you don't have a blaster handy."); + break; + + case DROP: + case DRAW: + cypher(); + ourtime--; + break; + + default: + puts("You don't have a chance; he is too quick."); + break; + + } + if (lifeline >= strength) { + printf("You have killed the %s.\n", objsht[enemy]); + if (enemy == ELF || enemy == DARK) + puts("A watery black smoke consumes his body and then vanishes with a peal of thunder!"); + clearbit(location[position].objects, enemy); + power += 2; + notes[JINXED]++; + return (0); + } + puts("He attacks..."); + /* Some embellishments. */ + hurt = rnd(NUMOFINJURIES) - (testbit(inven, SHIELD) != 0) - (testbit(wear, MAIL) != 0) - (testbit(wear, HELM) != 0); + hurt += (testbit(wear, AMULET) != 0) + (testbit(wear, MEDALION) != 0) + (testbit(wear, TALISMAN) != 0); + hurt = hurt < 0 ? 0 : hurt; + hurt = hurt >= NUMOFINJURIES ? NUMOFINJURIES - 1 : hurt; + if (!injuries[hurt]) { + injuries[hurt] = 1; + printf("I'm afraid you have suffered %s.\n", ouch[hurt]); + } else + puts("You emerge unscathed."); + if (injuries[SKULL] && injuries[INCISE] && injuries[NECK]) { + puts("I'm afraid you have suffered fatal injuries."); + die(); + } + goto fighton; +} diff --git a/fortune/datfiles/farber b/fortune/datfiles/farber new file mode 100644 index 0000000..6edc88e --- /dev/null +++ b/fortune/datfiles/farber @@ -0,0 +1,1856 @@ +A buck in the hand is worth two on the books. +% +A carpenter's son doesn't have shoes. +% +A dog under any other coat is still a dog. +% +A hand in the bush is worth two anywhere else. +% +A lot of these arguments are fetious. +% +A lot of things are going to be bywashed. +% +A lot of water has gone over the bridge since then. +% +A problem swept under the table occasionally comes home to roost. +% +A rocky road is easier to travel than a stone wall. +% +A stop-gap measure is better than no gap at all. +% +A whole hog is better than no hole at all. +% +Abandon ship all you who enter here! +% +After that, we'll break our gums on the computer. +% +All the hills of beans in China don't matter. +% +All the lemmings are coming home to roost. +% +All the lemmings are going home to roost. +% +All you have to do is fill in the missing blanks. +% +An avalanche is nipping at their heels. +% +An enigma is only as good as its bottom line. +% +An ounce of prevention is better than pounding the table. +% +And I take the blunt of it! +% +Another day, a different dollar. +% +Any kneecap of yours is a friend of mine. +% +Any storm in a port. +% +Anybody who marries her would stand out like a sore thumb. +% +Anything he wants is a friend of mine. +% +Are there any problems we haven't beat out to death? +% +As long as somebody let the cat out of the bag, we might as well +spell it correctly. +% +At the end of every pot of gold, there's a rainbow. +% +Before they made him they broke the mold. +% +Beware a Trojan bearing a horse. +% +Boulder dash! +% +By a streak of coincidence, it really happened. +% +By the time we unlock the bandages, he will have gone down the drain. +% +Cheapness doesn't come free. +% +Clean up or fly right. +% +Clean up your own can of worms! +% +Come down off your charlie horse. +% +Conceptual things are in the eye of the beholder. +% +Deep water runs still. +% +Dig a hole and bury it. +% +Dig yourself a hole and bury it. +% +Do it now; don't dingle-dally over it. +% +Do not fumble with a woman's logic. +% +Does it joggle any bells? +% +Don't bite the hand that stabs you in the back. +% +Don't burn your bridges until you come to them. +% +Don't cash in your chips until the shill is down. +% +Don't cast a gander upon the water. +% +Don't cast any dispersions. +% +Don't cast doubts on troubled waters. +% +Don't count your chickens until the barn door is closed. +% +Don't criticize him for lack of inexperience. +% +Don't cut off the limb you've got your neck strung out on. +% +Don't do anything I wouldn't do standing up in a hammock. +% +Don't eat with your mouth full. +% +Don't get your eye out of joint. +% +Don't jump off the gun. +% +Don't jump off the handle. +% +Don't jump on a ship that's going down in flames. +% +Don't just stand there like a sitting duck. +% +Don't lead them down the garden path and cut them off at the knees. +% +Don't leave the nest that feeds you. +% +Don't let the camels get their feet in the door. +% +Don't look a gift horse in the face. +% +Don't look a mixed bag in the mouth. +% +Don't look at me in that tone of voice. +% +Don't look for a gift in the horse's mouth. +% +Don't make a molehill out of a can of beans. +% +Don't make a tempest out of a teapot. +% +Don't muddle the waters. +% +Don't pull a panic button. +% +Don't pull an enigma on me. +% +Don't put all you irons on the fire in one pot. +% +Don't rattle the boat. +% +Don't rock the boat that feeds you. +% +Don't roll up your nostrils at me. +% +Don't stick your oar in muddy waters. +% +Don't strike any bells while the fire is hot. +% +Don't talk to me with your clothes on. +% +Don't talk with your mouth open. +% +Don't throw the baby out with the dishwasher. +% +Don't throw the dog's blanket over the horse's nose. +% +Don't twiddle your knee-caps at me! +% +Don't upset the apple pie. +% +Dot your t's and cross your i's. +% +Drop the other foot, for Christ's sake! +% +Each of us sleazes by at our own pace. +% +Erase that indelibly from your memory. +% +Every cloud has a blue horizon. +% +Every rainbow has a silver lining. +% +Everything is going all bananas. +% +Everything is ipso facto. +% +Everything is mutually intertangled. +% +Everything's all ruffled over. +% +Fade out in a blaze of glory. +% +Feather your den with somebody else's nest. +% +Fellow alumni run thicker than water. +% +Fish or get off the pot! +% +Float off into several individual conferees. +% +For all intensive purposes, the act is over. +% +From here on up, it's down hill all the way. +% +Gander your eye at that! +% +Gee, it must have fallen into one of my cracks. +% +Get off the stick and do something. +% +Get the hot poop right off the vine. +% +Getting him to do anything is like pulling hen's teeth. +% +Give him a project to get his teeth wet on. +% +Give him a square shake. +% +Give him an inch and he'll screw you. +% +Give him enough rope and he will run away with it. +% +Go fly your little red wagon somewhere else. +% +Good grace is in the eye of the beholder. +% +Good riddance aforethought. +% +Half a loaf is better than two in the bush. +% +Half a worm is better than none. +% +Hands were made before feet. +% +Have it prepared under my signature. +% +Have more discretion in the face of valor. +% +Have the seeds we've sown fallen on deaf ears? +% +Have we been cast a strange eye at? +% +Have we gone too fast too far? +% +He has a dire need, actually it's half-dire, but he thinks +it's double-dire. +% +He may be the greatest piece of cheese that ever walked down +the plank. +% +He and his group are two different people. +% +He came in on my own volition. +% +He can't hack the other can of worms. +% +He choked on his own craw. +% +He deserves a well-rounded hand of applause. +% +He didn't even bat an eyebrow. +% +He didn't flinch an eyelid. +% +He disappeared from nowhere. +% +He doesn't have the brain to rub two nickels together. +% +He doesn't know which side his head is buttered on. +% +He drinks like a sieve. +% +He flipped his cork. +% +He gave me a blanket check. +% +He got taken right through the nose. +% +He got up on his highheels. +% +He grates me the wrong way. +% +He has a marvelous way of extruding you. +% +He has a very weak indigestion. +% +He has a wool of steel. +% +He has feet of molasses. +% +He has his ass on the wrong end of his head. +% +He has his crutches around her throat. +% +He has his foot in the pie. +% +He has his neck out on a limb. +% +He has his pot in too many pies. +% +He has the character of navel lint. +% +He has the courage of a second-story man. +% +He hit the nose right on the head. +% +He is as dishonest as the day is long. +% +He just sat there like a bump on a wart. +% +He keeps his ear to the vine. +% +He knows which side his pocketbook is buttered on. +% +He knows which side of his bread his goose is buttered on. +% +He needs to get blown out of his water. +% +He popped out of nowhere like a jack-in-the-bean-box. +% +He pulled himself up on top of his own bootstraps. +% +He rammed it down their ears. +% +He reads memos with a fine tooth comb. +% +He rules with an iron thumb. +% +He said it thumb in cheek. +% +He should be gracious for small favors. +% +He smokes like a fish. +% +He wants to get his nose wet in several areas. +% +He was hoisted by a skyhook on his own petard! +% +He was hoisted by his own canard. +% +He was hung by his own bootstraps. +% +He was left out on the lurch. +% +He was putrified with fright. +% +He wears his finger on his sleeve. +% +He would forget his head if it weren't screwed up. +% +Heads are rolling in the aisles. +% +He'll get his neck in hot water. +% +He'll grease any palm that will pat his ass. +% +He's tossing symbols around like a percussionist in a John +Philip Sousa band. +% +He's a bulldog in a china shop. +% +He's a child progeny. +% +He's a fart off the old block. +% +He's a lion in a den of Daniels. +% +He's a little clog in a big wheel. +% +He's a shirking violet. +% +He's a wolf in sheep's underware. +% +He's a young peeksqueek. +% +He's as crazy as a bloody loon! +% +He's as crazy as a fruitcake. +% +He's as happy as a pig at high tide. +% +He's as quick as an eyelash. +% +He's bailing him out of the woods. +% +He's been living off his laurels for years. +% +He's being pruned for the job. +% +He's being shifted from shuttle to cock. +% +He's biting the shaft and getting the short end of the problem. +% +He's breathing down my throat. +% +He's casting a red herring on the face of the water. +% +He's clam bait. +% +He's cornered on all sides. +% +He's faster than the naked eye. +% +He's fuming at the seams. +% +He's going to fall flat on his feet. +% +He's got a rat's nest by the tail. +% +He's got a tough axe to hoe. +% +He's got four sheets in the wind. +% +He's got his intentions crossed. +% +He's got so much zap he can barely twitch. +% +He's king bee. +% +He's letting ground grow under his feet. +% +He's like a wine glass in a storm. +% +He's like sheep in a bullpen. +% +He's lying through his britches. +% +He's not breathing a muscle. +% +He's off in a cloud of ``hearty heigh-ho Silver''. +% +He's on the back of the pecking order. +% +He's one of the world's greatest flamingo dancers. +% +He's paying through the neck. +% +He's procrastinating like a bandit. +% +He's reached the crescent of his success. +% +He's restoring order to chaos. +% +He's running around like a bull with his head cut off. +% +He's running around like a chicken with his ass cut off. +% +He's running around with his chicken cut off. +% +He's running from gamut to gamut. +% +He's running off at the seams. +% +He's salivating at the chops. +% +He's seething at the teeth. +% +He's sharp as a whip. +% +He's singing a little off-keel. +% +He's so far above me I can't reach his bootstraps. +% +He's so mad he is spitting wooden nickels. +% +He's somewhere down wind of the innuendo. +% +He's spending a lot of brunt on the task. +% +He's splitting up at the seams. +% +He's the best programmer east of the Mason-Dixon line. +% +He's the king of queens. +% +He's the last straw on the camel's back to be called. +% +He's too smart for his own bootstraps. +% +He's up a creek with his paddles leaking. +% +He's within eyeshot of shore. +% +His eyeballs perked up. +% +His feet have come home to roost. +% +His foot is in his mouth up to his ear. +% +His head's too big for his britches. +% +His position is not commiserate with his abilities. +% +History is just a repetition of the past. +% +Hold your cool! +% +How old is your 2-year old? +% +I speak only with olive branches dripping from the corners +of my mouth. +% +I accept it with both barrels. +% +I apologize on cringed knees. +% +I came within a hair's breathe of it. +% +I can do it with one eye tied behind me. +% +I can remember everything; I have a pornographic mind. +% +I can't hum a straight tune. +% +I case my ground very well before I jump into it. +% +I come to you on bended bootstrap. +% +I contributed to the charity of my cause. +% +I could count it on the fingers of one thumb. +% +I could tell you stories that would curdle your hair. +% +I did it sitting flat on my back. +% +I don't always play with a full house of cards. +% +I don't know which dagger to clothe it in. +% +I don't like the feel of this ball of wax. +% +I don't want to be the pie that upset the applecart. +% +I don't want to cast a pall on the water. +% +I don't want to start hurdling profanity. +% +I don't want to stick my hand in the mouth that's feeding me. +% +I don't want to throw a wrench in the ointment. +% +I enjoy his smiling continence. +% +I flew it by ear. +% +I got you by the nap of your neck. +% +I guess I'd better get my duff on the road. +% +I guess I'm putting all my birds in one pie. +% +I guess that muddled the waters. +% +I had her by the nap of the neck. +% +I had to make a split decision. +% +I had to scratch in the back recesses of my memory. +% +I had to throw in the white flag. +% +I have a green thumb up to my elbow. +% +I have a rot-gut feeling about that. +% +I have feedback on both sides of the coin. +% +I have my neck hung out on an open line. +% +I have no personal bones to grind about it. +% +I have people crawling out of my ears. +% +I have post-naval drip. +% +I have reasonably zero desire to do it. +% +I have the self-discipline of a mouse. +% +I have to get my guts up. +% +I have too many cooks in the pot already. +% +I haven't bitten off an easy nut. +% +I haven't gotten the knack down yet. +% +I hear the handwriting on the wall. +% +I heard it out of the corner of my eyes. +% +I just pulled those out of the seat of my pants. +% +I keep stubbing my shins. +% +I know what we have to do to get our feet off the ground. +% +I listen with a very critical eye. +% +I looked at it with some askance. +% +I march to a different kettle of fish. +% +I only hear half of what I believe. +% +I only hope your every wish is desired. +% +I only mentioned it to give you another side of the horse. +% +I only read it in snips and snabs. +% +I owe you a great gratitude of thanks. +% +I pulled my feet out from under my rug. +% +I put all my marbles in one basket. +% +I read the sign, but it went in one ear and out the other. +% +I resent the insinuendoes. +% +I rushed around like a chicken out of my head. +% +I said it beneath my breath. +% +I see several little worms raising their heads around the corner. +% +I think he's gone over the bend. +% +I think I've committed a fore paw. +% +I think that we are making an out-and-out molehill of this issue. +% +I think the real crux is the matter. +% +I thought I'd fall out of my gourd. +% +I want half a cake and eat it too. +% +I want to embark upon your qualms. +% +I want to get more fire into the iron. +% +I want to get to know them on a face-to-name basis. +% +I want to go into that at short length. +% +I want to see him get a good hands-on feel. +% +I was working my balls to the bone. +% +I wish somebody could drop the other foot. +% +I won't hang my laurels on it. +% +I won't kick a gift horse in the mouth. +% +I worked my toes to the bonenail. +% +I would imagine he chafes a bit. +% +I wouldn't give it to a wet dog. +% +I wouldn't marry her with a twenty-foot pole. +% +I wouldn't take him on a ten foot pole. +% +I wouldn't want to be sitting in his shoes. +% +I'd better get my horse on it's ass. +% +I'd better jack up my bootstraps and get going. +% +I'd have been bent out of shape like spades. +% +I'd kill a dog to bite that man. +% +I'd like to intersperse a comment. +% +I'd like to put another foot into the pot. +% +I'd like to strike while the inclination is hot. +% +I'd rather be tight than right. +% +If they do that, they'll be committing suicide for the rest of +their lives. +% +If they had to stand on their own two feet, they would have gone +down the drain a long time ago. +% +If we keep going this way, somebody is going to be left standing +at the church with his pants on. +% +If you don't want words put in your mouth, don't leave it +hanging open. +% +If anything, I bend over on the backwards side. +% +If Calvin Coolidge were alive today, he'd turn over in his grave. +% +If the onus fits, wear it. +% +If the shoe fits, put it in your mouth. +% +If the shoe is on the other foot, wear it. +% +If there's no fire, don't make waves. +% +If they do it there won't be a living orgasm left. +% +If you ask him he could wax very quickly on that subject. +% +If you listen in the right tone of voice, you'll hear what I mean. +% +If you see loose strings that have to be tied down that are not +nailed up, see me about it. +% +If you want something bad enough, you have to pay the price. +% +If you want to be heard, go directly to the horse's ear. +% +If you want to get your jollies off, watch this! +% +If you'd let me, I'd forget the shirt off my back. +% +If you're going to break a chicken, you have to scramble a few eggs. +% +I'll be ready just in case a windfall comes down the pike. +% +I'll be there in the next foreseeable future. +% +I'll be there with spades one. +% +I'll bet there's one guy out in the woodwork. +% +I'll descend on them to the bone. +% +I'll fight him hand and nail. +% +I'll hit him right between the teeth. +% +I'll procrastinate when I get around to it. +% +I'll reek the benefits. +% +I'll see it when I believe it. +% +I'll stay away from that like a 10-foot pole. +% +I'll take a few pegs out of his sails. +% +I'll take any warm body in a storm. +% +I'm a mere fragment of my imagination. +% +I'm all ravelled up. +% +I'm basking in his shadow. +% +I'm burning my bridges out from under me! +% +I'm casting the dye on the face of the water. +% +I'm collapsing around the seams. +% +I'm creaking at the seams. +% +I'm creaming off the top of my head. +% +I'm deathly curious. +% +I'm flapping at the gills. +% +I'm going off tangentially. +% +I'm going right out of my bonker. +% +I'm going right over the bend. +% +I'm going to cast my rocks to the wind. +% +I'm going to down-peddle that aspect. +% +I'm going to feel it out by the ear. +% +I'm going to litigate it to the eyeballs. +% +I'm going to put a little variety in your spice of life. +% +I'm going to put my horn in. +% +I'm going to read between your lines. +% +I'm going to resolve it by ear. +% +I'm going to scatter them like chaff before the wind. +% +I'm going to scream right out of my gourd. +% +I'm going to take my vendetta out on them. +% +I'm going to take my venom out on you. +% +I'm going to throw myself into the teeth of the gamut. +% +I'm ground up to a high pitch. +% +I'm having a hard time getting my handles around that one. +% +I'm in my reclining years. +% +I'm in transit on that point. +% +I'm listening with baited ears. +% +I'm looking at it with a jaundiced ear. +% +I'm not going to bail him out of his own juice. +% +I'm not going to beat a dead horse to death. +% +I'm not going to get side tracked onto a tangent. +% +I'm not sure it's my bag of tea. +% +I'm not sure we're all speaking from the same sheet of music. +% +I'm not trying to grind anybody's axes. +% +I'm out of my bloomin' loon. +% +I'm over the hilt. +% +I'm parked somewhere in the boondoggles. +% +I'm pulling something over on you. +% +I'm ready to go when the bell opens. +% +I'm running around like a one-armed paper bandit. +% +I'm signing my own death knell. +% +I'm sitting on the edge of my ice. +% +I'm smarting at the seams. +% +I'm soaked to the teeth. +% +I'm standing over your shoulder. +% +I'm sticking my neck out on a ledge. +% +I'm stone cold sane. +% +I'm talking up a dead alley. +% +I'm throwing those ideas to you off the top of my hat. +% +I'm too uptight for my own bootstraps. +% +I'm up a wrong alley. +% +I'm up against a blind wall. +% +I'm up to my earballs in garbage. +% +I'm walking on cloud nine. +% +I'm walking on thin water. +% +I'm weighted down with baited breath. +% +I'm willing to throw my two cents into the fire. +% +I'm working my blood up into a fervor. +% +I'm wound up like a cork. +% +I'm your frontface in this matter. +% +In one mouth and out the other. +% +In this period of time, its getting very short. +% +In this vein I will throw out another item for Pandora' box. +% +Indiscretion is the better part of valor. +% +Is he an Amazon! +% +Is there any place we can pull a chink out of the log jam? +% +It is better to have tried and failed than never to have failed +at all. +% +It cuts like a hot knife through solid rock. +% +It drove me to no wits end. +% +It fills a well-needed gap. +% +It floated right to the bottom. +% +It flows like water over the stream. +% +It gets grained into you. +% +It goes from one gamut to another. +% +It goes from tippy top to tippy bottom. +% +It goes in one era and out the other. +% +It goes out one ear and in the other. +% +It got left out in the lurch. +% +It has more punch to the unch. +% +It hit me to the core. +% +It hit the epitome of it. +% +It leaks like a fish. +% +It looks like it's going to go on ad infinitum for a while. +% +It looks real enough to be artificial. +% +It may seem incredulous, but it's true. +% +It might break the straw that holds the camel's back. +% +It might have been a figment of my illusion. +% +It' not an easy thing to get your teeth around. +% +It rolls off her back like a duck. +% +It runs the full width of the totem pole. +% +It sounds like roses to my ears. +% +It sure hits the people between the head. +% +It was a heart-rendering decision. +% +It was a maelstrom around his neck. +% +It was deja vu all over again. +% +It was oozing right out of the lurches. +% +It was really amazing to see the spectra of people there. +% +It went through the palm of my shoe. +% +It will spurn a lot of furious action. +% +It will take a while to ravel down. +% +It's like asking a man to stop eating in the middle of a starvation diet. +% +It's a Byzantine thicket of quicksand. +% +It's a caterpillar in pig's clothing. +% +It's a fiat accompli. +% +It's a fool's paradise wrapped in sheep's clothing. +% +It's a hairy banana. +% +It's a hairy can of worms. +% +It's a home of contention. +% +It's a lot like recumbent DNA. +% +It's a lot of passed water under the bridge. +% +It's a mare's nest in sheep's clothing. +% +It's a mecca of people. +% +It's a monkey wrench in your ointment. +% +It's a new high in lows. +% +It's a road of hard knocks. +% +It's a sight for sore ears. +% +It's a slap in the chaps. +% +It's a tempest in a teacup. +% +It's a terrible crutch to bear. +% +It's a tough nut to hoe. +% +It's a tough road to haul. +% +It's a travesty to the human spirit. +% +It's a typical case of alligator mouth and hummingbird ass. +% +It's a useful ace in the pocket. +% +It's a white elephant around my neck. +% +It's a white herring. +% +It's about 15 feet as the eye flies. +% +It's about as satisfactory as falling off a log. +% +It's all above and beyond board. +% +It's all in knowing when to let a dead horse die. +% +It's all water under the dam. +% +It's always better to be safe than have your neck out on a limb. +% +It's an ill wind that doesn't blow somebody. +% +It's another millstone in the millpond of life. +% +It's as easy as falling off a piece of cake. +% +It's as flat as a door knob. +% +It's as predictable as cherry pie. +% +It's bouncing like a greased pig. +% +It's burned to shreds. +% +Its coming down like buckets outside. +% +It's crumbling at the seams. +% +It's enough to make you want to rot your socks. +% +It's going to bog everybody up. +% +It's going to fall on its ass from within. +% +It's got all the bugs and whistles. +% +It's hanging out like a sore tongue. +% +It's like a greased pig in a wet blanket. +% +It's like a knife through hot butter. +% +It's like a raft on roller skates. +% +It's like harnessing a hare to a tortoise. +% +It's like pulling hen's teeth. +% +It's like talking to a needle in a haystack. +% +It's like the flood of the Hesperis. +% +It's like trying to light a fire under a lead camel. +% +It's like trying to squeeze blood out of a stone. +% +It's more than the mind can boggle. +% +It's music to your eyes. +% +It's no chip off my clock. +% +It's no skin off my stiff upper lip. +% +It's no sweat off my nose. +% +It's not an easy thing to get your teeth wet on. +% +It's not completely an unblessed advantage. +% +It's not his bag of tea. +% +It's not my cup of pie. +% +It's not my Diet of Worms. +% +It's not really hide nor hair. +% +It's one more cog in the wheel. +% +It's perfect, but it will have to do. +% +It's raining like a bandit. +% +It's right on the tip of my head. +% +It's sloppy mismanagement. +% +It's so unbelievable you wouldn't believe it. +% +It's something you're all dying to wait for. +% +It's the blind leading the deaf. +% +It's the greatest little seaport in town. +% +It's the old chicken-in-the-egg problem. +% +It's the old Paul Revere bit . . . one if by two and two if by one. +% +It's the other end of the kettle of fish. +% +It's the straw that broke the ice. +% +It's the the highest of the lows. +% +It's the vilest smell I ever heard. +% +It's time to take off our gloves and talk from the heart. +% +It's under closed doors. +% +It's within the pall of reason. +% +It's wrought with problems. +% +It's your ball of wax, you unravel it. +% +I've been burning the midnight hours. +% +I've built enough fudge into that factor. +% +I've got applicants up to the ears. +% +I've got to put my duff to the grindstone. +% +I've had it up to the hilt. +% +I've had more girls than you've got hair between your teeth. +% +I've milked that dead end for all it's worth. +% +I've worked my shins to the bone. +% +Judas Proust! +% +Just because it's there, you don't have to mount it. +% +Just cut a thin slither of it. +% +Just remember that, and then forget it. +% +Keep the water as firm as possible until a fellow has his feet on the ground. +% +Keep this under your vest. +% +Keep your ear peeled! +% +Keep your eyes geared to the situation. +% +Keep your nose to the mark. +% +Keep your nose to the plow. +% +Lay a bugaboo to rest. +% +Let he who casts the first stone cast it in concrete. +% +Let him be rent from limb to limb. +% +Let him fry in his own juice. +% +Let it slip between the cracks. +% +Let me clarify my fumbling. +% +Let me feast your ears. +% +Let me flame your fan. +% +Let me say a word before I throw in the reins. +% +Let me take you under my thumb. +% +Let me throw a monkey into the wrench. +% +Let me throw a monkey wrench in the ointment. +% +Let sleeping uncertainties lie. +% +Let them fry in their socks. +% +Let them hang in their own juice. +% +Let's bend a few lapels. +% +Let's get down to brass facts. +% +Let's go outside and commiserate with nature. +% +Let's grab the initiative by the horns. +% +Let's kick the bucket with a certain amount of daintiness. +% +Let's kill two dogs with one bone. +% +Let's look at it from the other side of the view. +% +Let's lurch into the next hour of the show. +% +Let's not drag any more dead herrings across the garden path. +% +Let's not get ahead of the bandwagon. +% +Let's not hurdle into too many puddles at once. +% +Let's not open the skeleton in that closet. +% +Let's play the other side of the coin. +% +Let's put out a smeller. +% +Let's raise our horizons. +% +Let's roll up our elbows and get to work. +% +Let's set up a straw vote and knock it down. +% +Let's shoot holes at it. +% +Let's skin another can of worms. +% +Let's solve two problems with one bird. +% +Let's strike the fire before the iron gets hot. +% +Let's talk to the horse's mouth. +% +Let's wreck havoc! +% +Like the shoemaker's children, we have computers running out of our ears. +% +Look at the camera and say `bird'. +% +Look before you turn the other cheek. +% +Man cannot eat by bread alone. +% +May I inveigle on you? +% +Men, women, and children first! +% +Mind your own petard! +% +My antipathy runneth over. +% +My chicken house has come home to roost. +% +My dog was pent up all day. +% +My ebb is running low. +% +My foot is going out of its mind. +% +My head is twice its size. +% +My mind is a vacuum of information. +% +My mind slipped into another cog. +% +My mind went blank and I had to wait until the dust cleared. +% +My off-the-head reaction is negative. +% +My steam is wearing down. +% +My stomach gets all knotted up in rocks. +% +My train of thought went out to lunch. +% +Necessity is the invention of strange bedfellows. +% +Necessity is the mother of strange bedfellows. +% +Never feed a hungry dog an empty loaf of bread. +% +Never the twixt should change. +% +No Californian will walk a mile if possible. +% +No crumbs gather under his feet. +% +No dust grows under her feet. +% +No loaf is better than half a loaf at all. +% +No moss grows on his stone. +% +No one can predict the wheel of fortune as it falls. +% +No problem is so formidable that you can't just walk away from it. +% +No rocks grow on Charlie. +% +No sooner said, the better. +% +Nobody could fill his socks. +% +Nobody is going to give you the world in a saucer. +% +Nobody marches with the same drummer. +% +Nobody's going to put his neck out on a limb. +% +Nostalgia just isn't what it used to be. +% +Not all the irons in the fire will bear fruit or even come home to roost. +% +Not by the foggiest stretch of the imagination! +% +Not in a cocked hat, you don't! +% +Not in a pig's bladder you don't! +% +Not me, I didn't open my peep. +% +Not on your bootstraps! +% +Now he's sweating in his own pool. +% +Now the laugh is on the other foot! +% +Now we have some chance to cut new water. +% +One back scratches another. +% +One doesn't swallow the whole cake at the first sitting. +% +One man's curiosity is another man's Pandora's box. +% +Our backs are up the wall. +% +Our deal fell through the boards. +% +Peanut butter jelly go together hand over fist. +% +People in glass houses shouldn't call the kettle black. +% +Picasso wasn't born in a day. +% +Pick them up from their bootstraps. +% +Pictures speak louder than words. +% +Please come here ipso pronto. +% +Pour sand on troubled waters. +% +Put all your money where your marbles are. +% +Put it in a guinea sack. +% +Put it on the back of the stove and let it simper. +% +Put that in your pocket and smoke it! +% +Put the onus on the other foot. +% +Put your mouth where your money is. +% +Right off the top of my cuff, I don' know what to say. +% +Right off the top of my hand, I'd say no. +% +Roll out the Ouija ball. +% +Rome wasn't built on good intentions alone. +% +Row, row, row your boat, gently down the drain. +% +See the forest through the trees. +% +She had a missed conception. +% +She had an aurora of goodness about her. +% +She has eyes like two holes in a burnt blanket. +% +She hit the nail on the nose. +% +She looks like she's been dead for several years, lately. +% +She makes Raquel Welch look like Twiggy standing backwards. +% +She stepped full-face on it. +% +She was sitting there with an insidious look on her face. +% +She'll fight it tooth and toenail. +% +She's a virgin who has never been defoliated. +% +She's flying off the deep end. +% +She's got a bee in her bonnet and just won't let it go. +% +She's melting out punishment. +% +She's steel wool and a yard wide. +% +She's trying to feather her own bush. +% +Shoot it up the flag pole. +% +Somebody is going to have to take a forefront here. +% +Somebody pushed the panic nerve. +% +Somebody's flubbing his dub. +% +Someone is going to be left in the church with his pants on. +% +Sometimes I don't have both sails in the water. +% +Speaking off the hand, I'd advise you to quit. +% +Straighten up or fly right. +% +Strange bedfellows flock together. +% +Take care of two stones with one bird. +% +Take it with a block of salt. +% +That aspect permutes the whole situation. +% +That curdles my toes. +% +That curdles the milk of human kindness. +% +That didn't amount to a hill of worms. +% +That doesn't cut any weight with him. +% +That job is at the bottom of the rung. +% +That makes me as mad as a wet hatter. +% +That opens up a whole other kettle of songs. +% +That problem is getting pushed into the horizon. +% +That puts me up a worse creek. +% +That really uprooted the apple cart. +% +That restaurant is so crowded no one goes there anymore. +% +That solves two stones with one bird. +% +That was a mere peanut in the bucket. +% +That was almost half done unconsciously. +% +That was like getting the horse before the barn. +% +That was the corker in the bottle. +% +That was the pan he was flashed in. +% +That would drive him right out of his banana. +% +That would have been right up Harry's meat. +% +That'll take the steam out of their sails. +% +That's a ball of another wax. +% +That's a bird of a different color. +% +That's a camel's eye strained through a gnat's tooth. +% +That's a different jar of worms. +% +That's a horse of a different feather. +% +That's a matter for sore eyes. +% +That's a measle-worded statement if I ever heard one. +% +That's a sight for deaf ears. +% +That's a tough nut to carry on your back. +% +That's a two-edged circle. +% +That's a whole new ballpark. +% +That's an unexpected surprise. +% +That's getting to the crotch of the matter. +% +That's just putting the gravy on the cake. +% +That's no sweat off my back. +% +That's not my sack of worms. +% +That's obviously a very different cup of fish. +% +That's pushing a dead horse. +% +That's the other end of the coin. +% +That's the straw that broke the camel's hump. +% +That's the wart that sank the camel's back. +% +That's the way the old ball game bounces. +% +That's the whole ball of snakes. +% +That's the whole kettle of fish in a nutshell. +% +That's the whole kit and caboose. +% +That's their applecart, let them choke on it. +% +That's water under the dam. +% +That's way down in the chicken feed. +% +That's when I first opened an eyelash. +% +That's worse than running chalk up and down your back. +% +The grass is always greener when you can't see the forest for the trees. +% +The aggressor is on the wrong foot. +% +The analogy is a deeply superficial one. +% +The atmosphere militates against a solution. +% +The ball is in our lap. +% +The die has been cast on the face of the waters. +% +The early bird will find his can of worms. +% +The early worm catches the fish. +% +The eggs we put all in one basket have come home to roost. +% +The faculty has cast a jaundiced eye upon the waters. +% +The fervor is so deep you can taste it. +% +The foot that rocks the cradle is usually in the mouth. +% +The fruits of our labors are about to be felt. +% +The future is not what it used to be. +% +The gremlins have gone off to roost on someone else's canard. +% +The grocer's son always has shoes. +% +The groundwork is thoroughly broken. +% +The hand is on the wall. +% +The horse is stolen before the barn even gets its door closed. +% +The idea did cross my head. +% +The ideas sprang full-blown from the hydra's heads. +% +The initiative is on the wrong foot. +% +The lights are so bright the air is opaque. +% +The meeting was a first-class riot squad. +% +The onus is on the other foot. +% +The pipeline has ramped up. +% +The restaurants are terrible; the town is completely indigestible. +% +The sink is shipping. +% +The up-kick of all that will be nothing. +% +The viewpoints run from hot to cold. +% +The whole thing is a hairy potpourri. +% +The wishbone's connected to the kneebone. +% +Their attitude is to let lying dogs sleep. +% +There are enough cooks in the pot already. +% +There are too many cooks and not enough Indians. +% +There are two sides to every marshmallow. +% +There hasn't been much of a peep about it. +% +There is a prolifery of new ideas. +% +There is no surefool way of proceeding. +% +There is one niche in his armor. +% +There is some milk of contention between us. +% +There was danger lurking under the tip of an iceberg. +% +There were foot-high puddles. +% +There will be fangs flying. +% +There's a dark cloud on every rainbow's horizon. +% +There's a flaw in the ointment. +% +There's a little life in the old shoe yet. +% +There's a lot of blanche here to carte. +% +There's a lot of bull in the china shop. +% +There's a lot of credibility in that gap! +% +There's a strong over current here. +% +There's a vortex swimming around out there. +% +There's going to be hell and high water to pay. +% +There's laughing on the outside, panelling on the inside. +% +There's more than one way to skin an egg without letting the goose +out of the bag. +% +There's no place in the bowl for another spoon to stir the broth. +% +There's no two ways around it. +% +There's nothing like stealing the barn door after the horse is gone. +% +There's some noise afoot about the problem. +% +There's some trash to be separated from the chaff. +% +They are straining at nits. +% +They are unscrupulously honest. +% +They are very far and few between. +% +They closed the doors after the barn was stolen. +% +They descended on me like a hoar of locust. +% +They don't like to dictate themselves to the problem. +% +They don't see eye for eye with us. +% +They don't stand a tea bag's chance in hell. +% +They fell all over their faces. +% +They just want to chew the bull. +% +They just want to shoot the fat. +% +They locked the door after the house was stolen. +% +They make strange bedfellows together. +% +They rolled their eyebrows at me. +% +They run across the gamut. +% +They sucked all the cream off the crop. +% +They sure dipsied his doodle. +% +They unspaded some real down to earth data. +% +They went after him tooth and fang. +% +They wrecked havoc in the kitchen. +% +They'll carve that spectrum any way we desire it. +% +They're atrophying on the vine. +% +They're colder than blue blazes. +% +They're coming farther between. +% +They're dropping his course like flies. +% +They're dying off like fleas. +% +They're eating out of our laps. +% +They're germs in the rough. +% +They're grasping for needles. +% +They're spreading like wild flowers. +% +They're very far and few between. +% +They're working their bones off. +% +They's chomping their lips at the prospect. +% +They've beaten the bushes to death. +% +They've got the bull by the tail now. +% +They've reached a new level of lowness. +% +Things are all up in a heaval. +% +Things have slowed down to a terrible halt. +% +Things keep falling out of it, three or four years at a time. +% +This field of research is so virginal that no human eye has set foot on it. +% +This program has many weaknesses, but its strongest weakness remains to be seen. +% +This bit of casting oil on troubled feathers is more than I can take. +% +This ivory tower we're living in is a glass house. +% +This office requires a president who will work right up to the hilt. +% +This thing kills me to the bone. +% +This wine came from a really great brewery. +% +This work was the understatement of the year. +% +Those are good practices to avoid. +% +Those guys are as independent as hogs on ice. +% +Those guys weld a lot of power. +% +Those people have no bones to grind. +% +Those words were very carefully weaseled. +% +Time and tide strike but once. +% +To be a leader, you have to develop a spear de corps. +% +To coin a cliche, let's have at them. +% +To sweeten the pie, I'll add some cash. +% +To the cook goes the broth! +% +Together again for the first time. +% +Too many chiefs spoil the soup. +% +Too many drinks spoil the broth. +% +Too many hands spoil the soap. +% +Trying to do anything is like a tour de force. +% +Trying to get a doctor on Wednesday is like trying to shoot a horse on Sunday. +% +Watch her, she gets on the stick very quickly. +% +We are on equally unfooted ground. +% +We are paying for the sins of serenity. +% +We brought this can of worms into the open. +% +We can clean ourselves right up to date. +% +We can throw a lot of muscle into the pot. +% +We can't get through the forest for the trees. +% +We didn't know which facts were incorrect. +% +We don't want to get enhangled in that either. +% +We got another thing out of it that I want to heave in. +% +We got on board at ground zero. +% +We got the story post hoc. +% +We have a difference of agreement. +% +We have a real ball of wax to unravel. +% +We have a real messy ball of wax. +% +We have a wide range of broad-gauge people. +% +We have achieved a wide specter of support. +% +We threw everything in the kitchen sink at them. +% +We're getting down to bare tacks. +% +What can we do to shore up these problems? +% +When the tough get going they let sleeping dogs lie. +% +When they go downstairs, you can hear neither hide nor hair of them. +% +When you're jumping on sacred cows, you've got to watch your step. +% +You can make a prima donna sing, but you can't make her dance. +% +You get more for your mileage that way. +% +You gotta strike while the shoe is hot or the iron may be on the other foot. +% +You have sowed a festering cowpie of suspicion. +% +You put all your eggs before the horse. +% +You really can't compare us -- our similarities are different. +% +Your wild oats have come home to roost. +% +You're blowing it all out of context. +% +You've always been the bone of human kindness. +%