]> granicus.if.org Git - nethack/commitdiff
fix #K355 - grammar issues with monster+container
authorPatR <rankin@nethack.org>
Sat, 15 Feb 2020 00:24:49 +0000 (16:24 -0800)
committerPatR <rankin@nethack.org>
Sat, 15 Feb 2020 00:24:49 +0000 (16:24 -0800)
Mon rummages in <container> and Mon takes <item> from <container>
was missing an() for the container itself and should have been
using doname() rather than xname() for any items taken out (when
done adjacent to hero).

doc/fixes37.0
src/muse.c

index 4a2f297f6dc9135cd21e61112f6edaf6ae392574..e9f7e6fef72c78ef7974f8a3211667047a00f020 100644 (file)
@@ -1,4 +1,4 @@
-$NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.98 $ $NHDT-Date: 1581637124 2020/02/13 23:38:44 $
+$NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.99 $ $NHDT-Date: 1581726277 2020/02/15 00:24:37 $
 
 General Fixes and Modified Features
 -----------------------------------
@@ -94,6 +94,7 @@ prevent "you materialize on a different level" after "a mysterious force
 set g.context.botl for glove and wielding actions that could start or end
        bare-handedness in support of condtests[bl_bareh]
 reinstate ranked ordering of the status condition fields
+grammar for messages about a monster removing items from a container was bad
 
 
 Platform- and/or Interface-Specific Fixes
index bcb191f9f8aa8f572f51e55875415b9a48c17f99..ab5f41668bbfb1f82f57cfd2d68bd78cb649a09b 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.6 muse.c  $NHDT-Date: 1580685754 2020/02/02 23:22:34 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.119 $ */
+/* NetHack 3.6 muse.c  $NHDT-Date: 1581726278 2020/02/15 00:24:38 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.120 $ */
 /*      Copyright (C) 1990 by Ken Arromdee                         */
 /* NetHack may be freely redistributed.  See license for details.  */
 
@@ -1847,8 +1847,8 @@ boolean vismon;
                                 * even if [attempted] removal is observed */
         if (!*contnr_nam) {
             /* xname sets dknown, distant_name doesn't */
-            Strcpy(contnr_nam, nearby ? xname(container)
-                                      : distant_name(container, xname));
+            Strcpy(contnr_nam, an(nearby ? xname(container)
+                                         : distant_name(container, xname)));
         }
         /* this was originally just 'can_carry(mon, xobj)' which
            covers objects a monster shouldn't pick up but also
@@ -1865,10 +1865,10 @@ boolean vismon;
                     Norep("%s rummages through %s.", Monnam(mon), contnr_nam);
                 else if (takeout_indx == 0) /* adjacent, first item */
                     pline("%s removes %s from %s.", Monnam(mon),
-                          an(xname(xobj)), contnr_nam);
+                          doname(xobj), contnr_nam);
                 else /* adjacent, additional items */
                     pline("%s removes %s.", upstart(mpronounbuf),
-                          an(xname(xobj)));
+                          doname(xobj));
             }
             /* obj_extract_self(xobj); -- already done above */
             (void) mpickobj(mon, xobj);