From d6e2f77b10192e765011097444a5abef03421eb5 Mon Sep 17 00:00:00 2001 From: dolorous Date: Sun, 15 Jun 2008 18:39:46 +0000 Subject: Add yet more miscellaneous minor fixes. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5855 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/effects.cc | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'crawl-ref/source') diff --git a/crawl-ref/source/effects.cc b/crawl-ref/source/effects.cc index 594d71a460..066a1fba06 100644 --- a/crawl-ref/source/effects.cc +++ b/crawl-ref/source/effects.cc @@ -2502,7 +2502,7 @@ void handle_time(long time_delta) // we take off about .5 points per turn if (!you.duration[DUR_INVIS] && !you.duration[DUR_HASTE] && coinflip()) - added_contamination -= 1; + added_contamination--; // only punish if contamination caused by mutagenic randarts // (haste and invisibility already penalized earlier) @@ -2536,10 +2536,9 @@ void handle_time(long time_delta) // the magical contamination has a harder time dissipating // through non-living flesh. :-) boom.damage = - dice_def( 3, - you.magic_contamination - * (you.is_undead? 4 : 2) - / 4 ); + dice_def(3, + you.magic_contamination + * (you.is_undead ? 4 : 2) / 4); boom.thrower = KILL_MISC; boom.aux_source = "a magical explosion"; boom.beam_source = NON_MONSTER; @@ -2549,9 +2548,7 @@ void handle_time(long time_delta) boom.name = "magical storm"; boom.ench_power = (you.magic_contamination * 5); - boom.ex_size = (you.magic_contamination / 15); - if (boom.ex_size > 9) - boom.ex_size = 9; + boom.ex_size = std::min(9, you.magic_contamination / 15); explosion(boom); } @@ -2565,7 +2562,7 @@ void handle_time(long time_delta) // we're meaner now, what with explosions and whatnot, but // we dial down the contamination a little faster if its actually // mutating you. -- GDL - contaminate_player( -(random2(you.magic_contamination / 4) + 1) ); + contaminate_player(-(random2(you.magic_contamination / 4) + 1)); } } @@ -2644,7 +2641,7 @@ void handle_time(long time_delta) handle_god_time(); if (player_mutation_level(MUT_SCREAM) - && (random2(100) <= 2 + player_mutation_level(MUT_SCREAM) * 3) ) + && (random2(100) <= 2 + player_mutation_level(MUT_SCREAM) * 3)) { yell(true); } -- cgit v1.2.3-54-g00ecf