From: nethack.allison Date: Fri, 4 Jun 2004 01:10:44 +0000 (+0000) Subject: polywarn followup (trunk only) X-Git-Tag: MOVE2GIT~1457 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d9e2105d2274efce80cbcfa06b74b5e1c2e73e66;p=nethack polywarn followup (trunk only) --- diff --git a/src/artifact.c b/src/artifact.c index a071842da..02e008bed 100644 --- a/src/artifact.c +++ b/src/artifact.c @@ -1523,14 +1523,14 @@ long *abil; wornbits = (wornmask & *abil); for(obj = invent; obj; obj = obj->nobj) { - if(obj->oartifact) { + if(obj->oartifact && ((abil != &EWarn_of_mon) || context.warntype.obj)) { register const struct artifact *art = get_artifact(obj); if (art) { if (dtyp && (art->cary.adtyp == dtyp || art->defn.adtyp == dtyp)) return obj; if (spfx && ((art->cspfx & spfx) == spfx || - (art->spfx &spfx) == spfx)) + (art->spfx & spfx) == spfx)) return obj; } } else { diff --git a/src/cmd.c b/src/cmd.c index ffd47ec88..78054caac 100644 --- a/src/cmd.c +++ b/src/cmd.c @@ -991,7 +991,7 @@ int final; /* 0 => still in progress; 1 => over, survived; 2 => dead */ (context.warntype.polyd & M2_ORC) ? "orcs" : (context.warntype.polyd & M2_DEMON) ? "demons" : "certain monsters"); - you_are(buf,from_what(WARN_OF_MON)); + you_are(buf,""); } if (Warn_of_mon && context.warntype.speciesidx) { Sprintf(buf, "aware of the presence of %s",