From: Pasi Kallinen Date: Sat, 26 Dec 2015 19:40:17 +0000 (+0200) Subject: Fix prot from shape changers at level generation X-Git-Tag: NetHack-3.6.1_RC01~1109 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e55dd6919acd12dbc85b44c9f55cf376f8e8c2bd;p=nethack Fix prot from shape changers at level generation Mimics and other shape changers created at level generation did not obey protection from shape changers. --- diff --git a/src/makemon.c b/src/makemon.c index 55cf66fab..422a446c2 100644 --- a/src/makemon.c +++ b/src/makemon.c @@ -1988,7 +1988,7 @@ register struct monst *mtmp; struct obj *otmp; int mx, my; - if (!mtmp) + if (!mtmp || Protection_from_shape_changers) return; mx = mtmp->mx; my = mtmp->my; diff --git a/src/sp_lev.c b/src/sp_lev.c index f65e3c270..61740b436 100644 --- a/src/sp_lev.c +++ b/src/sp_lev.c @@ -1585,7 +1585,8 @@ struct mkroom *croom; * eventually be expanded. */ if (m->appear_as.str - && ((mtmp->data->mlet == S_MIMIC) || mtmp->cham)) { + && ((mtmp->data->mlet == S_MIMIC) || mtmp->cham) + && !Protection_from_shape_changers) { int i; switch (m->appear) {