From 6817824379462ee5a1aab8267eb437d2b543504e Mon Sep 17 00:00:00 2001 From: dolorous Date: Sun, 18 Jan 2009 00:34:22 +0000 Subject: Consolidate checks for the player's being undead or a demonspawn into player_is_unholy(), a la mons_is_unholy(), and use it where possible. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8522 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/beam.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'crawl-ref/source/beam.cc') diff --git a/crawl-ref/source/beam.cc b/crawl-ref/source/beam.cc index c8f0bc0143..938ab464f3 100644 --- a/crawl-ref/source/beam.cc +++ b/crawl-ref/source/beam.cc @@ -2270,7 +2270,6 @@ int mons_adjust_flavoured(monsters *monster, bolt &pbolt, int hurted, hurted == 0 ? " appears unharmed." : " writhes in agony!"); } - break; case BEAM_ICE: @@ -3254,7 +3253,6 @@ bool bolt::harmless_to_player() const case BEAM_INVISIBILITY: return (true); - // Cleansing flame doesn't affect player's followers. case BEAM_HOLY: return (is_good_god(you.religion)); @@ -4361,7 +4359,7 @@ void bolt::affect_monster(monsters* mon) // Visual - wake monsters. if (flavour == BEAM_VISUAL) { - behaviour_event( mon, ME_DISTURB, beam_source, source ); + behaviour_event(mon, ME_DISTURB, beam_source, source); apply_hit_funcs(mon, 0); return; } @@ -4386,7 +4384,7 @@ void bolt::affect_monster(monsters* mon) // before we decide if it actually hits. std::vector messages; int preac, postac, final; - if ( !determine_damage(mon, preac, postac, final, messages) ) + if (!determine_damage(mon, preac, postac, final, messages)) return; #if DEBUG_DIAGNOSTICS -- cgit v1.2.3-54-g00ecf