summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/mgrow.cc
diff options
context:
space:
mode:
authorDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-11-05 20:15:50 -0600
committerDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-11-05 20:17:47 -0600
commit142d889bc748bdf7f21a5b04d3693a5bc8b48d5c (patch)
tree7cae2b42f500d532d54072b633bc47bc4195b875 /crawl-ref/source/mgrow.cc
parentfe0c876c1598ee328e74c5be5102004f28972b7e (diff)
downloadcrawl-ref-142d889bc748bdf7f21a5b04d3693a5bc8b48d5c.tar.gz
crawl-ref-142d889bc748bdf7f21a5b04d3693a5bc8b48d5c.zip
Remove the M_EVIL flag from orc wizards.
Also, properly anger monsters that start off non-evil, but level up into evil monsters.
Diffstat (limited to 'crawl-ref/source/mgrow.cc')
-rw-r--r--crawl-ref/source/mgrow.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/crawl-ref/source/mgrow.cc b/crawl-ref/source/mgrow.cc
index 6334387a82..3693e43dd4 100644
--- a/crawl-ref/source/mgrow.cc
+++ b/crawl-ref/source/mgrow.cc
@@ -9,6 +9,7 @@
#include "enum.h"
#include "mgrow.h"
#include "mon-util.h"
+#include "monplace.h"
#include "monstuff.h"
#include "random.h"
@@ -235,5 +236,9 @@ bool monsters::gain_exp(int exp)
if (hit_dice < MAX_MONS_HD && experience >= mexplevs[hit_dice + 1])
experience = (mexplevs[hit_dice] + mexplevs[hit_dice + 1]) / 2;
+ // If the monster has leveled up to a monster that will be angered
+ // by the player, handle it properly.
+ player_angers_monster(this);
+
return (levels_gained > 0);
}