summaryrefslogtreecommitdiffstats
path: root/battlestar
Commit message (Collapse)AuthorAgeFilesLines
* Use standard AUTHORS section header. From YOMURA Masanori in private mailwiz2005-09-151-2/+2
| | | Sort sections if necessary. Use more/better markup.
* KNF and WARNS=3jmc2005-07-0117-394/+667
|
* Add (unsigned char) cast to ctype functionsdsl2004-11-051-11/+11
|
* Remove uses of __P.jsm2004-01-275-80/+80
|
* Move UCB-licensed code from 4-clause to 3-clause licence.agc2003-08-0725-172/+72
| | | Patches provided by Joel Baker in PR 22269, verified by myself.
* Grammar fixes, from jmc@openbsd.wiz2003-04-261-3/+3
|
* Lots of minor fixes resulting from reading these man pages in detail.wiz2002-09-261-15/+9
|
* New sentences begin on new lines.wiz2002-09-261-14/+15
| | | Patch from Richard Elz, slightly improved by yours truly.
* Generate <>& symbolically. I'm avoiding .../dist/... directories for now.ross2002-02-081-11/+11
|
* Convert old deprecated curses call to new equivalent.blymn2001-12-041-3/+3
|
* Rename com#.c to command#.c to avoid conflicts with those file basenamestv2001-10-198-16/+17
| | | on certain Microsoft host OS's.
* `existent', not `existant'wiz2001-06-191-3/+3
|
* don't deref -1.christos2001-06-021-3/+3
|
* Whitespace and/or punctuation fixes.wiz2001-04-021-3/+3
|
* In cypher(), don't attempt to make sense of words other than VERBs orjsm2000-09-255-12/+31
| | | | | | | | KNIFE when a verb is required. Add AUXVERB for "make", "move", "climb" (as in "make love", "climb up") and ignore AUXVERB as a verb, going on to the next word, instead of treating these words as adjectives. When creating new verbs from "put on", "put down", "take off", mark them as type VERB. Mostly from Paul Janzen <pjanzen@foatdi.harvard.edu>.
* Add new flags OBJ_PERSON and OBJ_NONOBJ to the objflags array.jsm2000-09-252-12/+29
|
* Add OBJ_AN flag to objflags so as to use "a" or "an" appropriately injsm2000-09-254-30/+38
| | | | messages; avoids "a amulet", "a Elf". Define and use macros to use "a", "an", "the", "is", "are" appropriately. Partly based on OpenBSD.
* Remove excess blank lines. From OpenBSD.jsm2000-09-251-14/+2
|
* Fix loving already loved goddess; avoid fallthrough after lovingjsm2000-09-251-3/+10
| | | goddess; give error on "love amulet". From OpenBSD.
* Use defined constant FINAL instead of hardcoded 275. From OpenBSD.jsm2000-09-251-3/+3
|
* Fix logic error in use of n and wordnumber in murder() when usingjsm2000-09-251-7/+7
| | | laser. From OpenBSD.
* Discard any part of a line of input that goes beyond our buffer ratherjsm2000-09-241-2/+8
| | | than treating it as our next line of input. From OpenBSD.
* Give less cryptic messages than "-1%" when WEIGHT or CUMBER are zero.jsm2000-09-241-5/+17
|
* Add explicit no-ops to empty loops following the NetBSD style guide.jsm2000-09-244-14/+20
|
* Make hash table static in parse.c.jsm2000-09-243-11/+11
|
* Use NULL instead of 0 (from OpenBSD). Also add or adjust comments.jsm2000-09-241-18/+18
|
* Correct spelling "dont" to "don't". From OpenBSD.jsm2000-09-243-9/+9
|
* Make functions local to parse.c static.jsm2000-09-242-9/+10
|
* Give a better message for trying to eat things it doesn't make sensejsm2000-09-241-7/+11
| | | | | | to eat. For something eatable, check first whether you're holding it, then whether you have a knife, then whether you're stuffed (gives better message for "eat coconuts" when you don't have any). From OpenBSD.
* Clean up fly.c by making local variables and functions static andjsm2000-09-242-23/+23
| | | removing abs() macro.
* Prevent CUMBER from going negative; avoid division by zero if it isjsm2000-09-242-7/+14
| | | zero.
* Attempt to disambiguate BODY for kicking. Avoid crashing or nonsensejsm2000-09-241-30/+55
| | | messages on "kick door" and "kick man". From OpenBSD.
* Allow for bathing goddess in love(); give better message for a loverjsm2000-09-231-13/+24
| | | that isn't present and for certain choices of lover. From OpenBSD.
* Allow for the bathing goddess in ravage(). From OpenBSD.jsm2000-09-231-4/+8
|
* Use a lookup table to identify whether objects are plural or singular,jsm2000-09-235-26/+41
| | | | instead of testing the final character against 's' in each place. Avoids oddities about "pot of jewels" and "compass".
* Don't say "Kicked." of an object not present; give sensible messages.jsm2000-09-221-3/+7
| | | From OpenBSD.
* Check for an object being taken not being there before checking forjsm2000-09-221-5/+5
| | | | whether it is too heavy or too bulky; gives a better message for "take viper" with the viper not present.
* Give appropriate messages (rather than saying nothing) if an verb isjsm2000-09-221-2/+48
| | | used with "all" and nothing relevant is present. From OpenBSD.
* Remove all adjectives in parse(), since they are nowhere used. Fixesjsm2000-09-226-28/+33
| | | | crash on "carry old all" shown up by fuzz testing. Patch from Paul Janzen <pjanzen@foatdi.harvard.edu>.
* Give an appropriate error on "kill all" rather than a crash orjsm2000-09-221-3/+4
| | | nonsense message. From OpenBSD.
* Various improvements to parsing in battlestar, mostly from OpenBSD.jsm2000-09-217-24/+99
| | | | | | | | | | | | | | | | | | | | Define a constant WORDLEN. Always use this constant and NWORD where appropriate. Use NWORD - 1 in battlestar.c to avoid off-by-one error. Increment wordnumber after the INVEN verb to allow it to be followed by a comma and other actions. Avoid overflowing elements of the words array if input words are too long. Parse "," as AND except when followed by a verb, to allow such constructions as "take foo, bar, and baz". Trim AND AND which may occur from the ", and" in such a list. Avoid crashes from EVERYTHING in the wrong place by moving it to the start of OBJECT AND EVERYTHING and NOUNS AND EVERYTHING sequences, and trimming EVERYTHING AND EVERYTHING.
* Don't try to wear anything that isn't OBJECT or NOUNS. Don't try tojsm2000-09-211-3/+6
| | | | | | wear DOOR or anything without a short description. Fixes crashes on "wear knfo" (bug reported by Peter Maydell <pmaydell@chiark.greenend.org.uk>), "wear wear", "wear kick", "wear door" and "wear goddess". Partly from OpenBSD.
* If no hand-to-hand weapons are available, try using the laser to killjsm2000-09-211-5/+31
| | | in murder(). From OpenBSD.
* die() on EOF; based on OpenBSD.jsm2000-09-211-2/+4
|
* From OpenBSD: in kiss(), "take" the bathing goddess if required, andjsm2000-09-211-30/+39
| | | give a better error message if the person to kiss is not present.
* Add missing initialisers (avoid gcc -W warnings) and comments givingjsm2000-09-182-556/+1106
| | | room numbers.
* Clean up formatting; partly from OpenBSD.jsm2000-09-177-240/+209
|
* Patches from OpenBSD: add verbs "open"/"unlock" (essentially a no-op),jsm2000-09-176-12/+85
| | | | | and "verbose"/"brief" (in verbose mode, always show long room descriptions), and synonyms "papaya" for "papayas" and "coconut" for "coconuts".
* Based on OpenBSD: spelling, punctuation, grammar and line lengthjsm2000-09-103-27/+32
| | | | adjustments, and support for '=' in room descriptions meaning a literal '-'.
* Wording, punctuation and line length improvements. Also adjust testjsm2000-09-107-26/+26
| | | | for killing nonsensical things to fix crash with "kill door". From OpenBSD.