open-adventure.git
3 years agoLocalize scope for restore file pointer in main. 186/head
Aaron Traas [Sun, 2 Jul 2017 06:28:58 +0000 (02:28 -0400)]
Localize scope for restore file pointer in main.

3 years agoCoverage -- version command
Aaron Traas [Sun, 2 Jul 2017 06:14:41 +0000 (02:14 -0400)]
Coverage -- version command

3 years agocentralize calls to make_zzword()
Aaron Traas [Sun, 2 Jul 2017 06:02:09 +0000 (02:02 -0400)]
centralize calls to make_zzword()

make_zzword() now called in set_seed(), because the only times it was
called in the entire application is after every invocation of set_seed().

3 years agoFixed -r option. Added test to make sure it doesn't break later.
Aaron Traas [Sun, 2 Jul 2017 05:36:28 +0000 (01:36 -0400)]
Fixed -r option. Added test to make sure it doesn't break later.

3 years agoChanged usage message to multi-line string for cheat
Aaron Traas [Sun, 2 Jul 2017 05:17:14 +0000 (01:17 -0400)]
Changed usage message to multi-line string for cheat

3 years agomake_zzword() moved to initialize. Pruned unused stuff from cheat.c
Aaron Traas [Sun, 2 Jul 2017 05:07:53 +0000 (01:07 -0400)]
make_zzword() moved to initialize. Pruned unused stuff from cheat.c

3 years agoImprove test coverage.
Eric S. Raymond [Sun, 2 Jul 2017 03:51:24 +0000 (23:51 -0400)]
Improve test coverage.

3 years agoRewrite dwarf-encounter ceck so coverage testing sees all predicates.
Eric S. Raymond [Sun, 2 Jul 2017 03:33:57 +0000 (23:33 -0400)]
Rewrite dwarf-encounter ceck so coverage testing sees all predicates.

3 years agoMore magic-number elimination.
Eric S. Raymond [Sun, 2 Jul 2017 03:07:23 +0000 (23:07 -0400)]
More magic-number elimination.

3 years agoMagic-number elimination.
Eric S. Raymond [Sun, 2 Jul 2017 02:50:08 +0000 (22:50 -0400)]
Magic-number elimination.

3 years agoFix typo in data comments
Wayne Conrad [Sat, 1 Jul 2017 21:25:29 +0000 (14:25 -0700)]
Fix typo in data comments

3 years agoFix typo in notes
Wayne Conrad [Sat, 1 Jul 2017 21:24:41 +0000 (14:24 -0700)]
Fix typo in notes

3 years agoSupply missing implementation of nodwarf bit in travel rules.
Eric S. Raymond [Sat, 1 Jul 2017 22:56:46 +0000 (18:56 -0400)]
Supply missing implementation of nodwarf bit in travel rules.

3 years agoAnother step in de-obscurifying the travel code.
Eric S. Raymond [Sat, 1 Jul 2017 18:20:34 +0000 (14:20 -0400)]
Another step in de-obscurifying the travel code.

3 years agoRefactor specials[] to have strings instead of enum references. 184/head
Jason S. Ninneman [Sat, 1 Jul 2017 18:53:54 +0000 (11:53 -0700)]
Refactor specials[] to have strings instead of enum references.

Clean up arbitrary_messages[] accordingly.

3 years agoMinor refactor - create an equality function to simplify skip logic.
Eric S. Raymond [Sat, 1 Jul 2017 18:03:01 +0000 (14:03 -0400)]
Minor refactor - create an equality function to simplify skip logic.

3 years agoNever write the input prompt to log files. 183/head
Jason S. Ninneman [Sat, 1 Jul 2017 18:03:20 +0000 (11:03 -0700)]
Never write the input prompt to log files.

3 years agoForther break apart the magic enconding of travel arrays.
Eric S. Raymond [Sat, 1 Jul 2017 16:51:12 +0000 (12:51 -0400)]
Forther break apart the magic enconding of travel arrays.

3 years agoRemove debris from a misclick.
Eric S. Raymond [Sat, 1 Jul 2017 16:40:12 +0000 (12:40 -0400)]
Remove debris from a misclick.

3 years agoIgnore l g z i under oldstyle.
Eric S. Raymond [Sat, 1 Jul 2017 16:34:44 +0000 (12:34 -0400)]
Ignore l g z i under oldstyle.

