- Don't show attacking a peaceful or tame monster, as
that is actually swapping places with them - so add that.
- Don't show naming a hostile monster - it's usually not
wanted, and this way when clicking a hostile monster, the
only entry is the attack, so will be executed automatically.
This makes it much more usable.
Previously the mouse clicklook mentioned every tile that matched
the character symbol, leading to overload of information and
if playing with tiles, it was mostly useless. Also the most
important bit - the tile info - was last in the text.
Now mouse clicklook only reports the exact tile information
that was clicked on.
If there are any migrating monsters, #migratemons offers a chance
to view them; display the list in arrival destination order rather
than the arbitrary migrating_mons order. Doesn't change the list's
order and doesn't apply to viewing 'c' (mons aimed at current level)
or 'n' (mons aimed at next level), just to 'o' (other, neither 'c'
nor 'n') and 'a' (all migrating mons).
A typo in the code added to #migratemons resulted in bad output when
listing a subset of migrating monsters if there were any aimed at the
next level. Didn't affect listing 'a'll because the incorrect code
wasn't reached in that situation.
If the map is big enough so that makerooms generates the maximum
allowed number of rooms for the level, the last room will "overflow"
into the subrooms array.
The rooms array assumes the last entry has hx = -1, and add_room
changes the next room hx to -1 but because the subrooms array
is right after the rooms array, this change actually touches
the first subroom on the level.
This has been present since who knows how long, but because
the levels are normally small enough, the room limit is never hit.
My change to allow binding the mouse buttons made getpos
push the mouse commands into a command queue, so when you
were asked for a map location, clicked on it with a mouse,
you'd first get the expected effect, and then (most likely)
immediately traveled there.
Change getpos to clear the commands bound to the mouse buttons,
and restore the binds afterwards.
Pull request #846 from entrez: pets got two chances to obtain
intrinsics if they hit for digestion damage (only possible with
engulf attacks).
Closes#846
Engulfing pets were getting a double chance to get an intrinsic from a
digestion attack, because they got the mon_givit call in mhitm_ad_dgst
and then also the one in mdamagem.
There is a bit of inconsistency here, in that mhitm_ad_dgst requires
corpse creation to grant nutrition, but the non-nutrition effects of
eating a corpse like polymorph, extra health, etc, in mdamagem don't
have any such requirement. As a result, one of the mon_givit calls
required a corpse to be "created" before granting an intrinsic, and the
other didn't. In choosing which one to remove, I figured intrinsic
granting is probably closer to those special effects than providing
nutrition (and also putting it in mhitm_ad_dgst is not ideal w/r/t
message ordering: it causes the 'intrinsic granted' message to appear
before the monster kill message).
When moat and lava use the same screen symbol and color is Off, lava
is rendered in inverse video. It used to be similar for floor and
ice, but that got broken last year. Fix inverse ice, and now that
fountain and sink might be same symbol (recent IBMgraphics change),
render sinks in inverse if they match fountains and color is Off.
I started to give sink its own mapglyph flag but then got lazy and
used the same value as ice. That can be amended if some interface
wants to use some more elaborate distinction than inverse video.
Instead of hardcoding mouse button actions, allow the user to
bind mouse buttons to extended commands. For example the new
defaults are:
BIND=mouse1:therecmdmenu
BIND=mouse2:clicklook
Currently a bit rudimentary; the defaults should be OK, but
documentation is bit lacking, and in-game binding and option
saving are missing.
Allowed commands to bind are "nothing", "therecmdmenu", "clicklook",
and "mouseaction". Clicklook replaces the "clicklook" boolean option,
and mouseaction does what mouse 1 button used to do - a context sensitive
action.
By temporarily changing the type definition for each of xint16 and
coordxy to int32_t, the compiler was able to find several places where
the type definitions were wrong.
Redo the fix for using doset(#optionsfull) to toggle perm_invent
under curses. Move it to curses code and let the core be unaware
of it. It does the perm_invent update twice when creating the
window for that.
dump_create_nhwindow() has been returning a bogus value. In the past
that didn't make any difference but after some recent perm_invent
changes, it started triggering a panic when writing the inventory
portion of DUMPLOG.
The changes to invent.c just avoid attempting to create a window that
won't be used.
This will fix some complaints from static analysis. Note that the
code it complained about wasn't incorrect and that's likely to be
the case of a lot of its complaints.
If a monster cannot move, for example because it's being
blocked off by boulders or walls, it will try to escape by some
method - such as a wand or scroll of teleportation.
The #name default key was 'N', but that gets bound to #runsoutheast
when not using number_pad. Swap around the default #name key to M-n,
and bind the 'N' to it in commands_init instead.
The number_pad option wasn't getting saved because it has a separate
handler - mark the option as changed even if the value did not change
so it will be saved to the config.
'color' appears in the simplified O menu for curses, but was not
showing up for tty. That's because it is hidden when tiles are in
use, and tty has had a bogus value for iflags.wc_tiled_map.
Presence of USE_TILES is not a reliable way to tell whether tiles
are available in a multi-interface binary. Nor is the setting of
DEFAULT_WC_TILED_MAP from config.h.
Remove 'I' for remembered, unseen monster if it is successfully killed
as well as when a kill attempt reveals that there is nothing there.
When killing engulfer, don't report it to be "unseen" since hero is
able to recognized it by touch.
Preceding #options or the key bound to that with m runs 'advanced'
options. Implement the inverse: preceding #optionsfull or the key
bound to that with m now runs 'simple' options.
Pull request from argrath: offending code is
| if (function())
| return FALSE;
| return FALSE;
so testing the function's return value is pointless.
Closes#863