diff options
Diffstat (limited to 'crawl-ref/source/beam.cc')
-rw-r--r-- | crawl-ref/source/beam.cc | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/crawl-ref/source/beam.cc b/crawl-ref/source/beam.cc index dd420adaad..6e7eb9c717 100644 --- a/crawl-ref/source/beam.cc +++ b/crawl-ref/source/beam.cc @@ -3531,7 +3531,7 @@ bool bolt::misses_player() void bolt::affect_player_enchantment() { - if ((has_saving_throw() || flavour == BEAM_POLYMORPH) + if (has_saving_throw() && flavour != BEAM_POLYMORPH && you_resist_magic(ench_power)) { // You resisted it. @@ -4640,8 +4640,6 @@ bool bolt::has_saving_throw() const if (aimed_at_feet) return (false); - bool rc = true; - switch (flavour) { case BEAM_HASTE: @@ -4650,12 +4648,10 @@ bool bolt::has_saving_throw() const case BEAM_DISPEL_UNDEAD: case BEAM_ENSLAVE_SOUL: // has a different saving throw case BEAM_ENSLAVE_DEMON: // ditto - rc = false; - break; + return (false); default: - break; + return (true); } - return rc; } bool _ench_flavour_affects_monster(beam_type flavour, const monsters* mon) |