3 years agoChange state of vase 182/head
NHOrus [Sat, 1 Jul 2017 15:23:51 +0000 (18:23 +0300)]
Change state of vase
Clear temporary save where it needs to be cleared instead of random places

3 years agoDo not compare state to magic numbers
NHOrus [Sat, 1 Jul 2017 15:12:25 +0000 (18:12 +0300)]
Do not compare state to magic numbers

3 years agoLittle more less magic in dragon state
NHOrus [Sat, 1 Jul 2017 14:44:58 +0000 (17:44 +0300)]
Little more less magic in dragon state

3 years agoDocumentation polishing.
Eric S. Raymond [Sat, 1 Jul 2017 15:01:06 +0000 (11:01 -0400)]
Documentation polishing.

3 years agoEnsure libedit is installed for the pipeline jobs. 181/head
Jason S. Ninneman [Sat, 1 Jul 2017 14:29:53 +0000 (07:29 -0700)]
Ensure libedit is installed for the pipeline jobs.

3 years agoAttempt to unbreak pipeline.
Jason S. Ninneman [Sat, 1 Jul 2017 14:27:37 +0000 (07:27 -0700)]
Attempt to unbreak pipeline.

3 years agoJettison the -s option. 180/head
Jason S. Ninneman [Sat, 1 Jul 2017 14:22:12 +0000 (07:22 -0700)]
Jettison the -s option.

It's no longer needed since libedit doesn't have the 'paste bug'.

3 years agoRemove the linenoise submodule.
Jason S. Ninneman [Sat, 1 Jul 2017 14:17:35 +0000 (07:17 -0700)]
Remove the linenoise submodule.

3 years agoMove most build instructions into INSTALL.adoc.
Jason S. Ninneman [Sat, 1 Jul 2017 14:14:27 +0000 (07:14 -0700)]
Move most build instructions into INSTALL.adoc.

3 years agoUpdate documentation about the libedit conversion.
Jason S. Ninneman [Sat, 1 Jul 2017 13:59:39 +0000 (06:59 -0700)]
Update documentation about the libedit conversion.

3 years agoReplace linenoise with libedit in code and build.
Jason S. Ninneman [Sat, 1 Jul 2017 13:51:00 +0000 (06:51 -0700)]
Replace linenoise with libedit in code and build.

3 years agoMagic-number elimination for dragon and rug.
Eric S. Raymond [Sat, 1 Jul 2017 13:58:45 +0000 (09:58 -0400)]
Magic-number elimination for dragon and rug.

3 years agoReindend, compile out all save stuff 179/head
NHOrus [Sat, 1 Jul 2017 13:46:51 +0000 (16:46 +0300)]
Reindend, compile out all save stuff

3 years agoPut stuff back in init, C-style
NHOrus [Sat, 1 Jul 2017 13:45:42 +0000 (16:45 +0300)]
Put stuff back in init, C-style

3 years agoApply DEMOTE_WORD(). 178/head
Jason S. Ninneman [Sat, 1 Jul 2017 13:21:37 +0000 (06:21 -0700)]
Apply DEMOTE_WORD().

3 years agoMagic-number and state-arithmetic removal.
Eric S. Raymond [Sat, 1 Jul 2017 13:21:04 +0000 (09:21 -0400)]
Magic-number and state-arithmetic removal.

3 years agoAdd a DEMOTE_WORD() macro. 177/head
Jason S. Ninneman [Sat, 1 Jul 2017 13:18:24 +0000 (06:18 -0700)]
Add a DEMOTE_WORD() macro.

3 years agoInterim magic number replacement.
Jason S. Ninneman [Sat, 1 Jul 2017 13:15:54 +0000 (06:15 -0700)]
Interim magic number replacement.

3 years agoMove PRNG initialization to simplify cheat.c
Eric S. Raymond [Sat, 1 Jul 2017 12:59:45 +0000 (08:59 -0400)]
Move PRNG initialization to simplify cheat.c

3 years agoSpread documentation from init.c It was empty without anything to document. Reindente...
NHOrus [Sat, 1 Jul 2017 11:36:54 +0000 (14:36 +0300)]
Spread documentation from init.c It was empty without anything to document. Reindented, too

