summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/mon-util.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/mon-util.cc')
-rw-r--r--crawl-ref/source/mon-util.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/crawl-ref/source/mon-util.cc b/crawl-ref/source/mon-util.cc
index ef3e325ce2..958f6bcd8d 100644
--- a/crawl-ref/source/mon-util.cc
+++ b/crawl-ref/source/mon-util.cc
@@ -49,6 +49,7 @@
#include "player.h"
#include "randart.h"
#include "religion.h"
+#include "spells3.h"
#include "spl-util.h"
#include "stuff.h"
#include "terrain.h"
@@ -4093,6 +4094,10 @@ bool monsters::del_ench(enchant_type ench, bool quiet)
if (i == enchantments.end())
return (false);
+ // monsters inside a halo don't lose backlight
+ if (ench == ENCH_BACKLIGHT && mons_inside_halo(x, y))
+ return (false);
+
const mon_enchant me = i->second;
const enchant_type et = i->first;
enchantments.erase(et);