Commit Graph

835 Commits

Author SHA1 Message Date
Pasi Kallinen
16ed7e49c3 Separate level flags for premapped and sokoban 2023-10-29 12:35:32 +02:00
PatR
8e37ea26d8 another data.base bit
Change the stalker entry attribution of "H. G. Wells" to "H.G. Wells"
to match the other attributions.  There was once a mixture of both
styles but at some point all the ones with the expected--and possibly
stylistically preferred--extra space got changed to the condensed form.

The sasquatch quote still contains "J. W. Burns", in the text rather
than in an attribution.  I wasn't sure whether it should be changed
so left it alone.  Presumably the source of the quote had that space.
2023-10-21 16:52:09 -07:00
PatR
d1c11903cf data.base entry for athame
Separate the old generic text for athame from the new quote with an
empty attribution line.  Reformat both the old and new portions so
that they won't their widths won't be so different from each other.
2023-10-17 00:04:30 -07:00
PatR
9021aa9ec0 minor data.base cleanup
The new entry for 'shade' had "acrossthe" run together on the first
line.  While fixing that, I changed that entry to use two-space
separation between sentences and did the same for 'shield'.

I also made indentation for various attribution lines (new necessarily
new ones) be more consistent (two tabs, for for the data file format
and one for indentation, unless the line is wide-enough to warrant
shrinking the second tab) but burned out before getting very far with
that.  Also removed line split between "Dante" and "Alighieri" in a
couple of places.  Shouldn't split a name unless other alternatives
are worse...
2023-10-16 16:50:29 -07:00
PatR
006d97e5c8 github pull request #1108 - new data.base entries
Pull request from NullCGT:  a lot of new data.base entries.  Over 20
separate commits; this time I didn't squash them together because I
didn't want to mess with their log messages.

Three had non-ascii characters where apostrophe or single-quote or
long dash are intended.  _The_Invisible_Man_ for stalker was the worst
offender.  While fixing those, I changed period followed by single
space when separating sentences to period followed by two spaces but
didn't do that for the other new entires.  A few had trailing spaces and
one existing entry had trailing tabs.  I've fixed up those situations.

The ice box quote is out of whack with everything else due to wider
lines but the capitalization indicates that it's from a poem that was
formatted that way.  I left it as is instead of splitting several of
the lines.

The conical hat entry is iffy since nethack's conical hat is not a
wide-brimmed witch's hat, but I've left it in.  Likewise helm of
brilliance says that it's made of steel but nethack's is now crystal.