3 years agoCut initialize in favor of implicit/default initialization where possible
NHOrus [Sat, 1 Jul 2017 11:21:07 +0000 (14:21 +0300)]
Cut initialize in favor of implicit/default initialization where possible

3 years agoPutting cleanup in the right place, too 175/head
NHOrus [Sat, 1 Jul 2017 08:50:49 +0000 (11:50 +0300)]
Putting cleanup in the right place, too

3 years agoFix make debug check
NHOrus [Sat, 1 Jul 2017 07:51:13 +0000 (10:51 +0300)]
Fix make debug check

3 years agoWithout IGNORE, -Wunused-result throws a warning on fread(2).
Eric S. Raymond [Sat, 1 Jul 2017 12:35:05 +0000 (08:35 -0400)]
Without IGNORE, -Wunused-result throws a warning on fread(2).

I've seen it happen on fwrite(2) as well; wrapping that as well in
case some compiler decides to be finicky.

3 years agoMagic-number elimination.
Eric S. Raymond [Sat, 1 Jul 2017 05:59:06 +0000 (01:59 -0400)]
Magic-number elimination.

3 years agoTest modification for little more coverage
NHOrus [Fri, 30 Jun 2017 23:44:00 +0000 (02:44 +0300)]
Test modification for little more coverage

3 years agoStop leaking memory
NHOrus [Fri, 30 Jun 2017 23:13:30 +0000 (02:13 +0300)]
Stop leaking memory

3 years agoVarious cleanups. 173/head
Jason S. Ninneman [Fri, 30 Jun 2017 20:51:03 +0000 (13:51 -0700)]
Various cleanups.

* Remove disused macro.
* GCC doesn't seem to mind if IGNORE() is left off.
* Enumify phase codes.
* Use EXIT_* macros in all exit() calls.
* How did this even work without extern?
* Give advent.h a much-needed makeover.
* Use the chomp indicator in YAML string blocks to avoid code ugliness.

3 years agoError message when you make if without retrieving git modules yet 172/head
Aaron Traas [Fri, 30 Jun 2017 19:56:46 +0000 (15:56 -0400)]
Error message when you make if without retrieving git modules yet

3 years agoUse YAML block-literal syntax to avoid wrapped lines.
Eric S. Raymond [Fri, 30 Jun 2017 20:19:02 +0000 (16:19 -0400)]
Use YAML block-literal syntax to avoid wrapped lines.

In vspeak(), andle text with extra trailing \n.

3 years agoThe bugtype enum doesn't need explicit numbers. 171/head
Jason S. Ninneman [Fri, 30 Jun 2017 18:26:11 +0000 (11:26 -0700)]
The bugtype enum doesn't need explicit numbers.

3 years agoPlugged little linenoise memory leaks. 170/head
NHOrus [Fri, 30 Jun 2017 18:30:01 +0000 (21:30 +0300)]
Plugged little linenoise memory leaks.

3 years agoImplement and document %V escape so version only needs to be set once.
Eric S. Raymond [Fri, 30 Jun 2017 18:35:18 +0000 (14:35 -0400)]
Implement and document %V escape so version only needs to be set once.

3 years agoRemove disused function definitions. 169/head
Jason S. Ninneman [Fri, 30 Jun 2017 18:08:54 +0000 (11:08 -0700)]
Remove disused function definitions.

3 years agoRemove more disused macros.
Jason S. Ninneman [Fri, 30 Jun 2017 18:05:37 +0000 (11:05 -0700)]
Remove more disused macros.

3 years agoRemove some disused stuff.
Jason S. Ninneman [Fri, 30 Jun 2017 17:56:38 +0000 (10:56 -0700)]
Remove some disused stuff.

3 years agoMagic-number elimination.
Eric S. Raymond [Fri, 30 Jun 2017 17:30:49 +0000 (13:30 -0400)]
Magic-number elimination.

3 years agoRemoved line as redundant
NHOrus [Fri, 30 Jun 2017 17:03:18 +0000 (20:03 +0300)]
Removed line as redundant

As of 8675c4facd154b9 lines 612-613 in main.c unreachable due to earlier
dispatch at line 1132 that redirects all find/inventory verbs into actions.c
Message NEARBY fires from YAML link to those verbs.
Also, reduced signature of playermove() to motion only.

