summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/monstuff.cc
diff options
context:
space:
mode:
authorzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-01-19 10:39:40 +0000
committerzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-01-19 10:39:40 +0000
commit292e72845a1e767892b9f64024099ef91b1faf11 (patch)
tree5988b5095ebce687f0a50a83e493a4467690ccba /crawl-ref/source/monstuff.cc
parentb3ee0a265fdc0914c44fa0574d1d7d107fa8d38a (diff)
downloadcrawl-ref-292e72845a1e767892b9f64024099ef91b1faf11.tar.gz
crawl-ref-292e72845a1e767892b9f64024099ef91b1faf11.zip
Don't place monster death clouds when the monster is submerged or dismissed by
wizard command. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8591 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/monstuff.cc')
-rw-r--r--crawl-ref/source/monstuff.cc15
1 files changed, 10 insertions, 5 deletions
diff --git a/crawl-ref/source/monstuff.cc b/crawl-ref/source/monstuff.cc
index 0f883fb19f..9199d78f98 100644
--- a/crawl-ref/source/monstuff.cc
+++ b/crawl-ref/source/monstuff.cc
@@ -1039,8 +1039,8 @@ int monster_die(monsters *monster, killer_type killer,
if (mons_near(monster) || wizard)
remove_auto_exclude(monster);
- int summon_type = 0;
- int duration = 0;
+ int summon_type = 0;
+ int duration = 0;
const bool summoned = mons_is_summoned(monster, &duration,
&summon_type);
const int monster_killed = monster_index(monster);
@@ -1051,6 +1051,8 @@ int monster_die(monsters *monster, killer_type killer,
const bool mons_reset( killer == KILL_RESET || killer == KILL_DISMISSED );
+ const bool submerged = monster->submerged();
+
bool in_transit = false;
#ifdef DGL_MILESTONES
@@ -1129,7 +1131,8 @@ int monster_die(monsters *monster, killer_type killer,
silent = true;
}
- if (monster->type == MONS_FIRE_VORTEX && !wizard && !mons_reset)
+ if (monster->type == MONS_FIRE_VORTEX && !wizard && !mons_reset
+ && !submerged)
{
place_cloud(CLOUD_FIRE, monster->pos(), 2 + random2(4),
monster->kill_alignment());
@@ -1148,7 +1151,7 @@ int monster_die(monsters *monster, killer_type killer,
silent = true;
}
- if (!wizard && !mons_reset)
+ if (!wizard && !mons_reset && !submerged)
place_cloud(CLOUD_COLD, monster->pos(), 2 + random2(4),
monster->kill_alignment());
@@ -1607,7 +1610,9 @@ int monster_die(monsters *monster, killer_type killer,
_mummy_curse(monster, killer, killer_index);
}
- _monster_die_cloud(monster, !mons_reset, silent, summoned, summon_type);
+ if (!wizard && !submerged)
+ _monster_die_cloud(monster, !mons_reset, silent, summoned,
+ summon_type);
int corpse = -1;
if (!mons_reset)