From: nethack.allison Date: Tue, 20 Aug 2002 00:03:17 +0000 (+0000) Subject: B07004 camera breaks on shade X-Git-Tag: MOVE2GIT~2500 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6578eb18841587e3eb00c5622641d851296c2a9a;p=nethack B07004 camera breaks on shade --- diff --git a/doc/fixes34.1 b/doc/fixes34.1 index ad948b72a..df228ce3d 100644 --- a/doc/fixes34.1 +++ b/doc/fixes34.1 @@ -210,6 +210,7 @@ remove TIMED_DELAY from the features checked for version compatibility rolling boulder hitting monster stuck in pit should stop even when mon survives don't see chest trap gas colors while Blind adjust fruit name in potion juice messages if it has the form "foo of bar" +wielded camera passes harmlessly through shade Platform- and/or Interface-Specific Fixes diff --git a/src/uhitm.c b/src/uhitm.c index 0b0f62757..29d881de1 100644 --- a/src/uhitm.c +++ b/src/uhitm.c @@ -519,6 +519,7 @@ int thrown; int wtype; struct obj *monwep; char yourbuf[BUFSZ]; + char *unconventional = (char *)0; /* substituted for word "attack" in msg */ wakeup(mon); if(!obj) { /* attack with bare hands */ @@ -684,10 +685,13 @@ int thrown; break; #ifdef TOURIST case EXPENSIVE_CAMERA: - You("succeed in destroying %s camera. Congratulations!", - shk_your(yourbuf, obj)); - useup(obj); - return(TRUE); + if (mdat != &mons[PM_SHADE]) { + You("succeed in destroying %s camera. Congratulations!", + shk_your(yourbuf, obj)); + useup(obj); + return(TRUE); + } else unconventional = "camera"; + break; #endif case CORPSE: /* fixed by polder@cs.vu.nl */ if (touch_petrifies(&mons[obj->corpsenm])) { @@ -892,7 +896,8 @@ int thrown; tmp = 0; if (mdat == &mons[PM_SHADE]) { if (!hittxt) { - Your("attack passes harmlessly through %s.", + Your("%s passes harmlessly through %s.", + unconventional ? unconventional : "attack", mon_nam(mon)); hittxt = TRUE; }