From b5a43a60f283ddd66b8be70a9425171828507ac1 Mon Sep 17 00:00:00 2001 From: Pasi Kallinen Date: Fri, 25 Aug 2023 10:58:07 +0300 Subject: [PATCH] Asmodeus' cold magic attack when hero is resistant Asmodeus kept using the cold magic attack when hero was cold resistant. The distance magic attack already considered hero resistances, so use the same logic for the close-up magic attack. --- src/mcastu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mcastu.c b/src/mcastu.c index 72b6264a4..8499ae81a 100644 --- a/src/mcastu.c +++ b/src/mcastu.c @@ -221,7 +221,8 @@ castmu( } /* monster unable to cast spells? */ - if (mtmp->mcan || mtmp->mspec_used || !ml) { + if (mtmp->mcan || mtmp->mspec_used || !ml + || m_seenres(mtmp, cvt_adtyp_to_mseenres(mattk->adtyp))) { cursetxt(mtmp, is_undirected_spell(mattk->adtyp, spellnum)); return M_ATTK_MISS; }