autodescribe vs MSGTYPE

I was baffled about why moving the cursor across a fire elemental
kept putting up --More-- until I remembered that I once used
 MSGTYPE=stop "[Ff]ire"
to test Qt's handling for that.  Turns out that I left it in my
config file.  autodescribe feedback should not be honoring that;
honoring MSGTYPE=norepeat is not as clear-cut but this disables
it too.

User sounds were also kept enabled during autodescribe but I have
no way to test them.  Like norepeat, disabling just falls into
place.

The pline.c change is unrelated.  It just eliminates a wide line
(from adding 'g.') in the source by using a shorter variable name.
This commit is contained in:
PatR
2020-11-27 11:10:44 -08:00
parent bbb3d35252
commit daf1381cc2
3 changed files with 11 additions and 9 deletions

View File

@@ -1,4 +1,4 @@
NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.365 $ $NHDT-Date: 1606473484 2020/11/27 10:38:04 $
NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.366 $ $NHDT-Date: 1606504240 2020/11/27 19:10:40 $
General Fixes and Modified Features
-----------------------------------
@@ -312,6 +312,8 @@ throwing or kicking a shop container (that's light enough to move) made the
hero pay for any gold inside, then didn't refund that amount if the
container landed inside the shop
try to fix message sequencing for tame golems that "roast/rot/rust in peace"
autodescribe when moving the cursor was erroneously honoring MSGTYPE=stop
and potentially delivering sounds
Fixes to 3.7.0-x Problems that Were Exposed Via git Repository

View File

@@ -1,4 +1,4 @@
/* NetHack 3.7 do_name.c $NHDT-Date: 1596498162 2020/08/03 23:42:42 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.182 $ */
/* NetHack 3.7 do_name.c $NHDT-Date: 1606504240 2020/11/27 19:10:40 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.184 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Pasi Kallinen, 2018. */
/* NetHack may be freely redistributed. See license for details. */
@@ -556,7 +556,7 @@ int cx, cy;
if (do_screen_description(cc, TRUE, sym, tmpbuf, &firstmatch,
(struct permonst **) 0)) {
(void) coord_desc(cx, cy, tmpbuf, iflags.getpos_coords);
custompline(SUPPRESS_HISTORY,
custompline((SUPPRESS_HISTORY | OVERRIDE_MSGTYPE),
"%s%s%s%s%s", firstmatch, *tmpbuf ? " " : "", tmpbuf,
(iflags.autodescribe
&& getpos_getvalid && !(*getpos_getvalid)(cx, cy))

View File

@@ -1,4 +1,4 @@
/* NetHack 3.7 pline.c $NHDT-Date: 1596498196 2020/08/03 23:43:16 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.96 $ */
/* NetHack 3.7 pline.c $NHDT-Date: 1606504240 2020/11/27 19:10:40 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.100 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2018. */
/* NetHack may be freely redistributed. See license for details. */
@@ -50,16 +50,16 @@ const char *line;
}
/* called during save (unlike the interface-specific message history,
this data isn't saved and restored); end-of-game releases saved_pline[]
this data isn't saved and restored); end-of-game releases saved_plines[]
while writing its contents to the final dump log */
void
dumplogfreemessages()
{
unsigned indx;
unsigned i;
for (indx = 0; indx < DUMPLOG_MSG_COUNT; ++indx)
if (g.saved_plines[indx])
free((genericptr_t) g.saved_plines[indx]), g.saved_plines[indx] = 0;
for (i = 0; i < DUMPLOG_MSG_COUNT; ++i)
if (g.saved_plines[i])
free((genericptr_t) g.saved_plines[i]), g.saved_plines[i] = 0;
g.saved_pline_index = 0;
}
#endif