summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-11 15:29:17 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-11 15:29:17 +0000
commit2cd32d9940652f0467301ffd387e0c8e277fb6cc (patch)
tree6b0a43693e520eeb7c7cba4efe464127287c665f
parent227944da0af8ce80bfe1c916906d8c2550027f5e (diff)
downloadcrawl-ref-2cd32d9940652f0467301ffd387e0c8e277fb6cc.tar.gz
crawl-ref-2cd32d9940652f0467301ffd387e0c8e277fb6cc.zip
Backport trunk r9960 to 0.5.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/branches/stone_soup-0.5@9961 c06c8d41-db1a-0410-9941-cceddc491573
-rw-r--r--crawl-ref/source/mon-util.cc18
1 files changed, 11 insertions, 7 deletions
diff --git a/crawl-ref/source/mon-util.cc b/crawl-ref/source/mon-util.cc
index 5bc02bd5f3..c7fa1b26d1 100644
--- a/crawl-ref/source/mon-util.cc
+++ b/crawl-ref/source/mon-util.cc
@@ -6591,26 +6591,30 @@ void monsters::add_enchantment_effect(const mon_enchant &ench, bool quiet)
if (type == MONS_AIR_ELEMENTAL)
{
mprf("%s merges itself into the air.",
- name(DESC_CAP_A, true).c_str() );
+ name(DESC_CAP_A, true).c_str());
}
else if (type == MONS_TRAPDOOR_SPIDER)
{
mprf("%s hides itself under the floor.",
- name(DESC_CAP_A, true).c_str() );
+ name(DESC_CAP_A, true).c_str());
}
else if (seen_context == "surfaces"
|| seen_context == "bursts forth"
|| seen_context == "emerges")
{
- // The monster surfaced and submerged in the same turn without
- // doing anything else.
+ // The monster surfaced and submerged in the same turn
+ // without doing anything else.
interrupt_activity(AI_SEE_MONSTER,
activity_interrupt_data(this,
"surfaced"));
}
else if (crawl_state.arena)
- mprf("%s submerges.", name(DESC_CAP_A, true).c_str() );
+ mprf("%s submerges.", name(DESC_CAP_A, true).c_str());
}
+
+ // Pacified monsters leave the level when they submerge.
+ if (mons_is_pacified(this))
+ make_mons_leave_level(this);
break;
case ENCH_CONFUSION:
@@ -6631,8 +6635,8 @@ void monsters::add_enchantment_effect(const mon_enchant &ench, bool quiet)
if (is_patrolling())
{
- // Enslaved monsters stop patrolling and forget their patrol point,
- // they're supposed to follow you now.
+ // Enslaved monsters stop patrolling and forget their patrol
+ // point; they're supposed to follow you now.
patrol_point.reset();
}
if (you.can_see(this))