The most-current macOS version is greater than 12 (15 at time of
this change).
Expand Windows suggestions to include variations specific to MSYS2 and WSL2.
I can't post comments to github but can commit something that will
result in an update of the issue. Hopefully you'll see the commit.
Issue reported by RetepV: using the Macbook option key as an alt
key and using that as a shift with a regular key does not generate
a meta key value for the regular key.
This behavior is not new. I see the same thing on OSX 10.11.6.
The curses interface calls meta(,TRUE) and <option>+key produces
M-key as intended with it. The tty interface can't use that, even
when nethack is linked against a curses library which contains it.
But it should be possible to reproduce the functionality, at least
for some of the paths through the confusing conditional mazes in
sys/share/unixtty.c and win/tty/termcap.c.
However, my attempts to do that have been unsuccessful. Fetching
and sending the termcap 'mm' sequence ('smm' for terminfo) wasn't
enough, tinkering with the internal terminal settings wasn't enough,
nor combining the two. I'm not a UNIX guru so the internals part
was guesswork. And after trying to look at the ncurses source code
in bafflement I've thrown up my hands and given up.
But all is not lost. NetHack's 'altmeta' option can be used to
simulate meta keys. It's intended to support terminals that transmit
<esc> X when you type <alt>+X. But it also allows manually typing
<esc> X (as two separate keys rather than as a shift) when nethack
is waiting for a command. They will be combined into M-X. It works
when positioning the cursor too, so that when using number_pad you
can use <esc> <digit> to move the cursor multiple spots at a time.
'altmeta' deliberately doesn't work when assigning names to objects
or making wishes or various other text entry situations, nor in menus
where <esc> works in the usual way. A potential gotcha is that if
you type <esc> when nethack is waiting for a command, the game will
just sit there until you type another key. That can be another <esc>
since <esc> <esc> is converted into plain <esc> rather than M-<esc>.
Reported by ars3niy, the curses interface could behave strangely on
the first turn if the 'pauper' option/conduct was specified.
There isn't any definitive flag indicating whether or not the game
has started. Since 'moves' has traditionally been initialized to 1
rather than to 0, there were several instances of
| if (moves <= 1 && invent != NULL)
being used to determine the starting state on the assumption that
once hero has inventory, the game has begun. Introduction of the
'pauper' option made the test for non-Null invent become unreliable.
For paupers, the program would behave as if the game hadn't started
yet until the player finally made a time-consuming move.
This changes compile-time initialization of 'moves' from 1 to 0,
then sets it to 1 when initial inventory would be bestowed (even
when 'pauper' inhibits that). That's probably not the best place
for it, but testing for 'moves==0' now should produce an identical
effect as 'moves<=1 && invent!=NULL' used to accomplish.
It would have been much simpler just to give paupers 1 gold piece,
or perhaps one rock, in place of usual starting gear so that their
initial inventory wouldn't be empty, but the moves+invent way of
checking for start-of-play has always bothered me.
Should 'pauper' be preventing 'nethack -X' from giving its starting
wand of wishing? Conducts and explore mode don't really overlap so
maybe it doesn't matter.
Fixes#1275
I normally force DECgraphics for tty and for curses so hadn't noticed
this before. I recently let curses default to 'cursesgraphics' and the
engraving-in-room character was crossed horizontal and vertical bars,
the crosswall character. It certainly stood out in the middle of a
room, but the emphasis seems out of proportion for "engraving here".
There is no 'epsilon' among the DEC line drawing characters. Curses
might be able to render one, but not with DEC-style rendering of 0xEE.
Comment out S_engroom so that curses inherits the default backtick.
The old secret door detection just redisplayed locations with
discoveries (secret doors and traps, mostly). Somewhere along the
line it was augmented to find hidden monsters and to deliver one or
two messages reporting how many things had been discovered. Now it
has been augmented again, to find trapped doors and chests, and to
supply a message when the detection attempt fails to find anything.
More substantially, it highlights the relevant locations as they're
found, before the feedback message(s).
Initially I was using tmp_at() to mark all significant locations,
but that required --More-- and for player to acknowledge it when
detection was done. That would probably be ok for wand of secret
door detection and spell of detect unseen, but it would be a hassle
for ^E. It's been revised to use flash_glyph_at() [previously only
used when ^G creates unseen monsters, I think].
The new behavior seems to be working reasonably well. For curses,
the 'timed_delay' option must be set. flash_glyph_at() calls
flush_screen() between its output and nap in each cycle of multiple
flashes, but that evidently isn't sufficient for curses. Maybe
curses init should just force on 'timed_delay'.
I've left the tmp_at() stuff in. We might want to modify things to
use it instead of flash_glyph_at() when the accessibility flag is
set. Its current compile-time selection won't be adequate though.
do_clear_area() runs a callback over each point in a square around
a center point. When executed near the edge of the map, it clips
the square to avoid going over that edge. But on the left side,
it was clipping to column 0 rather than 1, so running the callback
routine on column 0 even though that isn't part of the level. This
bug doesn't seem to have caused any problems though.
magic_map_background() would overwrite remembered objects and traps.
That meant discovery of secret corridors by secret door detection
or ^E would forget embedded objects at their locations.
^E and wand of secret door detection used to just update the map
without any other feedback, but were changed post-3.6 to issue a
message about what things are being discovered. But the message is
misleading if [some of] the things revealed are obscured by objects
or by monsters. Presumeably by regions too.
If player uses the 'm' prefix before the #vanquished command when
the vanquished monsters list has fewer than two types so far,
select the preferred sort for #vanquished even though it won't be
applicable yet.
Also, when prompting about vanquished monsters during end of game
disclosure, where an 'a' response is given special meaning, use
"[ynq]" instead of "[ynaq]" if there is only one type of monster
vanquished. It's skipped altogether when the list has zero types
and there's no point in picking sort order when there is just one
type. The player can still answer with 'a' when [ynq] doesn't show
that (for tty and curses at least, probably X11); 'a' will end up
behaving as 'y' in that case.
Explicitly sort and label Riders before major demons when displaying
vanquished monsters with sort-by-class. They're lumped in with '&'
but they aren't really demons.
Instead of
" a-z and
" A-Z and
" @&':;
for the lists of characters used to show monsters, followed by
" I
for special "remembered, unseen monster", change the capital letter
line
" a-z and
" A-HJ-Z and
" @&':;
to emphasize that 'I' is used differently from other letters.
Also, add the trailing "and"s to the LaTeX version. I haven't seen
what the result looks like.
When looking at a monster that's inside a gas cloud, include that
fact in the output for farlook and for probing. When the monster
being examined is sensed rather than seen, you'll sense the presense
of the cloud as well as the monster even if the cloud can't be seen.
Do likewise for self when using look-here (':'). Bonus fix: zapping
wand of probing at self while engulfed reported that you were just
held by the engulfer.
Also fix an old comment typo/thinko.
Support tab separation for the region portion of #timeout output.
This works ok under Qt. However, the output from #timeout uses a
fixed-width font so tab separation isn't necessary.
No idea how well it will work for mswin.
Some_Monnam() returns "Someone" or "Something", not "Someone" or "It".
Removing the redundant '&& uchain != NULL' test shouldn't produce any
change in behavior.
Testing the shopkeeper speed change, I noticed that zapping the shk
with speed monster made her angry. Since being hasted is beneficial
for the target, don't become angry.
Issue reported by ars3niy: a hasted shopkeeper always gets 2 moves
per turn and had a tendency to move away from the door and then move
right back, keeping it blocked.
I didn't view the ttyrec and didn't reproduce the situation, but I
have noticed something of the sort in the past. This reduces shk
speed so that there will usually be 2 moves per turn but not always,
increasing the likelihood of leaving the door unblocked when nearby
hero does not owe anything.
This change results in a slowed shopkeeper having speed dropped to 11
rather than 12. I suspect that the original 18 speed might have been
picked to guarantee slowed speed of at least 12, but if so, that was
in the days when speed 11 would have provided 11 consecutive moves
and then a turn guaranteed to not allow a move rather than the current
11 out of 12 chance to move each turn.
Fixes#1267
Allow farlook/quicklook to step through all engravings--corridor
ones as well as room ones--with repeated '`' when picking location
with getpos(), similar to how repeated '^' goes through all traps
no matter what display character they use.
It isn't possible to look at corridor engravings by using their
default symbol '#'. It is possible by using 'a' for "anything of
interest" but that matches lots of other stuff.
This tries to add an NHDT tags line to sym.h. That was followed by
'git nhadd' which did stage it for commit, but date/branch/revision
tag expansion isn't working. I did something similar to defsym.h
about 5 weeks ago; that one worked and I don't recall having needed
to do anything special.
From a change made about two and half months ago: eating a pyrolisk
egg tried to use it up from inventory even when it was on the floor.
That would trigger an object lost panic.
When hero was swallowed and a temporary region at swallower's spot
expired, hero was told "the gas cloud around you dissipates". This
just suppresses the message rather than changing it into "the gas
cloud around <engulfer> dissipates".
Various bits tried while flailing about with map display of monsters
in visible regions. The newsym()/mon_overrides_region() part is
definitely an improvement because the logic about whether to show a
monster in a region or just the region wasn't easy to comprehend and
was even harder to extend.
I'm not sure whether the _map_location() part is necessary.
This fixes the bug where a monster displayed instead of a gas cloud
because the hero was next to it didn't revert to gas cloud when hero
moved and was no longer next to the monster.
It is possible to have a known trap be at the same location as a gas
cloud region. When paranoid_confirm:trap is set, ask for confirmation
about entering the region before confirmation about entering the trap
since the map will be showing the region rather than the trap.
Dual confirmations will be annoying but not new. Before this change,
it would ask about entering the trap, and if the answer was yes, it
would ask about entering the region. The situation seems to be too
rare to warrant implementing a single combined confirmation, and the
code to accomplish that would likely be messy.
Show visible regions among the other timed events. Turn number is
relative rather than absolute. Location is the internal bounding box
which tends to cover more area than just the gas cloud spots.
When multiple regions are present (common on Plane of Fire), they're
listed in arbitrary order. It would be better to order them by
timeout or by location or both, but the extra effort to do that seems
unjustified.
Extend paranoid_confirm:trap to also ask for confirmation when
attempting to enter a gas cloud region (scroll of stinking cloud,
breath from green dragons or iron golems, steam clouds from boiling
water, vapor left by fog cloud movement, no doubt several others).
Like with traps, can be overridden for a given move by using the
'm' prefix. Unlike traps, doesn't try to guess whether moving into
a region will be harmless.
Doesn't affect movement into cloud terrain (Plane of Air).
Update the Guidebook to describe the revised behavior of
paranoid_confirm:trap and to mention how #terrain deals with regions.
'any_visible_region()' got mixed in with this but isn't used yet.
Affects extern.h and region.c.
While trying to track down a display problem with regions
[when a monster is shown over a region because the hero is
adjacent, it doesn't revert to the region's cloud glyph when
hero moves farther away; that's not resolved yet],
I discovered a different display problem for the same thing. If
you pick a #terrain choice that keeps traps it is supposed to show
region spots too, but that didn't work when there was a monster at
the same spot. It removed the monster but showed background there.
A recent change was setting mon->data prior to canspotmon(mon) but
that triggered a crash if the temporary mon->data was Null. All the
testing was done with vampshifers and this affects non-vampshifers.
Push even more shapechange messaging into newcham() by not trying to
determine whether requesting a message from it will oblige.