]> granicus.if.org Git - nethack/commitdiff
gold kicking bit
authorPatR <rankin@nethack.org>
Sun, 11 Jul 2021 00:37:38 +0000 (17:37 -0700)
committerPatR <rankin@nethack.org>
Sun, 11 Jul 2021 00:37:38 +0000 (17:37 -0700)
One of the gold kicking changes I had pending.  The "Thwwpingg"
message is obviously intended as a sound effect so shouldn't be
given if the hero is Deaf.

src/dokick.c

index 6fa333553e90caf89f9f46ce0ae6feffe0734eab..48199babac0224d391ef1384e95fd39c3905cb0a 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.7 dokick.c        $NHDT-Date: 1608673689 2020/12/22 21:48:09 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.162 $ */
+/* NetHack 3.7 dokick.c        $NHDT-Date: 1625963851 2021/07/11 00:37:31 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.167 $ */
 /* Copyright (c) Izchak Miller, Mike Stephenson, Steve Linhart, 1989. */
 /* NetHack may be freely redistributed.  See license for details. */
 
@@ -641,9 +641,10 @@ really_kick_object(xchar x, xchar y)
                     "send coins flying in all directions",
                 };
 
-                pline("Thwwpingg!");
+                if (!Deaf)
+                    pline1("Thwwpingg!");
                 You("%s!", flyingcoinmsg[rn2(SIZE(flyingcoinmsg))]);
-                (void) scatter(x, y, rn2(3) + 1, VIS_EFFECTS | MAY_HIT,
+                (void) scatter(x, y, rnd(3), VIS_EFFECTS | MAY_HIT,
                                g.kickedobj);
                 newsym(x, y);
                 return 1;