summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--crawl-ref/source/mon-act.cc6
-rw-r--r--crawl-ref/source/monster.cc4
-rw-r--r--crawl-ref/source/output.cc2
3 files changed, 10 insertions, 2 deletions
diff --git a/crawl-ref/source/mon-act.cc b/crawl-ref/source/mon-act.cc
index bc15130cc4..da7b274724 100644
--- a/crawl-ref/source/mon-act.cc
+++ b/crawl-ref/source/mon-act.cc
@@ -1461,7 +1461,7 @@ static bool _handle_throw(monsters *monster, bolt & beem)
return (false);
const bool archer = mons_class_flag(monster->type, M_ARCHER);
- // Highly-specialised archers are more likely to shoot than talk.
+ // Highly-specialised archers are more likely to shoot than talk. (?)
if (one_chance_in(archer? 9 : 5))
return (false);
@@ -1474,6 +1474,10 @@ static bool _handle_throw(monsters *monster, bolt & beem)
if (!archer && adjacent(beem.target, monster->pos()))
return (false);
+ // If the monster is a spellcaster, don't bother throwing stuff.
+ if (mons_has_ranged_spell(monster, true, false))
+ return (false);
+
// Greatly lowered chances if the monster is fleeing or pacified and
// leaving the level.
if ((mons_is_fleeing(monster) || monster->pacified())
diff --git a/crawl-ref/source/monster.cc b/crawl-ref/source/monster.cc
index 3e51512148..30ea97c471 100644
--- a/crawl-ref/source/monster.cc
+++ b/crawl-ref/source/monster.cc
@@ -1445,6 +1445,10 @@ bool monsters::pickup_throwable_weapon(item_def &item, int near)
ASSERT(slot == MSLOT_MISSILE);
+ // Spellcasters shouldn't bother with missiles.
+ if (mons_has_ranged_spell(this, true, false))
+ return (false);
+
// If occupied, don't pick up a throwable weapons if it would just
// stack with an existing one. (Upgrading is possible.)
if (mslot_item(slot)
diff --git a/crawl-ref/source/output.cc b/crawl-ref/source/output.cc
index 7a55f02527..8226d157f0 100644
--- a/crawl-ref/source/output.cc
+++ b/crawl-ref/source/output.cc
@@ -308,7 +308,7 @@ static void _print_stats_mp(int x, int y)
for (int i = 11-col; i > 0; i--)
cprintf(" ");
- if (! Options.classic_hud)
+ if (!Options.classic_hud)
MP_Bar.draw(19, y, you.magic_points, you.max_magic_points);
}