From: Pasi Kallinen Date: Sat, 14 Oct 2017 18:29:17 +0000 (+0300) Subject: Make boulder dropping noise wake up monsters X-Git-Tag: NetHack-3.6.1_RC01~257 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=612a0cb909143d9e29e1f7b9e9b40ae62771d0b9;p=nethack Make boulder dropping noise wake up monsters Also, don't bother waking up monsters who would end up dead anyway. --- diff --git a/src/read.c b/src/read.c index ad1c75f37..29513f7ef 100644 --- a/src/read.c +++ b/src/read.c @@ -1714,6 +1714,7 @@ boolean confused, helmet_protects, byu, skip_uswallow; } } else dmg = 0; + wake_nearto(u.ux, u.uy, 4 * 4); /* Must be before the losehp(), for bones files */ if (!flooreffects(otmp2, u.ux, u.uy, "fall")) { place_object(otmp2, u.ux, u.uy); @@ -1771,7 +1772,6 @@ boolean confused, byu; xname(helmet), mhim(mtmp)); } } - wakeup(mtmp, byu); mtmp->mhp -= mdmg; if (mtmp->mhp <= 0) { if (byu) { @@ -1780,7 +1780,10 @@ boolean confused, byu; pline("%s is killed.", Monnam(mtmp)); mondied(mtmp); } + } else { + wakeup(mtmp, byu); } + wake_nearto(x, y, 4 * 4); } else if (u.uswallow && mtmp == u.ustuck) { obfree(otmp2, (struct obj *) 0); /* fall through to player */