3 years agoLess magical numbers.
Eric S. Raymond [Fri, 30 Jun 2017 16:10:26 +0000 (12:10 -0400)]
Less magical numbers.

3 years agoImprove test coverage.
Eric S. Raymond [Fri, 30 Jun 2017 16:05:38 +0000 (12:05 -0400)]
Improve test coverage.

3 years agoMagic-number ellimination, contiguity warnings, cleanup.
Eric S. Raymond [Fri, 30 Jun 2017 15:58:17 +0000 (11:58 -0400)]
Magic-number ellimination, contiguity warnings, cleanup.

3 years agoTests for misc and main 166/head
NHOrus [Fri, 30 Jun 2017 15:30:19 +0000 (18:30 +0300)]
Tests for misc and main

3 years agoRemove gaps from arbitrary_messages, there are no more number sependencies.
Eric S. Raymond [Fri, 30 Jun 2017 15:25:46 +0000 (11:25 -0400)]
Remove gaps from arbitrary_messages, there are no more number sependencies.

Some spans within the list may still rely on contiguity.

3 years agoFixed previous test, added nibble more 165/head
NHOrus [Fri, 30 Jun 2017 14:56:59 +0000 (17:56 +0300)]
Fixed previous test, added nibble more

3 years agoMagic-number elimination.
Eric S. Raymond [Fri, 30 Jun 2017 15:03:57 +0000 (11:03 -0400)]
Magic-number elimination.

3 years agoFix date typo.
Eric S. Raymond [Fri, 30 Jun 2017 14:46:59 +0000 (10:46 -0400)]
Fix date typo.

3 years agoLast one test case 164/head
NHOrus [Fri, 30 Jun 2017 09:27:11 +0000 (12:27 +0300)]
Last one test case

3 years agoSome more easy tests
NHOrus [Fri, 30 Jun 2017 08:31:18 +0000 (11:31 +0300)]
Some more easy tests

3 years agoUpdate illformed.chk for current YAML. 1.1
Eric S. Raymond [Thu, 29 Jun 2017 22:27:14 +0000 (18:27 -0400)]
Update illformed.chk for current YAML.

3 years agoDeduce version from NEWS.
Eric S. Raymond [Thu, 29 Jun 2017 22:25:45 +0000 (18:25 -0400)]
Deduce version from NEWS.

3 years agoUpdate NEWS.
Eric S. Raymond [Thu, 29 Jun 2017 21:54:30 +0000 (17:54 -0400)]
Update NEWS.

3 years agoImplement 'version' command.
Eric S. Raymond [Thu, 29 Jun 2017 21:52:26 +0000 (17:52 -0400)]
Implement 'version' command.

3 years agoTest coverage -- fix regression 163/head
Aaron Traas [Thu, 29 Jun 2017 21:22:00 +0000 (17:22 -0400)]
Test coverage -- fix regression

3 years agoTest coverage - add lots more coverage from actions.c 162/head
Aaron Traas [Thu, 29 Jun 2017 20:40:21 +0000 (16:40 -0400)]
Test coverage - add lots more coverage from actions.c

3 years agoNot the best idea to try to rewach Don Woods for help any more.
Eric S. Raymond [Thu, 29 Jun 2017 20:59:27 +0000 (16:59 -0400)]
Not the best idea to try to rewach Don Woods for help any more.

3 years agoTypo fix.
Eric S. Raymond [Thu, 29 Jun 2017 20:46:36 +0000 (16:46 -0400)]
Typo fix.

3 years agoAdd Aaron Traas to credits.
Eric S. Raymond [Thu, 29 Jun 2017 20:44:01 +0000 (16:44 -0400)]
Add Aaron Traas to credits.

3 years agoStart another round of magic_number removal, this time for motions.
Eric S. Raymond [Thu, 29 Jun 2017 20:41:49 +0000 (16:41 -0400)]
Start another round of magic_number removal, this time for motions.

3 years agoDocumentation and comment cleanup.
Aaron Traas [Thu, 29 Jun 2017 20:37:07 +0000 (16:37 -0400)]
Documentation and comment cleanup.

Also, renove uused enums.

3 years ago'd' had a collision; 'drop' vs ;down'. Remove from 'drop' synonyms.
Eric S. Raymond [Thu, 29 Jun 2017 20:28:20 +0000 (16:28 -0400)]
'd' had a collision; 'drop' vs ;down'. Remove from 'drop' synonyms.

