diff options
author | Adam Borowski <kilobyte@angband.pl> | 2013-10-24 01:13:03 +0200 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2013-10-24 01:16:23 +0200 |
commit | 030a9692ab9c0726bfda5f73777e6d6a0a00a37f (patch) | |
tree | ce6d44297d95990121b1ca6387c94e5f9ab07316 /crawl-ref/source/mon-project.cc | |
parent | 1d578dda6fd52327bc9191d353834ce0f246dbcc (diff) | |
download | crawl-ref-030a9692ab9c0726bfda5f73777e6d6a0a00a37f.tar.gz crawl-ref-030a9692ab9c0726bfda5f73777e6d6a0a00a37f.zip |
Fix a crash when a boulder beetle dies to its own first move.
Besides, why should they even get to start rolling if there's an enemy
next to them? Isn't rolling damage supposed to require some space to
gain momentum? They can keep biting when up close.
Diffstat (limited to 'crawl-ref/source/mon-project.cc')
-rw-r--r-- | crawl-ref/source/mon-project.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crawl-ref/source/mon-project.cc b/crawl-ref/source/mon-project.cc index 53c9e37aef..94980d0f5d 100644 --- a/crawl-ref/source/mon-project.cc +++ b/crawl-ref/source/mon-project.cc @@ -152,6 +152,9 @@ static bool _in_front(float vx, float vy, float dx, float dy, float angle) static void _iood_stop(monster& mon, bool msg = true) { + if (!mon.alive()) + return; + if (mons_is_boulder(&mon)) { // Deduct the energy first - the move they made that just stopped |