Commit Graph

10318 Commits

Author SHA1 Message Date
PatR
4bd3fdbd57 Achievements documentation
> Todo:  redo the recently revised Achievements table again.  Current
> formatting isn't spanning page boundaries, resulting in a big chunk
> of blank space preceding it so that it will start on the next page.

The '.SD i' environment was causing this, and also changing the font
somehow when forcing the text to start on the next page (but not when
it fit on current page?).  Taking '.SD i' out loses the indentation
that Guidebook.ps had (one of the explicit differences between it and
Guidebook.txt), which looks a little inferior, but fixes the page
boundary issue.
2020-02-15 05:19:23 -08:00
PatR
91b569e6c4 Guidebook.dat, one-page edition of Guidebook.txt
Update sys/unix/Makefile.doc to be able to build Guidebook.dat, an
unpaginated copy of the plain text Guidebook.  It's generated from
the 'roff source rather than by attempting to post-process the
regular text Guidebook.

No doubt there are easier ways to do this.
2020-02-14 18:15:25 -08:00
PatR
eb919d3cdb fix #K355 - grammar issues with monster+container
Mon rummages in <container> and Mon takes <item> from <container>
was missing an() for the container itself and should have been
using doname() rather than xname() for any items taken out (when
done adjacent to hero).
2020-02-14 16:24:49 -08:00
PatR
629e417bba Guidebook update
This adds a new figure that shows the 3-line status.  Also expands
a couple of status items.

In the commands section, redo the hjkl direction diagram to make
"Figure 2" (now Figure 3) line up with the rest of the table.  Lot's
of trial and error involved, and the plain text version didn't come
out as expected (but still looks better than before).

Modify suit of armor table to wrap an additional line and make the
table narrower.  Having the pair of columns closer together is a bit
easier on eyes when tracking from the suit names to the AC number.

Todo:  redo the recently revised Achievements table again.  Current
formatting isn't spanning page boundaries, resulting in a big chunk
of blank space preceding it so that it will start on the next page.
(Only noticeable at the moment with the Postscript output; plain
text had enough room on its current page to not need to force next.)

Guidebook.tex is lagging again.
2020-02-14 15:28:28 -08:00
nhmall
334db31cd0 Guidebook update from latest cron-daily 2020-02-13 22:10:37 -05:00
nhmall
751f1f47ab Windows options dynamically
There are two executables int the windows binary, each of which
have different options and capabilities. Sharing of one dat/options
file hasn't really been an accurate approach.

Produce that information dynamically for the Windows exe files.

This impacts alt-v results.
2020-02-13 21:24:24 -05:00
PatR
cbe27c7702 unseen pet drowning
The "you have a sad feeling for a moment" message was only given when
one monster kills another (and the latter is an unseen pet).  Give it
for drowning too.  There are probably a bunch of other circumstances
which warrant it as well but I've settled for handling minliquid().
2020-02-13 15:38:59 -08:00
nhmall
878ec6ee2a Merge branch 'NetHack-3.7' of https://rodney.nethack.org:20040/git/NHsource into NetHack-3.7 2020-02-13 18:19:35 -05:00
nhmall
a213811975 stone/unexplored glyph follow-up
typo
2020-02-13 17:37:55 -05:00
Pasi Kallinen
5885962efd Alloc sizeof struct instead of pointer-to-struct 2020-02-13 22:06:50 +02:00
nhmall
5ca2cdbd86 eliminate an odd line wrapping noticed on windows 2020-02-13 00:59:04 -05:00
PatR
75e9055b89 plug a couple of memory leaks in sp_lev.c, take II
[...]
| Change selection_free(foo) to also free(foo) after freeing foo's
| fields.  Every use was already
|   selection_free(foo);
|   free(foo);
| except for the two instances of memory leak.

