Bumping into an unseen wall reported "a wall" instead of "solid stone",
even though you could not know it was a wall when looking at it.
Use the same method when looking at glyphs on the map instead of
the map location type.
Fixes#318
For the grid of extended commands used to pick one after typing "#",
show a command's description if the mouse hovers over its button.
For once something with Qt was actually easy.
I accidentally swapped the covetous monsters teleport to stairs to heal
but instead of changing it back like it was, now make those monsters
teleport to either upstairs or downstairs - some of them will go up,
others go down.
... you will also get a message when a seen stinking cloud
or the one surrounding the hero dissipates.
Original feature comes from Fourk, but this version (with some
minor changes) comes from xnethack by copperwater <aosdict@gmail.com>
nethack 3.0, nethack 2.2, and hack 1.0 did not use a three component
version numbering scheme so their corresponding fixes files shouldn't
do so either. Change those from fixesX-Y-0.txt to fixesX-Y--.txt.
git has me really confused right now, first requiring a merge, then
not needing any merge. Anyway, add pull request #624 which was
unintentinoally closed and then couldn't re-opened. Now it's been
incorporated so is intentionally closed.
Closes#624
Makefile.mingw32 and Makefile.mingw32.depend are intended to replace
Makefile.gcc.
To use them:
cd /d/prj/NetHack/src
cp ../sys/windows/Makefile.mingw32* .
mingw32-make -f Makefile.mingw32 clean
mingw32-make -f Makefile.mingw32 depend
mingw32-make -f Makefile.mingw32
Improvements:
Add $(USE_LUADLL) to release lua-5.4.3.dll, instead of link static
lua.lib into .exe files.
Add windres "--target" option, to fix the NetHackW.exe startup problem.
Add "-s" option to $(LDFLAGS) in release mode, to make exe/dll smaller.
Add $(CLEAN_DIR) and $(CLEAN_FILE) to track what to clean.
Remove *.tag, but use "order-only prerequisites" to make directory
before any '.o' is built.
Use make variables and functions to improve readability.
Each project has its own directory to hold object files, to fix the
interference problem between different projects, like NetHack.exe object
files were built with "-DTILES".
Add "-mconsole" option when linking NetHack.exe, to fix that sometimes
GetStdHandle returned with invalid handle error.
Add ".PHONY" statements.
Use "gcc -E -MM -MT" to implement semi-auto "Prerequisites Generating".
The stop_row and stop_col were off-by-one in some cases, leaving
black lines on the map when a window on top was closed.
Simplify the calculation by always going one row/col further,
ensuring previously covered area gets redrawn for sure.
This should not affect speed or resource usage noticeably these days.
The priest/cleric quest provides unlimited wraiths and a player
(not a robot with limitless patience) posting on reddit gave up
building up his character by killing them and eating the corpses
after accumulating 40K HP and 20K En. (Or something close to that;
I can't get back to the post right now.) His character might have
been capable of surviving decapitation or bisection.
Make it very much harder to get to 5 digits of HP or En via level
gains after reaching level 30. If maxhp < 300, new gains will be
capped at 5 extra HP; 300..599, cap is 4; 600..899, cap is 3;
900..1199, cap is 2; and once 1200 is reached, further level gains
will only add 1 HP. For maxen < 200, extra En is capped at 4;
200..399, cap is 3; 400..599, cap is 2; and once 600 is reached,
further gains only add 1 En. Note: this only kicks in when gaining
levels while already at level 30.
The extended command input prompt was behaving in an unintended way:
Typing #a<enter> executed #adjust. Spaces in the entry prevented matching
any command. No error message was given when no command was matched.
Fix all of those, so it behaves more like the tty.
Clean up the tty, curses, and X11 windowport code, so they don't use
the extcmdlist array directly, but query with extcmds_match
and extcmds_getentry.
When rest_on_space is On, assign same function as for #wait to the
<space> key. When Off, set that key to Null instead. Binding some
other command to <space> when rest_on_space is Off doesn't work but
I would classify that as something to be discouraged anyway.
This fixes moving in direction '>' while wielding a pick-axe with
the 'autodig' option On. Attempting to dig assumed size-to-side
activity because u.dz wasn't being set, so the pick-axe was swung at
thin air instead making a pit or turning an existing pit into a hole.
dodown() and doup() should probably call set_move_cmd() instead of
manipulating u.dz directly. But they would also need to suppress
g.move_attempting or the game says "you can't get there from here..."
after successfully digging or plunging into a pit.
When hitting with a wielded wet towel, use "you lash <mon>" like
bullwhip. If you continue with the towel after it has dried out,
message reverts to ordinary "you hit <mon>".
Enhance damage slightly and double the wetness bonus when target
is an iron golem. Damage was (tmp=rnd(1..7), max(tmp,6)); now it's
rnd(1 + 1..7) for other monsters, rnd(1 + 2*(1..7)) for iron golem,
with no cap of 6 for either.
Sequencing: defer "your towel dries" until after the lash message.
When the hero has the Glib condition, ^X reports "you have slippery
fingers" or "you have slippery gloves" but self-probing (either wand
or stethoscope aimed at self) was reporting "you have slippery hands."
Change self-probing to match enlightenment for this.
Message shown when hero sees a monster's wet towel become less wet:
"<Mon>'s {moist|wet} towel drie[ out]." Corresponding message for
hero's towel spelled "dries" correctly.
Reported for to-be-3.7 but present since 3.6.0.
Kicking a door can produce "WHAMMM!!!". "Wham" doesn't necessarily
imply any noise but there's a strong suggestion that it does, so a
deaf hero shouldn't be able to hear it. Give alternate feedback,
"Thwack!!" when deaf, and sometimes give that even when not deaf.
Also tone down "WHAMMM!!!" to Whammm!!".
Changes most of the special keys used in the main input loop
into extended commands:
- movement keys are now bound to extended commands, eg.
#movewest and so on.
- m-prefix is now #reqmenu extended command, still bound to
the 'm' key.
- run, rush, and fight are now extended commands, still bound
to the same keys as previously.
- nopickup and runnopickup keys are removed.
Nopickup was using 'm' key, the same as the m-prefix, so
allow #reqmenu to modify movement commands to disable pickup.
- multiple prefix commands are allowed. This lets user to
use #reqmenu, followed by #run, followed by movement to simulate
runnopickup behaviour. (If necessary, adding runnopickup back
as an extended command would be easy)
and rename {roles,races}[].malenum to {roles,races}[].mnum.
Pull request #653 from entrez. Male and female player character
monsters are no long separate even when their title's differ and all
the entries for femalenum in the roles[] and races[] arrays were set
to NON_PM (meaning not used in this case).
The update in the pull request overlooked win/Qt/qt_plsel.cpp which
had four references to .malenum so this is more than just the fixes
entry.
Closes#653
Pull request #654 from entrez: the change to avoid impossible
"unpaid_cost: object wasn't on any bill" when examining inventory
while in a wall shared by multiple shops didn't work correctly for
shop-owned objects inside hero-owned containers (which worked prior
to that change).
Not fixed, and possibly not going to be: if a hero-owned container
holds items from more than one shop, the cost appended to those items'
inventory entries might show the wrong amount if the relevant code
picks the wrong shk. Presumably the wrong amount can also happen if
player puts items from one shop into a container owned by another
shop.
Closes#654
Fix the reported bug of using Passes_walls to carry an unpaid item
from inside a shop into the wall it shares with another shop
producing a situation where examining inventory issued an impossible
"unpaid_cost: object wasn't on any bill" when trying to append the
cost to the formatted inventory line. u.ushops[], u.ushops0[], and
others are lists that can have up to four entries and the relevant
code was only checking the first one.
Not mentioned in the report: continuing another step into the other
shop didn't get recognized as robbing the first shop, for a similar
reason.
For either of these bugs, digging a breach in the wall, paying off
the miffed shopkeeper, then stepping into the breach before it gets
repaired will probably trigger the same results without the need for
polymorphing into a xorn or earth elemental. But not on the tourist
goal level test case since walls there are undiggable.
I didn't go looking for other instances of not checking all relevant
shopkeepers. It wouldn't surprise me if there are some more.
Wounded_legs was changed from (HWounded_legs || EWounded_legs) to
just (HWounded_legs), but when the timeout code decremented the timer
to 0, HWounded_legs became 0 and heal_legs() operated as if there was
nothing to repair and hero didn't recover from temporarily lost Dex.
Change Wounded_legs back to (HWounded_legs || EWounded_legs).
During role/race/gender/alignment selection, when gender gets toggled
replace the gender-specific role titles and their icons to reflect
new gender value. And enable or disable Valkyrie choice depending
upon the gender value, not just current race value.
This ended up revising a lot of the NetHackQtPlayerSelector code,
eliminating some redundancies and being more careful with the use of
validrace()/validgend()/validalign(). That still isn't bulletproof.
It also changes the two instances of buttonPressed that were drawing
Qt6 warnings from connect() at run-time with buttonClicked. That
works as intended with Qt5 and might eliminate those.
The code to use female player character tiles looks correct to me
but when I toggle gender, role titles change but their icons don't.
I don't know what's going on here. Some ealier code always specifies
MALE but that code isn't used according to various prints to stderr
that I temporarily inserted.
The set-but-not-used warning for 'ret' revealed an actual bug this
time. Parsing sysconf cares whether any errors were encountered
when parsing its contents, but BINDINGS=key1:cmd1,key2:cmd2 only
returned the result of the first key in the comma-separated list
because the result from recursive calls was lost to the set-but-
not-used variable. Just adding use of that variable would have
ended up reporting success if any key bound succesfully rather than
requiring that they all do as sysconf parse handling intends.
Also, binding comma to a command required that it be specified by
its numeric value because parsing via recursion ate up the actual
commas. Now allow "BINDINGS=,:cmd" or "keyM:cmdM,,:cmdN" or
"BINDINGS=\,:cmd" or "keyM:cmdM,\,:cmdN".
It also recognizes "BINDINGS=',':cmd" and "keyM:cmdM,',':cmdN" but
that yields an invalid key error for "','". I thought txt2key()
supported that but it doesn't. I've left this in because the error
about ',' not being recognized as a key seems better than one about
"'" not being a valid key bind and then accidentally binding single
quote via post-comma "':command".
'toptenwin' defaults to false, so the high scores list at end of game
gets written to stdout by default. stdout might be a bit bucket if
the game is started from a menu somewhere or from Explorer or Finder
or something comparable. Even when started from a terminal, writing
to stdout is bad if running asynchronously ('nethack &').
Have Qt init force the 'toptenwin' option to true to show the high
scores in a pop-up text window. The "since you were in wizard mode
your score is ignored" line also goes to a pop-up text window now too.
An extra <return> is needed to dismiss that when quitting if you go
through the full disclosure sequence.
'nethack -s' writes scores to stdout before interface initialization
takes place, so isn't affected by this change. That's intentional so
that 'nethack -s > ~/myscores' can be used to capture the output.
Pull request from vultur-cadens: when engraving with a weapon, the
occupation routine doesn't dull it on the last character, so engraving
a single character never dulled the weapon. Didn't apply to engraving
with other types of items.
Closes#651
After the fairly recent glyph changes, the icons shown for roles and
races during the character selection dialog all were all depicted by
the giant ant tile. I might have noticed this sooner but usually
have '-@' on the command line to bypass selection.