diff options
author | DracoOmega <draco_omega@live.com> | 2014-03-09 17:21:02 -0230 |
---|---|---|
committer | DracoOmega <draco_omega@live.com> | 2014-03-09 17:36:16 -0230 |
commit | 0f74bc222cbbb273b5f9879651926401fd134641 (patch) | |
tree | 3d918b5d7b179438648ee7dfae042721125ba412 /crawl-ref/source/throw.cc | |
parent | 5a92590ec142e48405347105de5e9b3661726479 (diff) | |
download | crawl-ref-0f74bc222cbbb273b5f9879651926401fd134641.tar.gz crawl-ref-0f74bc222cbbb273b5f9879651926401fd134641.zip |
Remove misleadingly non-functional AT_SHOOT attacks
AT_SHOOT was intended to provide a damage bonus to selected M_ARCHER
monsters, but due to a mistake in the code, this never actually
functioned. Since the monsters which used it are already plenty
dangerous as-is (eg: deep elf master archers), rather than fixing it
to actually provide the 'intended' bonus, I am simply removing the
misleading attacks, and AT_SHOOT itself.
The one case where AT_SHOOT did actually function was providing an
accuracy bonus to thrown weapons when used by an M_ARCHER (this applied
to merfolk javelineers). This same bonus now applies to any M_ARCHER,
regardless of the presence of an AT_SHOOT attack. In practice, this
just means that javelineers didn't get nerfed, and nothing else should
be noticably affected.
AT_WEAP_ONLY now translates to AT_NONE for enemies using missile
weapons, which is functionally the same as before.
I'm inclined to think that the save compat code here is not actually
necessary, since I don't believe attack_type values this high were
ever persisted anywhere (no ghost_demons seem to use them), but
I'm choosing to err on the side of caution.
Diffstat (limited to 'crawl-ref/source/throw.cc')
-rw-r--r-- | crawl-ref/source/throw.cc | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/crawl-ref/source/throw.cc b/crawl-ref/source/throw.cc index aeea1743ea..ee63f99ef1 100644 --- a/crawl-ref/source/throw.cc +++ b/crawl-ref/source/throw.cc @@ -2133,18 +2133,9 @@ bool mons_throw(monster* mons, bolt &beam, int msl, bool teleport) // FIXME: ammo enchantment ammoHitBonus = ammoDamBonus = min(3, div_rand_round(mons->hit_dice , 3)); - // Archers get a boost from their melee attack. - if (mons->is_archer()) - { - const mon_attack_def attk = mons_attack_spec(mons, 0); - if (attk.type == AT_SHOOT) - { - if (projected == LRET_THROWN) - ammoHitBonus += random2avg(attk.damage, 2); - else - ammoDamBonus += random2avg(attk.damage, 2); - } - } + // Archers get an accuracy boost with thrown weapons + if (mons->is_archer() && projected == LRET_THROWN) + ammoHitBonus += random2avg(mons->hit_dice * 4 / 3, 2); if (projected == LRET_THROWN) { |