From 191abc51947145395619617a958774cb0a2cdd10 Mon Sep 17 00:00:00 2001 From: haranp Date: Sun, 16 Sep 2007 21:25:47 +0000 Subject: Battlelust rage effect changed to 'building rage': you will go berserk next turn. (You can drink a !oBR to cancel the effect. Another rage card effect, however, will just stack on and make you go berserk the next turn.) Breaks savefiles. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2111 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/acr.cc | 8 ++++++-- crawl-ref/source/decks.cc | 7 +++++-- crawl-ref/source/enum.h | 1 + crawl-ref/source/it_use2.cc | 5 +++++ 4 files changed, 17 insertions(+), 4 deletions(-) diff --git a/crawl-ref/source/acr.cc b/crawl-ref/source/acr.cc index 9921435574..406b6df672 100644 --- a/crawl-ref/source/acr.cc +++ b/crawl-ref/source/acr.cc @@ -1849,6 +1849,10 @@ static void decrement_durations() else you.duration[DUR_GOURMAND] = 0; + // must come before might/haste/berserk + if (decrement_a_duration(DUR_BUILDING_RAGE)) + go_berserk(false); + // paradox: it both lasts longer & does more damage overall if you're // moving slower. // rationalisation: I guess it gets rubbed off/falls off/etc if you @@ -1885,10 +1889,10 @@ static void decrement_durations() { mpr("Your icy shield dissipates!", MSGCH_DURATION); you.duration[DUR_CONDENSATION_SHIELD] = 0; - you.redraw_armour_class = 1; + you.redraw_armour_class = true; } } - + if (decrement_a_duration(DUR_ICY_ARMOUR, "Your icy armour evaporates.")) you.redraw_armour_class = true; diff --git a/crawl-ref/source/decks.cc b/crawl-ref/source/decks.cc index 74e2a0c4ef..dfdd37e599 100644 --- a/crawl-ref/source/decks.cc +++ b/crawl-ref/source/decks.cc @@ -808,11 +808,14 @@ static void battle_lust_card(int power, deck_rarity_type rarity) { const int power_level = get_power_level(power, rarity); if ( power_level >= 2 ) + { you.duration[DUR_SLAYING] = random2(power/6) + 1; + mpr("You feel deadly."); + } else if ( power_level == 1 ) { - // FIXME change to "go berserk next turn" - go_berserk(false); + you.duration[DUR_BUILDING_RAGE] = 1; + mpr("You feel your rage building."); } else if ( power_level == 0 ) potion_effect(POT_MIGHT, random2(power/4)); diff --git a/crawl-ref/source/enum.h b/crawl-ref/source/enum.h index 67856cc382..63ac725453 100644 --- a/crawl-ref/source/enum.h +++ b/crawl-ref/source/enum.h @@ -991,6 +991,7 @@ enum duration_type DUR_DEATHS_DOOR, DUR_FIRE_SHIELD, + DUR_BUILDING_RAGE, // countdown to starting berserk DUR_EXHAUSTED, // fatigue counter for berserk DUR_LIQUID_FLAMES, diff --git a/crawl-ref/source/it_use2.cc b/crawl-ref/source/it_use2.cc index a893ca4ceb..381a9f2364 100644 --- a/crawl-ref/source/it_use2.cc +++ b/crawl-ref/source/it_use2.cc @@ -275,6 +275,11 @@ bool potion_effect( potion_type pot_eff, int pow ) mpr("You feel slightly irritated."); make_hungry(100, false); } + else if ( you.duration[DUR_BUILDING_RAGE] ) + { + you.duration[DUR_BUILDING_RAGE] = 0; + mpr("Your blood cools."); + } else { if (go_berserk(true)) -- cgit v1.2.3-54-g00ecf