Closes #1108
2023-10-15 01:39:40 -07:00
Kestrel Gregorich-Trevor
502c66f5e3 Add encyclopedia entry for helm of brilliance. 2023-10-15 00:07:42 -07:00
Kestrel Gregorich-Trevor
83344e7568 Add encyclopedia entry for pointy hats. 2023-10-15 00:07:42 -07:00
Kestrel Gregorich-Trevor
1fa0da3948 Match "large rock" for rock encyclopedia entry. 2023-10-15 00:07:41 -07:00
Kestrel Gregorich-Trevor
629e3371b7 Add database entry for white-handed shield. 2023-10-15 00:07:41 -07:00
Kestrel Gregorich-Trevor
ad49757553 Add Demonbane encyclopedia entry. 2023-10-15 00:07:41 -07:00
Kestrel Gregorich-Trevor
820432da08 Replace shade encyclopedia entry.
Sourced from xnethack. Seems like an excellent candidate for
replacement, since the quote gets across what shades are and also
hints at their weakness.
2023-10-15 00:07:40 -07:00
Kestrel Gregorich-Trevor
1a5b0851fc Scroll of punishment encyclopedia entry.
Sourced from xnethack. Added a line so that it will match "punished"
as well as "punishing."
2023-10-15 00:07:40 -07:00
Kestrel Gregorich-Trevor
1ebf96d94e Ensure potion of hallucination matches encyclopedia. 2023-10-15 00:07:40 -07:00
Kestrel Gregorich-Trevor
cdf9e7563c Add hallucination encylopedia entry.
Sourced from xnethack.
2023-10-15 00:07:40 -07:00
Kestrel Gregorich-Trevor
9b899c3eca Add fruit/fruitname encyclopedia entry.
Sourced from xnethack.
2023-10-15 00:07:40 -07:00
Kestrel Gregorich-Trevor
7a61a454d0 Add fortune cookie encyclopedia entry.
Sourced from xnethack.
2023-10-15 00:07:39 -07:00
Kestrel Gregorich-Trevor
da5283174d Add dwarvish cloak encyclopedia entry.
Sourced from xnethack.
2023-10-15 00:07:39 -07:00
Kestrel Gregorich-Trevor
236dff24f4 Added dented pot encyclopedia entry.
Sourced from xnethack.
2023-10-15 00:07:39 -07:00
Kestrel Gregorich-Trevor
69fb0b5e65 Add athame quotation.
Sourced from xnethack.
2023-10-15 00:07:39 -07:00
Kestrel Gregorich-Trevor
4dbb930be0 Add fortune cookie quotation.
Sourced from xnethack.
2023-10-15 00:07:38 -07:00
Kestrel Gregorich-Trevor
a138080b33 Remove unneeded engraved bell encyclopedia entry. 2023-10-15 00:07:38 -07:00
Kestrel Gregorich-Trevor
1efdc9fd93 Return strange object entry for strange and glorkum.
If the player is looking up a glorkum in the encyclopedia then
there are probably larger problems at play than a missing encyclopedia
entry.
2023-10-15 00:07:38 -07:00
Kestrel Gregorich-Trevor
9676352cf1 Rectify typo in shield database entry. 2023-10-15 00:07:38 -07:00
Kestrel Gregorich-Trevor
babd9d50cb Encyclopedia: Bells, credit cards, and stalkers.
Replace the encyclopedia entries for bells, credit cards, and
stalkers with those suggested by aosdict. Sourced from xnethack.
2023-10-15 00:07:37 -07:00
Kestrel Gregorich-Trevor
b0a83bbee3 Encyclopedia Entry: Ice Box. 2023-10-15 00:07:37 -07:00
Kestrel Gregorich-Trevor
f5bd695017 Add missing database entries.
This commit adds entries for the following items:
    - Credit card
    - Silver bell
    - Bell
    - Walking shoes
    - Iron shoes
    - Hard shoes
    - Dragonbane
    - Gauntlets of Power
    - Gauntlets of Fumbling
    - Gauntlets of Dexterity
    - Potion of Sickness
    - Splashes of Venom (Various)
    - Shields (Various)

The following monsters also now have associated entries:
    - Stalker
2023-10-15 00:07:37 -07:00
Pasi Kallinen
38546778d5 Bigroom 3 may have some walls replaced with other terrain 2023-10-06 12:07:07 +03:00
PatR
7c0ece5bd6 fix #H2736 - missing Samurai quest throne
Reported 11 years ago, the level definition for the Samurai quest
home level specifies a throne room and entering it gives the "opulent
throne room" message, but there isn't any throne.

Initially I was going to add a throne but decided that its lack is
probably intentional.  The throne room designation is used to give
periodic atomspheric messages.  That's my guess anyway.

Alter the room entry message there to omit "throne" from "you enter
an opulent throne room".  Add a no-throne comment to Sam-strt level
definition.