And except for the three which aren't in sp_lev.c, one of which was
dealing with memory managed by Lua.  This time it seems to be working
as intended.
2020-02-12 18:56:41 -08:00
PatR
914c78546f Guidebook spelling mistake 2020-02-12 16:22:33 -08:00
PatR
804499d9be add some new, easier achievements
Introduce eight achievements that can be attained by more players.
 Entered Gnomish Mines  - self explanatory
 Entered Mine Town      - the town portion, not just the level
 Entered a shop         - any tended shop on any level
 Entered a temple       - likewise for temple
 Consulted the Oracle   - bought at least one major or minor oracle
 Read a Discworld Novel - read at least one passage
 Entered Sokoban        - like mines
 Entered the Big Room   - not always possible since not always present

The novel and bigroom ones aren't always achieveable since novels are
only guaranteed if a book or scroll shop gets created and bigroom is
only guaranteed in wizard mode.  No one ever claimed that every
possible achievement can be attained in a single game.  (If one for
entering the Fort Ludios level--or perhaps entering the Fort itself--
eventually gets add, that won't be possible in every game either.)

The mine town one probably needs some tweaking.  Two of the town's
seven variants have no town boundary (despite a rectangular area of
pre-defined map) and at present simply arriving on either of those
levels is enough to be credited with the entered-town achievement.

Bump EDITLEVEL because u.uachieved[] has increased in size.  This
time it has been expanded to the maximum that xlogfile's bitmask of
achievements can handle, enough for up to 9 more achievements without
another EDITLEVEL increment.
2020-02-12 14:35:37 -08:00
PatR
1ec6e6f96b Guidebook.mn streamlining
Set up variable 'fF' once and use it to conditionalize between
fixed-width font Guidebook.txt and proportional-width font
Guidebook.ps instead of making the width comparison of 'f' and 'F'
each time.  There are four instances where it is used; three that
suppress some indentation for the plain text output and one that
manually wraps a couple of long lines for it.

This change shouldn't produce different output from before (last
night) and doesn't need any corresponding change in Guidebook.tex.
2020-02-12 11:43:25 -08:00
PatR
bfe23d0c8c Guidebook update: Achievements
Redo the Achievements section in Guidebook.mn to be more compact.
It's also become more complicated because it formats Guidebook.txt
differently from Guidebook.ps/.pdf.

Finally add the Achievements section to Guidebook.tex to catch up.
Not as complicated but also not tested.
2020-02-12 02:35:35 -08:00
PatR
7da5a8b8e3 Guidebook update: armor and other objects
Condense the clunky one entry per line table of suits of armor and
their AC values in Guidebook.mn.  Guidebook.tex uses a two-column table
that I've left alone.

Mention all the other types of armor instead of leaving out gloves and
shirts.  For armor commands, mention that P and R work.

Rings:  describe their interaction with gloves.  For ring commands,
include a pointer to amulets.

Amulets:  for amulet commands, mention that A, W, and T work.

Tools:  mention that some can be worn and include a pointer to amulets
for the relevant commands.  Also, that some can be wielded as weapons.

Boulders and statues:  boulders can be pushed and smashed, statues can
be smashed.

Gold:  not subject to blessing or cursing.  goldX option affects BUCX
filtering.
2020-02-11 17:21:39 -08:00
nhmall
2c69ad8771 improve the g.multi condition results 2020-02-11 14:04:19 -05:00
nhmall
40bb0b2bb8 update Guidebook.txt from cron-NetHack-3.7 2020-02-11 00:25:27 -05:00
nhmall
b7e0a9a9dc version bit 2020-02-11 00:04:28 -05:00
nhmall
0342a2b029 bump Guidebook date 2020-02-10 23:56:46 -05:00
nhmall
7421c989e5 accuracy bit 2020-02-10 23:39:37 -05:00
nhmall
a7122a0656 minor correction to Guidebook.tex 2020-02-10 23:33:34 -05:00
nhmall
4a7cb8d3d7 Merge branch 'chasonr-msdos-video-doc' into NetHack-3.7 2020-02-10 23:26:26 -05:00
nhmall
e779165733 Guidebook corrections for msdos video_width and video_height
merge pull request #294 from chasonr

