The #wizgenesis command can also accept a quantity in the input prompt,
previously it only accepted a command repeat prefix.
(via UnNetHack, originally from NetHack4)
Move enlightenment and conduct from cmd.c to insight.c. Also move
vanquished monsters plus genocided and/or extinct monsters from end.c
to there. And move the one-line stethoscope/probing feedback for
self and for monsters from priest.c to there.
Achievement feedback has been overhauled a bit. When no achievements
have been recorded, the header for them (after conducts) won't be
shown, and when at least one has been recorded, make the prompt for
asking whether to disclose conduct be about disclosing conduct and
achievements. Also, describe achievements in the Guidebook.
I ran out of gas before updating Guidebook.tex; it will catch up to
Guidebook.mn eventually.
Some of the MS-DOS Makefiles haven't been updated yet so linking
without insight.{o,obj} will break there.
Those tests were only checking the permonst mflags2 field
so anytime those tests were used in the code, they came
up false for things like an elven ranger. An elven ranger
should return true for an is_elf() test, as an example.
That happens because the profession monsters in monst.c
are defined with M2_HUMAN.
This augments those is_*() race tests to also check for a
matching player race as well.
Give better feedback than "<Monster> rummages through something"
when hero sees a monster looting a container.
Have monster take out up to 4 items at a time instead of always 1.
(Hero can take out an arbitrary number in one move.)
When deciding what to try to take out, 'count' (now 'nitems') was
initialized to 1 instead of 0, giving the monster a 1 out of N+1
chance of not trying to take anything out. It wasn't clear whether
that was intentional (there's already a chance for not taking things
out when deciding whether to use the container). I kept that result
in and made it more explicit now.
When deciding whether the chosen item could be moved from container
to monster's inventory, the can_carry(item) check was counting the
weight of the item twice, once explicitly when considering adding it
to minvent but also implicitly as part of the carried container's
weight already in minvent.
After casting a spell, a monster got a chance to make a regular attack
despite the apparent attempt to set up a return value indicating that
it wouldn't move.
When looking over the return value situation, I noticed 'wormhitu()'
for the first time. It gives worms additional attacks when the hero
is adjacent to some of the tail, that only works if the head is within
reach of a melee attack. The hidden tail segment at head's location
always met that criterium so gave an extra attack that didn't make
sense; change wormhitu() to skip that segment.
Do some formatting in mcastu.c; no change in actual code there.
Fixes#285
While testing the changes to dungeon and special level handling, I got
|A mysterious force prevents you from descending!
|You materialize on a different level!
The mystery force is handled by goto_level() so level_tele() doesn't
know that the failure is going to happen when it sets up the message
for deferred delivery. Suppress the message if you don't change levels.
Some cleanup when chasing a memory leak. get_table_str() and
get_table_str_opt() return a value from dupstr() and it wasn't always
being freed. I'm not sure that I found the problem--maybe it involved
pointers turned over to Lua garbage collection--but did find a couple
of suspicious things in dungeon setup.
Preparation for moving enlightenment and conduct into new source
file insight.c. Right now it's a stub that shouldn't break anything
whether included or omitted. Once makefiles and project files have
been updated to compile and link it, the actual code will be moved.
unix/Makefile.src has been updated;
vms/Makefile.src and vmsbuild.com have been updated but not tested.
nhl_loadlua() went from too simple to too complicated, now somewhere
in between. Still doesn't assume that an entire file can be scooped
up with a single fread(), but no longer mucks about with the contents
of the file in order to insert a comment containing the file's name.
In order to have useful filename feedback in Lua error messages, just
use a different liblua routine to feed the file's contents to it.
Stairs up from Orcish Town variation of Mine Town were being forced
to be near the bottom of the left side of the level due to a bogus
exclusion region in the level description. If that small area was all
solid rock then a warning was issued and no stairs up were created.
Applying royal jelly listed all of inventory as likely candidates for
what to rub it on, including itself.
Applying it to anything took no time.
After the "you smear royal jelly on <foo>" message,
unsuccessfully applying it to non-eggs gave no other feedback;
successfully applying it to eggs gave no additional feedback.
Allow #rub to use royal jelly too.
Also, require hands to apply or #rub anything.
Not done: fumbling and/or slippery fingers should have a chance to
drop the jelly or to drop whatever gets rubbed with it.
Royal jelly applied on an egg will change a killer bee egg to
a queen bee egg. Cursed jelly will kill the egg, uncursed and blessed
will revive it. Blessed jelly will also make the creature think
you're the parent.
Original patch was by Kenneth Call
Instead of hardcoding the "prize" type and then watching for that
to be created, specify it in the level description.
Also, instead of giving both Sokoban end levels 50:50 chance for
either prize, bias the one that used to always have the bag of
holding to now have 75% chance for that and 25% chance for amulet
of reflection, with the other one having those chances reversed.
So still 50:50 overall.
Also change a bunch of automatic arrays with initializers to static
so that they won't be reinitialized every time their block is entered.
get_table_buc() is changed to support bless/curse specifiers for
"not-cursed", "not-uncursed", and "not-blessed" but they aren't used
yet.
"The 'm' prefix before a movement command can be used" is awkwardly
worded.
"Various ... variations" is redundant all by itself but doubly so
when "various" is used again two sentences later.
mention_decor is missing a sentence between "Normally only shown
when obscured" and then an exception when it is enabled.
Add the new header file to HACKINCL which only matters to HSOURCES
which only matters for the 'tags' target.
'make depend' reordered some stuff that could have stayed as-is but
also found a missing dependency for nhlobj.{c,o}.
Hero shouldn't be able to zap wands when polymorphed into a form which
lacks hands.
The other tweaks to dozap() shouldn't produce any change in behavior.