While in there, make Lord Sato's katana and splint mail explicitly
rustproof and either blessed or uncursed.  (The mail was already
implicitly rustproof because splint mail created on the Sam quest
home level always is, like for a Samurai's initial inventory.)
2023-09-28 13:25:20 -07:00
PatR
1a64ee1c28 github PR #259 - paranoid_confirmation:trap
Fairly old pull request from copperwater:  add new paranoid_confirm
setting 'trap'.

The old commit suffered from bit rot and merging needed too much
fixing up despite there not being many bands of change in the commit's
diffs.  I ultimately redid it from scratch, although the two biggest
chunks of code started with copy+paste of the pull request's commit.

It operates like paranoid:pray.  Setting paranoid:trap adds a new
"Really step into <trap>?" y/n prompt when attempting to move
into/onto a known trap, even if an object covers it on the map.
Setting both 'paranoid:Confirm trap' turns that into a yes/no prompt.
(Adding 'Confirm' affects other paranoid confirmations; in addition
to requiring yes<return> rather than just y to accept, it also forces
no<return> to reject.)

However, moving into a known trap that is considered to be harmless
behaves as if no trap was present.  Some of the trap classification
might be out of date; several types of traps have undergone changes
since implementation of the original pull request, notably anti-magic
field.  When the hero is hallucinating, all known traps are considered
harmful since the map no longer reliably describes them.

Preceding a movement command with the 'm' prefix also behaves as if
no trap was present, bypassing confirmation for that move, similar to
how paranoid:swim currently behaves.  Being stunned or confused also
behaves as if no trap was present, taking priority over hallucination.

This updates the documentation.

Supersedes #259
Closes #259
2023-09-08 15:55:31 -07:00
PatR
67513c96bb options help
Update the 'optmenu' data file to describe the simple options menu
(new paragraph containing just a one sentence) as well as the full
options menu (still several paragraphs).  Visible by choosing '?' in
the full options menu or the 'how to set options' choice in the main
help menu.

Add a line to the simple options menu about how to get the full
options menu.  Only shown if you type '?' to toggle on "show help";
taken away again if you use '?' to toggle back to "hide help".
2023-08-31 14:58:51 -07:00
Pasi Kallinen
e407af4477 Allow defining random-teleport exclusion zones in lua
Adds a new lua command

  des.exclusion({ type = "teleport", region = { x1,y1, x2,y2 } });

which allows defining "exclusion zones" in the level, areas where
random teleports (or falling into the level) will never place the hero.
Does not prevent targeted teleportation into the area.

Breaks saves and bones.
2023-08-24 18:38:39 +03:00
nhkeni
9ba47555c9 Merge remote-tracking branch 'origin/keni-versioncopy' into NetHack-3.7 2023-08-15 09:33:59 -04:00
PatR
c155d23823 data.base entry for stethoscope
I was going to add a joke entry for "microscope" to data.base and
disocovered that stethoscope was missing.  (There is a rumor about
cursed ones.)  Add a lame entry for it so that the joke has something
to relate to.

Searching for "stethoscope" led to the "cope" comment, which is near
the "cornuthaum" entry.  Add a comment giving Janet credit for coining
the term.
2023-08-11 15:57:27 -07:00
nhkeni
1663ecf85d Add --version:copy, deprecate --version:paste. 2023-08-03 21:51:25 -04:00
PatR
085594ac04 more PR #1051, take II
I realized that the previous attempt was misusing the item's locked
state when attempting to create the chest that the item would go into,
which was absurd.  I hadn't realized that I was also misspelling
"olocked" as "locked".

This fix was already in progress before the mail about the previous
commit.  I did try switching to 'lckd = nil' for the attempt to retain
the chest's random locked/unlocked state but that resulted in all the
chests being created locked.  Using separate box=... expressions does
work as intended.  Doing something with totable() doesn't seem to be
necessary.

The indentation seems to be messed up compared to the rest of the
file (initial indent of 5 with increments of 4 rather than 3 and 3);
I have't done anything to try to fix it.
2023-07-21 23:09:39 -07:00
PatR
d99b549bb0 more PR #1051 - water-vault escape item
When generating an "escape item" inside one of the chests in the
"water-surrounded vault" theme room, make sure that the chest is not
locked if the item is made of glass or crystal.  Otherwise kicking the
chest to get access to its contents might destroy the item.

I imagine that this could be done more cleanly, but after quite a bit
of thrashing about I have something which seems to work.  To test, I
temporarily modified object shuffling to force wand of digging to be
made out of crystal and gave the water-vault a very high generation
frequency.
2023-07-21 15:00:54 -07:00
Michael Meyer
95b410ee94 Provide escape item in water-surrounded vaults
Water vaults are one of the few places that can/will generate completely
sealed off in a normal level.  Other such spots are designed to provide
a guaranteed means of escape (vault guard, scrolls of teleportation in
niches, etc) -- water vaults were an exception that didn't do this, so a
hero who fell into one from above could have ended up in a position
where she had no choice but to wait to starve to death or #quit. Provide
an escape item in one of the vault's chests to give a hero more options
in that position.

Also fix a minor mistake (I'm pretty sure, though I'm not a Lua expert
enough to be certain) in an nhlib.c comment describing how to use
obj.addcontent() -- when called as box.addcontent(contents) as the
comment suggested it produces an error, but works OK when called as
box:addcontent(contents) or obj.addcontent(box, contents).
2023-07-07 09:42:43 -07:00
Kufat
66d0c47951 Add true rumor re. intrinsics/extrinsics
Some extrinsics (telepathy, speed) are more powerful than their intrinsic versions.
2023-07-04 22:09:20 -07:00
PatR
b1d30fbce9 address github issue #303 - paranoid_confirm:pray
An issue from nearly three years ago, reported by Anerag:  asking
player whether to really pray isn't paranoid enough because it
accepts 'y' rather than requring "yes".

This changes it to require "yes" followed by <return> or <enter> if
paranoid_confirm:Confirm is also set.  (A side-effect of that is
explicit "no<return|enter>" is required instead of just 'n' to
decline--for all the paranoid confirmations, not just for prayer.)
This extension of paranoid:Confirm applies to paranoid:AutoAll too.

A comment asks why paranoid_confirm:pray is different from the other
paranoid questions in the first place.  The answer is that when it
isn't set, no confirmation prompt is issued at all.  The others all
have y/n confirmation prompts when the corresponding paranoid option
isn't set.

Once upon a time there was a boolean option called 'prayconfirm' that
issued "really pray?" prompt when True.  It was added after players
whinged about typing Alt+p when they meant to type Alt+o.  When the
more advanced 'paranoid_confirmation' was introduced, paranoid:pray
superseded prayconfirm, but it still only issues a confirmation
prompt where there normally wouldn't be one rather than change an
existing one to require "yes<return|enter>" instead of 'y'.

Closes #303
2023-06-24 16:12:54 -07:00
PatR
0cd337c78b address issue #1065 - Auto-select every item
Issue most recently reported by Xdminsy (previously reported by
others):  it is too easy to accidentally pick choice 'A' in object
class selection menus for menustyle:Full.  Previous change relevant
to this was to exclude choices 'A' and 'a' from being set by '.'
(choose all entries) and '~' (toggle all entries).  That was an
improvement but doesn't help with pressing shift when meaning to
type 'a' by those who type faster than they cogitate.

This implements a suggestion by janne-hmp:  add new choice for the
paranoid_confirmation option, 'Autoall' (synonym 'Autoselect-all').
If the player sets this and includes 'A' among the choices for
class selection, prompt to confirm whether to honor it.  Like
confirmation for praying, it adds an extra y/n prompt rather than
change an existing y/n prompt into a yes/n or yes/no one.  If the
player declines, then nothing is selected and the operation is
cancelled rather than putting the menu back up to choose again.

OPTIONS=paranoid_confirm:autoall requires at least two letters
('au') even if the 'a' is capitalized.  paranoid_confirm:a means
confirm attacking peaceful monsters.  And it should be
OPTIONS=paranoid_confirm:autoall pray swim
if someone just wants to add autoall to the default paranoid bits.

The Guidebook hasn't been updated to describe the new choice since
it seems likely that it might undergo adjustments.

Closes #1065
2023-06-24 01:15:44 -07:00
PatR
cd9f145dba fix leaving the tutorial levels
While running the tutorial, the Save command is disabled.  When the
tutorial was extended to two levels, stashing and restoring the
hero's equipment stopped working as intended if player entered the
second level.  The attempted fix for that broke re-enabling Save
even if the player left the tutorial without entering its second
level.

This seems to fix things, but I'm flailing around with barely a clue
here.  A couple of simpler attempts didn't work and I haven't figured
out why, so this is a bit more complex than what I wanted.

Reorganizing nhl_callback() isn't part of the fix, just avoids use
of some redundant code.
2023-06-23 15:19:36 -07:00
PatR
8fd8d1defa Mitre of Holiness
If the priest quest artifact Mitre of Holiness (a helm of brilliance,
so crystal helmet) is acquired via the quest (rather than by wishing)
make it start out tempered (aka crackproof|erodeproof).
2023-06-17 13:27:40 -07:00
PatR
c4c31ae6a8 fix issue #1025 - stuck in Mines' End
Issue reported by AndrioCelos:  if you arrived at the Wine Cellar
variation of Mines' End by falling or by level teleportion instead
of via the stairs, you could end up in the treasure chamber.  If
you lacked a way to dig or to level teleport, you would be stuck.
Since most of that level is undiggable, it would likely fill up with
monsters before one that could dig would appear close enough to dig
to you and you'd eventually starve.

The initial report suggested including an escape item in the treasure
chamber.  This adds a teleport region to control hero's arrival spot
instead.  There was a suggestion fix things this way from copperwater
but I didn't notice that until I had already chosen this method....

Fixes #1025
2023-06-10 01:49:55 -07:00
PatR
e475dca209 add 'montelecontrol' option (wizard-mode only)
Add a new debugging option, 'montelecontrol', that allows a wizard-
mode player to choose a teleporting monster's destination.  If player
picks a bad spot, confirmation will be requested.  If accepted, the
spot will be used even though the consequences could be bad; that's
on the player.  If rejected, the destination will be assigned as if
no control had been attempted rather than try again.

The fuzzer isn't allowed to override a bad spot if it tries to pick
one.  That would probably trigger a sanity_check warning; the fuzzer
causes impossible warnings to behave as if panic, so accepting a bad
spot would just be fuzzer suicide.  It is allowed to randomly set the
option and maybe--though extremely unlikely--randomly pick a valid
controlled destination.
2023-06-09 00:56:53 -07:00
PatR
a5a11c19c9 update data.base 'cat' entry
The first paragraph for cat/feline is obviously not from Lovecraft, so
insert an entry attribution line between it and the second paragraph.
2023-06-05 13:58:45 -07:00
PatR
2bbfed2183 fix github issue #1046 - tutorial anomalies
Reported by Noisytoot:  going from level tut-1 to tut-2 returned the
hero's starting equipment too soon, and exiting the tutorial from
tut-2 let the hero keep any equipment acquired within the tutorial.

Entering and leaving the tutorial was being handled by lua code in
the level description of tut-1 and adding a second level messed that
up.  I didn't see any way of handing that with level-specific lua
code so I made it become the core's responsibility.  gotolevel()
knows when the hero is moving from one dungeon branch to another so
it can recognize entry to or exit from the tutorial easily.

While fixing this, prevent #invoke of the Eye of the Aethiopica from
offering the tutorial as a candidate destination (was feasible if it
had been entered at start of game).

Not fixed:  levels visited in the tutorial become part of #overview.

Show location as "Tutorial:1" instead of "Dlvl:1" on status lines.
Only tested with tty; some interfaces handle location themselves and
may need their own fixup for this.

Fixes #1046
2023-06-03 16:39:12 -07:00
PatR
0a16638fe4 data.base entry for "combat"
16 years ago the "combat" entry got inserted in between a comment and
the "cope" entry, making the comment end up being out of place.  Move
that and add a bit more detail.
2023-05-29 05:09:21 -07:00
PatR
1851c7ca88 update Medusa's data.base entry
The second paragraph about Medusa is an excerpt from Bulfinch's
Mythology, but first paragraph is not.  Insert an empty attribution
line between them.  Also, remove the reference to Graeae from the
introduction since it contradicts Bulfinch, which describes them as
"three sisters who were gray-haired from their birth" and Gorgons as
"monstrous females with huge teeth, brazen claws, and snaky hair".
2023-05-13 11:23:49 -07:00
PatR
7a18387ff2 Fix github issue #1016 - buried zombie theme room
Reported by vultur-cadens:  it was possible to encounter ettin zombies
and giant zombies at shallow levels if those levels were generated
with the "buried zombies" theme room.

This uses a simpler fix than the suggestion(s); it's only applicable
to the zombie room though.

Also, vary the zombify_mon timeout.  If the hero happened to be in
the room at the time that that expired, they would all claw their way
out of the ground at once.  The new variation is quite small so they
still escape burial as a group, but over the span of 21 turns rather
than all on one turn.

Fixes #1016
2023-05-01 15:37:30 -07:00
Pasi Kallinen
8a85f1d92c Fix minetn-6 map generation errors
Two error cases with the map generation in minetn-6:

first one was the lregion placement impossible, caused by randomly
generated mines not going past the map either left or right, and
the stair generation being restricted outside the fixed map.

second was one side of the map being unreachable, because the
mines layout joined to the other side right at the edge of map
behind the small room with the "x" mapchars.
2023-04-22 19:05:45 +03:00