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.cc7
1 files changed, 6 insertions, 1 deletions
diff --git a/crawl-ref/source/mon-util.cc b/crawl-ref/source/mon-util.cc
index 0a80500e7e..a664852bcd 100644
--- a/crawl-ref/source/mon-util.cc
+++ b/crawl-ref/source/mon-util.cc
@@ -3190,7 +3190,12 @@ item_def *monsters::launcher()
item_def *monsters::weapon(int which_attack)
{
- if (which_attack > 1)
+ const mon_attack_def attk = mons_attack_spec(this, which_attack);
+ if ( attk.type != AT_HIT )
+ return NULL;
+
+ // Even/odd attacks use main/offhand weapon
+ if ( which_attack > 1 )
which_attack &= 1;
// This randomly picks one of the wielded weapons for monsters that can use