fix #H4 - remote recognition of Astral Plane high priests

From a bug report:  the Call command's
prompt is careful not to include "of <deity>" when asking what name to give
a high priest on the Astral level, but the resulting rejection message of
"the <unique monster> doesn't like to be called names" did not, resulting
in feedback of "the high priest of <deity>" and giving away which temple it
is from afar.
This commit is contained in:
nethack.rankin
2005-12-23 02:51:06 +00:00
parent 4327fc88af
commit a43a3ac988
2 changed files with 5 additions and 4 deletions

View File

@@ -170,6 +170,7 @@ can hear the opening or closing of an unseen drawbridge
prevent "object lost" panic caused by accessing freed memory after worn
non-fireproof water walking boots are destroyed by lava
stop multi-turn running, searching, or resting early if levitation ends
Call command could be used to remotely identify which high priest is which
Platform- and/or Interface-Specific Fixes

View File

@@ -246,7 +246,7 @@ const char *name;
int
do_mname()
{
char buf[BUFSZ];
char buf[BUFSZ], monnambuf[BUFSZ];
coord cc;
register int cx,cy;
register struct monst *mtmp;
@@ -290,15 +290,15 @@ do_mname()
return(0);
}
/* special case similar to the one in lookat() */
(void) distant_monnam(mtmp, ARTICLE_THE, buf);
Sprintf(qbuf, "What do you want to call %s?", buf);
(void) distant_monnam(mtmp, ARTICLE_THE, monnambuf);
Sprintf(qbuf, "What do you want to call %s?", monnambuf);
getlin(qbuf,buf);
if(!*buf || *buf == '\033') return(0);
/* strip leading and trailing spaces; unnames monster if all spaces */
(void)mungspaces(buf);
if (mtmp->data->geno & G_UNIQ)
pline("%s doesn't like being called names!", Monnam(mtmp));
pline("%s doesn't like being called names!", upstart(monnambuf));
else
(void) christen_monst(mtmp, buf);
return(0);