diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index 7a14944638..876fa73a7b 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -5647,7 +5647,8 @@ namespace CalamityMod.NPCs VulnerabilityHexFireDrawer = null; // Miracle Blight will not attempt to use its shader on bosses from other mods. It still works on vanilla bosses. - bool otherModBoss = npc.IsABoss() && npc.ModNPC.Mod is not null && npc.ModNPC.Mod != CalamityMod.Instance; + Mod sourceMod = npc.ModNPC?.Mod ?? null; + bool otherModBoss = npc.IsABoss() && sourceMod != CalamityMod.Instance; // Setting the NPC immune to Miracle Blight also makes the shader immediately disappear. bool useMiracleBlightShader = !npc.buffImmune[BuffType()] && !otherModBoss; if (useMiracleBlightShader && npc.Calamity().miracleBlight > 0)