I did this several months ago to avoid a sanity check warning (and
consequent fuzzer panic) when an engulfer expels the hero on a full
level. I was hoping to refine it but never went back; install it
now before forgetting about it entirely.
If a chameleon changes from wall-phazer to engulfer while in a spot
the hero can't move onto and engulfs him/her, expelling the hero
after the engulfer has taken the hero's spot might be forced to put
the hero on top of the engulfer or another monster when unable to
use the engulfer's former spot. Rather than try to figure out all
the possible ways this might happen and attempt to deal with each
of them, just prevent an engulf attack from succeeding if the hero
wouldn't be able to move to the engulfer's spot. (Does not prevent
an air elemental over water from engulfing the hero.)
Don't attempt to switch to CR font (used to get fixed-width characters
when generating output that uses proportional width ones) when output
is already fixed-width (plain text).
The most recent release of groff (version 1.23) complains when a font
can't be found, then keeps going. Earlier versions just silently kept
going. Failing to load the CR font when already producing fixed-width
chars makes 'keep going' acceptable but the font-load-failure warnings
are a nuisance.
"object lost" panic occurred when hero's worn amulet of magical
breathing was stolen. This prevents drown() -> emergency_disrobe()
from dropping an item while in the midst of it being stolen, avoiding
the possibility of it no longer being in inventory when the theft
completes. There may be variations other than drowning that lead to
unwear -> drop-or-destroy that are still vulnerable, and this fix can
potentially cause items to vanish from hangup save files.
It also has a side-effect of not being able to drop levitation boots
to lighten encumbrance enough to crawl out of water if the drowning
occurs while they are being taken off, not just when being stolen,
even though they should be easily droppable in such circumstance. The
hero will just need to drop other things instead.
If any cond_xyz options came from the old RC file or were changed with
'm O' but they were all back to their default values when #saveoptions
was executed, the new RC file would end up with 'OPTIONS=\n' at the
end. Then if that RC file gets loaded in a subsequent game, there
will be a warning about "Empty statement".
Confusion between 'o_status_cond' and 'pfx_cond_'. Still confusing
but I think now working as intended and expected.
If any cond_xyz option has been loaded from the RC file or changed via
'm O', #saveoptions still saves the full set rather than just the ones
that are different from their default value.
Menus in the curses interface would honor a digit as a selector
character ("letter" :-) for PICK_ANY menus but forced it to start a
count in PICK_ONE menus. This fixes that, although the menu where I
was using digits as selectors (not included) has been changed to use
letters so this fix isn't being exercised anymore.
Also, add a couple of comments about persistent inventory.
This does not fix the actual problem that is causing the warnings.
It merely suppresses the hundreds of warnings until the actual
problem is corrected.
If there is no NROFF_FLAGS defined in a hints file, there should be
no change in behavior.
At this time, only sys/unix/hints/linux.370 sets NROFF_FLAGS.
Modifying an() [actually just_an()] to treat "<thickness> ice" and
"frozen <hallucinatory liquid>" as special cases which shouldn't be
prefixed with "a" or "an" affected using something like "shaved ice"
or "frozen yogurt" as named fruit.
|a) shaved ice
|b) frozen yogurt (weapon in hand)
now have article "a" preceding them:
|a) a shaved ice
|b) a frozen yogurt (weapon in hand)
However, the existing cases
|c) iron bars
|d) an iron bars (weapon in hand)
still get item 'c' wrong. 'd' is slightly odd but that's because the
fruit name is ambiguous as to whether it's singular or plural.
Classify nearby ice as "solid" (no melt timer), "sturdy" (more than
1000 turns left), "steady" (101 to 1000 turns left), "unsteady" (51
to 100 turns left), "thin" (15 to 50 turns left), or "slushy" (1 to
14 turns left, matching walking on ice with the Warning attribute).
[I'm not thrilled with "steady" and particularly "unsteady".]
I was originally going to do this just for probing downward, but ended
up also doing it for look-here and getpos's autodescribe. It nearly
got out of hand and touched more files than anticipated.
'mention_decor' ought to treat moving from ice firmer than thin to
thin or slushy, from thin to slushy, from slushy to any other, and
from thin to firmer as if moving onto different terrain but I haven't
attempted to tackle that.
The melt timer could work more like a candle's burn timer, triggering
at intermediate stages and resetting itself, so that ice which changes
to a weaker state under the hero could be reported to the player. But
this doesn't implement that.
When probing is zapped downward while hero is at a water or lava spot
and hero isn't beneath the surface, show any objects 'hidden' by the
water or lava at that spot.
Gold can be quivered but not wielded, so remove the reference to the
latter. Inuse-only mode gets passed lamps and leashes when they're
actively used, so remove the reference to that being different from
Qt's paperdoll. (It is actually different, but not because they
won't be shown as in-use. The paperdoll only shows one of each but
inventory of in-use items might have more than one of either or both.)
Add a what-if comment to tools_in_use().
and reimplement 'sparse' mode (TTYINV=2 or TTYINV=3).
When hero had no inventory except for gold and perminv display mode is
ignoring gold, the header said "empty" when "only gold" was intended.
Sparse mode populates perminv with inventory letters in the unused
slots instead of leaving them blank. (The core doesn't need to be
aware of that since it doesn't affect what display_inventory() sends
to the inventory menu.)
My repository got out of synch and I had a hell of a time restoring
sanity.
The most recent commit included a line in wintty.c that shouldn't have
been there.
Some changes I made while chasing the slots 'A' and 'B' bug. These
weren't necessary to fix that and I don't think they produce any
change in behavior, aside from making the "Bad window id N" panic
be more specific if it occurs.
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.
Fuzzer encountered "m_detach: monster already detached?"
A monster hit a black pudding that split. The clone was
created on top of a rolling boulder trap, which triggered,
the boulder hit the original black pudding, and killed it.
The dead pudding then retaliated (as the code didn't check
if it was dead) and a passive attack of the other monster
tried to kill the already dead pudding.
I think one of these checks would be enough, but adding the
DEADMONSTER check just in case.
While testing something else, I noticed rolling boulders
just ignored walls and trees; in normal play this isn't
a problem - but should probably make boulders handle other
terrain too. Lava and water is already handled correctly.
This allowed eg. throwing the iron ball anywhere on the map,
by first throwing something else, using the "simulated mouse click"
to select any map location, and then throwing the iron ball and
also using the mouse click feature to select any location.
Currently the only function that actually uses the simulated
mouse click feature is #therecmdmenu
A tame nymph attacked another monster, stole an item and teleported
away, but dog_move() wasn't passed the information that the nymph
was done, and tried to move the nymph from the old location.
Same with a tame leprechaun.
Report suggested that "can not" should be "cannot". Both forms are
acceptable. This switches them to use contractions for various "You
<verb> not subject" phrases: "You can't subject", "hadn't", and so
forth. Not exhaustively tested; there may be some sentences where the
informal contraction makes things worse rather than better.
The goal here was compactness rather than efficiency since the code
involved doesn't execute very often.
The problem with tty perminv slots 'A' and 'B' boiled down to
slot_limit = SIZE(slot_tracker); /*54*/
...
/* blank out unused slots */
for (slot = 0; slot < slot_limit; ++slot) {
...
row = (slot % rows_per_side) + 1; /* +1: top border */
side = slot < rows_per_side ? 0 : 1;
ttyinv_populate_slot(row,side,...);
}
Unused slots [52] and [53] (available for show_gold mode to display
"$a..zA..Z#", not filled with inventory for normal tty perm_invent
"a..zA..Z") yielded rows 1 and 2, side 1, so clobbered slots 'A' and
'B' with blanks.
This is a subset of the changes I was working with and didn't get as
much testing as the full set.