Closes #294
2020-02-10 23:20:58 -05:00
nhmall
de339ce14d Merge branch 'msdos-video-doc' of https://github.com/chasonr/NetHack into chasonr-msdos-video-doc 2020-02-10 23:05:33 -05:00
nhmall
1566063b4c bump editlevel
the code in pr298 altered the sound bit for one existing monster
2020-02-10 22:12:38 -05:00
nhmall
292d681efa sounds for minotaurs pr298
Closes #298
2020-02-10 22:04:10 -05:00
nhmall
0b15b99b12 Merge branch 'NullCGT-minotaurs-pr298' into NetHack-3.7 2020-02-10 22:02:26 -05:00
PatR
9a8bea550f Revert "plug a couple of memory leaks in sp_lev.c"
This reverts commit 1b7ac93930.

I just got a crash from within Lua when loading mine town and it
appears to be memory related, so back out the "plug leaks" commit
for the time being.
2020-02-10 15:44:16 -08:00
PatR
1b7ac93930 plug a couple of memory leaks in sp_lev.c
selection_floodfill() would free the contents of its temporary
selection structure when the check function was Null but neglected
to free the allocated structure itself.  I don't know whether that
was ever triggered.

generate_way_out_method() did likewise when trying to make a hole
or trapdoor.  It reused the 'ov3' pointer without freeing it first.
'heaputil' reported instances of non-freed memory that were
allocated at line 3612 by selection_clone(), only called within
generate_way_out_method().

Change selection_free(foo) to also free(foo) after freeing foo's
fields.  Every use was already
  selection_free(foo);
  free(foo);
except for the two instances of memory leak.
2020-02-10 14:23:47 -08:00
PatR
bade2f19b2 simplify Achievements display
The you-acquired-the-Amulet achievement uses alternate wording when
you were carrying it but just gave it up via #offer to ascend.  That
wording looks much better when displayed right before "You ascended!",
without entered-endgame and entered-astral (and maybe always-blind or
never-wore-armor) achievements in between.  That was and still is done
by taking it away.  Adding it back in the desired spot is simpler than
leaving it out while tracking whether it was removed.

Effectively, ACH_UWIN (ascension) is forced to be very last--where it
will always be anyway, but at one point the blind and nudist ones came
after it--and ACH_AMUL (you obtained the Amulet) is sorted to right
before that.  For non-ascending games, the Amulet achievement is left
in the position where it was attained.
2020-02-10 11:21:44 -08:00
PatR
d462bdffca redo achievement tracking
Instead of an assortment of bits, assign numeric indices to the
potential achievements and keep an array of those in the order they
were attained.  So disclosure might show the same subset occurring
differently in different games depending on the player's actions.
The encoded field in xlogfile doesn't care about that and remains
the same.

Modifies 'struct u', so EDITLEVEL has been incremented and existing
save files are invalidated.
2020-02-10 00:17:54 -08:00
nhmall
9b0ded6ff6 Merge branch 'feature/sounds' of https://github.com/NullCGT/NetHack into NullCGT-minotaurs-pr298 2020-02-09 20:38:22 -05:00
PatR
89c1b09d70 Achievements doc bit
Confusion on my part.  "Entered Gehennom" achievement is recorded if
you enter the Valley of the Dead rather than requiring that you get
past that level.

