]> granicus.if.org Git - nethack/commitdiff
B04007 unknown corpse type revealed by hider
authornethack.allison <nethack.allison>
Sun, 28 Jul 2002 02:19:21 +0000 (02:19 +0000)
committernethack.allison <nethack.allison>
Sun, 28 Jul 2002 02:19:21 +0000 (02:19 +0000)
"It was hidden under a green mold corpse!  It bites!"
Never seen corpse from a never seen monster can be
revealed by the hider.
-problem is that the corpse of the monster is
always created with dknown set to 1 when make_corpse() finishes,
even in the case where you never knew what it was while alive.

doc/fixes34.1
src/mon.c

index 46cdfb2478d57cb640fa6362cf2c81ae15711d65..76865a37ab3340d827d10fff560b41a3536ec4e5 100644 (file)
@@ -174,6 +174,7 @@ when using '/' to examine multiple map items in succession, don't mislabel
        some with "or a splash of venom" after having looked at a '.' item
 martial arts kick that knocks a monster into a trap would result in warning
        "dmonsfree: 1 removed doesn't match 2 pending" if the trap was fatal
+if you can't see or sense a monster when it dies, don't set dknown on corpse
 
 
 Platform- and/or Interface-Specific Fixes
index 49c4dee674541b32eeaa9e3f9adea82a2d93eeb7..b449e04714263707dc226623ae766507cc11fa6a 100644 (file)
--- a/src/mon.c
+++ b/src/mon.c
@@ -254,6 +254,14 @@ register struct monst *mtmp;
        if (mtmp->mnamelth)
            obj = oname(obj, NAME(mtmp));
 
+       /* Avoid "It was hidden under a green mold corpse!" 
+        *  during Blind combat. An unseen monster referred to as "it"
+        *  could be killed and leave a corpse.  If a hider then hid
+        *  underneath it, you could be told the corpse type of a
+        *  monster that you never knew was there without this.
+        */
+       if (Blind && !sensemon(mtmp)) obj->dknown = 0;
+
 #ifdef INVISIBLE_OBJECTS
        /* Invisible monster ==> invisible corpse */
        obj->oinvis = mtmp->minvis;