From 616e07cde9a55f1cb51e0ed12bdb682adf25914c Mon Sep 17 00:00:00 2001 From: PatR Date: Thu, 14 Nov 2019 16:42:53 -0800 Subject: [PATCH] more #H9392 - deafness vs music The report mentioned whistles but I had forgotten all about them by the time I tried to deal with musical instruments. Plain whistles had deaf handling but magic whistles didn't. --- doc/fixes36.3 | 3 ++- src/apply.c | 19 ++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/doc/fixes36.3 b/doc/fixes36.3 index c7bf521dc..1291c29d7 100644 --- a/doc/fixes36.3 +++ b/doc/fixes36.3 @@ -1,4 +1,4 @@ -$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.176 $ $NHDT-Date: 1573777025 2019/11/15 00:17:05 $ +$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.177 $ $NHDT-Date: 1573778559 2019/11/15 00:42:39 $ This fixes36.3 file is here to capture information about updates in the 3.6.x lineage following the release of 3.6.2 in May 2019. Please note, however, @@ -254,6 +254,7 @@ percentage highlighting for Xp broke up/down/changed highlighting for it; it was flagged as having gone up every time the percentage changed deaf change to zap_over_floor needed to be restricted to player actions only monster vs shade attack inflicted damage despite "passes harmlessly through" +fix for feedback from musical instruments played while deaf ignored whistles curses: sometimes the message window would show a blank line after a prompt curses: the change to show map in columns 1..79 instead of 2..80 made the highlight for '@' show up in the wrong place if clipped map had been diff --git a/src/apply.c b/src/apply.c index e77db07d4..e77984d30 100644 --- a/src/apply.c +++ b/src/apply.c @@ -1,4 +1,4 @@ -/* NetHack 3.6 apply.c $NHDT-Date: 1573346182 2019/11/10 00:36:22 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.283 $ */ +/* NetHack 3.6 apply.c $NHDT-Date: 1573778560 2019/11/15 00:42:40 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.284 $ */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /*-Copyright (c) Robert Patrick Rankin, 2012. */ /* NetHack may be freely redistributed. See license for details. */ @@ -449,7 +449,8 @@ register struct obj *obj; return res; } -static const char whistle_str[] = "produce a %s whistling sound."; +static const char whistle_str[] = "produce a %s whistling sound.", + alt_whistle_str[] = "produce a %s, sharp vibration."; STATIC_OVL void use_whistle(obj) @@ -461,8 +462,7 @@ struct obj *obj; You("blow bubbles through %s.", yname(obj)); } else { if (Deaf) - You_feel("rushing air tickle your %s.", - body_part(NOSE)); + You_feel("rushing air tickle your %s.", body_part(NOSE)); else You(whistle_str, obj->cursed ? "shrill" : "high"); wake_nearby(); @@ -480,16 +480,17 @@ struct obj *obj; if (!can_blow(&youmonst)) { You("are incapable of using the whistle."); } else if (obj->cursed && !rn2(2)) { - You("produce a %shigh-pitched humming noise.", - Underwater ? "very " : ""); + You("produce a %shigh-%s.", Underwater ? "very " : "", + Deaf ? "frequency vibration" : "pitched humming noise"); wake_nearby(); } else { int pet_cnt = 0, omx, omy; /* it's magic! it works underwater too (at a higher pitch) */ - You(whistle_str, - Hallucination ? "normal" : Underwater ? "strange, high-pitched" - : "strange"); + You(Deaf ? alt_whistle_str : whistle_str, + Hallucination ? "normal" + : (Underwater && !Deaf) ? "strange, high-pitched" + : "strange"); for (mtmp = fmon; mtmp; mtmp = nextmon) { nextmon = mtmp->nmon; /* trap might kill mon */ if (DEADMONSTER(mtmp))