Guidebook.tex is still lagging but not forgotten.
2020-02-09 16:56:23 -08:00
PatR
e09bfeb8af remove another unused variable 2020-02-09 12:28:19 -08:00
nhmall
bea4fb9166 remove an unused variable 2020-02-09 15:21:35 -05:00
nhmall
2ed0270e7e Merge branch 'NetHack-3.7' of https://rodney.nethack.org:20040/git/NHsource into NetHack-3.7 2020-02-09 14:57:15 -05:00
nhmall
c7c0c87859 move status condition field selection to its own menu 2020-02-09 14:56:37 -05:00
Pasi Kallinen
6fd51c29ef Unify Bag of Holding item loss chance 2020-02-09 18:39:46 +02:00
Pasi Kallinen
39032d2fac Fix the selection param unify 2020-02-09 14:47:41 +02:00
Pasi Kallinen
e182ff428b Unify lua setting wallprop 2020-02-09 14:30:11 +02:00
Pasi Kallinen
ced327fdf5 Unify some exported lua script params 2020-02-09 13:44:04 +02:00
nhmall
5e0c668e83 set g.opt_need_redraw on ingame cond_foo change 2020-02-08 21:38:14 -05:00
nhmall
4d42d44c02 catch-up on some updates to fixes37.0
Side note: Here's a correction for the commit
message for 330287da42:

The original incorrectly stated 'CONDITION_SIZE' (which
doesn't exist) instead of CONDITION_COUNT in one of the
paragraphs.

--- snip ---

eliminate the uses of the manually maintained BL_MASK_BITS

Use CONDITION_COUNT which does not require manual updating.

Also attempts to adjust win32 graphics window port for
the new fields.

That port has its own field names and should be adjusted
to using the following which are declared extern in
include/botl.h.

   struct conditions[CONDITION_COUNT];
   int cond_idx[CONDITION_COUNT];

The former contains the fields that were port-specifically
added to the win32 graphical port and more, plus it is
centrally maintained and currently utilized by tty and curses.

The cond_idx[] array contains the ranked ordering of the
condition fields from highest ranking to lowest. Instead
of indexing like this:
    int i;
    for (i = 0; i < CONDITION_COUNT; ++i) {
        ...conditons[i].enabled;
        ...condtions[i].text[0];
    }

you can use the ranked ordering like this:
    int i, ci;
    for (i = 0; i < CONDITION_COUNT; ++i) {
        ci = cond_idx[i];
        ...conditons[ci].enabled;
        ...condtions[ci].text[0];
    }
2020-02-08 21:07:04 -05:00
nhmall
330287da42 Merge branch 'NetHack-3.7' of https://rodney.nethack.org:20040/git/NHsource into NetHack-3.7 2020-02-08 20:51:10 -05:00
nhmall
2da95e4dc0 eliminate the uses of the manually maintained BL_MASK_BITS
Use CONDITION_SIZE which does not require manual updating.

Also attempts to adjust win32 graphics window port for
the new fields.

That port has its own field names and should be adjusted
to using the following which are declared extern in
include/botl.h.

   struct conditions[CONDITION_COUNT];
   int cond_idx[CONDITION_COUNT];

The former contains the fields that were port-specifically
added to the win32 graphical port and more, plus it is
centrally maintained and currently utilized by tty and curses.

The cond_idx[] array contains the ranked ordering of the
condition fields from highest ranking to lowest. Instead
of indexing like this:
	int i;
	for (i = 0; i < CONDITION_COUNT; ++i) {
	    ...conditons[i].enabled;
 	    ...condtions[i].text[0];
	}

you can use the ranked ordering like this:
	int i, ci;
	for (i = 0; i < CONDITION_COUNT; ++i) {
	    ci = cond_idx[i];
	    ...conditons[ci].enabled;
 	    ...condtions[ci].text[0];
	}
2020-02-08 20:40:38 -05:00
PatR
e198150ad8 more level teleport feedback
Level teleporting to current level doesn't give any feedback but
is usually done intentionally to abort the level teleport.  Being
on the bottom level of branch and attempting to teleport even lower
failed silently like choosing the current level.  Have it give some
feedback about not being able to go any lower.
2020-02-08 17:15:18 -08:00
nhmall
4096ce8454 Merge branch 'NetHack-3.7' of https://rodney.nethack.org:20040/git/NHsource into NetHack-3.7 2020-02-08 19:52:22 -05:00
nhmall
67cc0183b0 ranking of new status conditions 2020-02-08 19:51:04 -05:00