3 years agoDocumentation polishing and minor test improvements.
Eric S. Raymond [Thu, 29 Jun 2017 20:25:55 +0000 (16:25 -0400)]
Documentation polishing and minor test improvements.

3 years agoBreaking one-line conditionals 160/head
NHOrus [Thu, 29 Jun 2017 19:51:30 +0000 (22:51 +0300)]
Breaking one-line conditionals

3 years agoRe-indented.
Eric S. Raymond [Thu, 29 Jun 2017 19:45:59 +0000 (15:45 -0400)]
Re-indented.

3 years agoClean out the now-disused vocabulary structure.
Jason S. Ninneman [Thu, 29 Jun 2017 18:20:36 +0000 (11:20 -0700)]
Clean out the now-disused vocabulary structure.

3 years agoUpdated documentation
Aaron Traas [Thu, 29 Jun 2017 19:13:11 +0000 (15:13 -0400)]
Updated documentation

3 years agoCleanup test case
Aaron Traas [Thu, 29 Jun 2017 16:54:07 +0000 (12:54 -0400)]
Cleanup test case

3 years agoCoverage - Die while closing after lamp dim
Aaron Traas [Thu, 29 Jun 2017 16:28:46 +0000 (12:28 -0400)]
Coverage - Die while closing after lamp dim

3 years agok2 is dead 157/head
NHOrus [Thu, 29 Jun 2017 18:13:53 +0000 (21:13 +0300)]
k2 is dead

3 years agoUntangling variable reuse
NHOrus [Thu, 29 Jun 2017 18:08:09 +0000 (21:08 +0300)]
Untangling variable reuse

3 years agoSeparate debugging of linenoise 156/head
NHOrus [Thu, 29 Jun 2017 17:23:39 +0000 (20:23 +0300)]
Separate debugging of linenoise

3 years agoFix an OB1 bug in allocation.
Eric S. Raymond [Thu, 29 Jun 2017 17:43:36 +0000 (13:43 -0400)]
Fix an OB1 bug in allocation.

3 years agoUnshadowed k2 into k3 in main.c 155/head
NHOrus [Thu, 29 Jun 2017 17:11:53 +0000 (20:11 +0300)]
Unshadowed k2 into k3 in main.c
Reindented everything

3 years agoUpstream linenoise rebased their project. 154/head
Jason S. Ninneman [Thu, 29 Jun 2017 16:34:23 +0000 (09:34 -0700)]
Upstream linenoise rebased their project.

3 years agoTransition to YAML is done, adventure.text and travel.py can go away.
Eric S. Raymond [Thu, 29 Jun 2017 16:21:50 +0000 (12:21 -0400)]
Transition to YAML is done, adventure.text and travel.py can go away.

3 years agoComment polishing.
Eric S. Raymond [Thu, 29 Jun 2017 16:18:55 +0000 (12:18 -0400)]
Comment polishing.

3 years agoFinish newdb -> dungeon renaming. 153/head
Jason S. Ninneman [Thu, 29 Jun 2017 15:49:12 +0000 (08:49 -0700)]
Finish newdb -> dungeon renaming.

3 years agonewdungeon.py is now make_dungeon.py.
Jason S. Ninneman [Thu, 29 Jun 2017 15:45:47 +0000 (08:45 -0700)]
newdungeon.py is now make_dungeon.py.

newdb.[ch] is now dungeon.[ch].

3 years agoRemove MAPLIN(). Fold common.[ch] into other files and remove them.
Jason S. Ninneman [Thu, 29 Jun 2017 15:41:32 +0000 (08:41 -0700)]
Remove MAPLIN(). Fold common.[ch] into other files and remove them.

3 years agoJettison MAKEWD(), GETTXT(), vocab(), GETIN(), and the old db compiler.
Jason S. Ninneman [Thu, 29 Jun 2017 15:35:48 +0000 (08:35 -0700)]
Jettison MAKEWD(), GETTXT(), vocab(), GETIN(), and the old db compiler.

3 years agoCoverage - Test going back when you can't. 152/head
Aaron Traas [Thu, 29 Jun 2017 14:57:34 +0000 (10:57 -0400)]
Coverage - Test going back when you can't.