no renaming of unique monsters with proper names

Not all leaders and nemeses have M2_PNAME set, so they require an extra
check to result in the expected behavior.
This commit is contained in:
cohrs
2002-12-12 02:41:05 +00:00
parent de45cdcc61
commit aec4a1aa8e
2 changed files with 4 additions and 1 deletions

View File

@@ -275,7 +275,9 @@ do_mname()
/* strip leading and trailing spaces; unnames monster if all spaces */
(void)mungspaces(buf);
if (mtmp->iswiz || type_is_pname(mtmp->data))
if (mtmp->iswiz || type_is_pname(mtmp->data) ||
mtmp->data->msound == MS_LEADER ||
mtmp->data->msound == MS_NEMESIS)
pline("%s doesn't like being called names!", Monnam(mtmp));
else (void) christen_monst(mtmp, buf);
return(0);