From 176766de35534103aa16f320af43f26b658fb07c Mon Sep 17 00:00:00 2001 From: Jared Tinney (Twinge) Date: Sat, 6 Mar 2010 03:41:54 -0800 Subject: [PATCH] Make Holy Word useful: more damage, paralysis, hits evil. Damage is now 58 average, higher for those worshipping good gods (esp. TSO) Paralyzes now instead of faking it with energy. High HD mobs can resist, and also recover faster. Now flavored as calling on TSO's aid, and hits those worshipping evil gods too, both player and monster. Related to this, chances of non-priest orcs worshipping Beogh reduced. --- crawl-ref/source/contrib/sdl-image | 2 +- crawl-ref/source/contrib/sqlite | 2 +- crawl-ref/source/dat/descript/items.txt | 4 ++-- crawl-ref/source/effects.cc | 25 +++++++++++++++---------- crawl-ref/source/item_use.cc | 4 ++-- crawl-ref/source/mon-place.cc | 8 ++++++-- 4 files changed, 27 insertions(+), 18 deletions(-) diff --git a/crawl-ref/source/dat/descript/items.txt b/crawl-ref/source/dat/descript/items.txt index ed5f676..3289cb9 100644 --- a/crawl-ref/source/dat/descript/items.txt +++ b/crawl-ref/source/dat/descript/items.txt @@ -1274,8 +1274,8 @@ This scroll surrounds the reader with a dense cloud of fog. %%%% scroll of holy word -This scroll calls on the powers of Heaven to cause great damage to any -nearby unholy creature - including you! +This scroll calls on the powers of The Shining One to cause great damage to +any nearby undead, demonic, or evil-worshipping creature - including you! %%%% scroll of identify diff --git a/crawl-ref/source/effects.cc b/crawl-ref/source/effects.cc index cd35eec..58ed8a3 100644 --- a/crawl-ref/source/effects.cc +++ b/crawl-ref/source/effects.cc @@ -79,7 +79,7 @@ int holy_word_player(int pow, int caster, actor *attacker) { - if (!you.undead_or_demonic()) + if (!you.undead_or_demonic() && !is_evil_god(you.religion)) return (0); int hploss; @@ -128,7 +128,8 @@ int holy_word_player(int pow, int caster, actor *attacker) int holy_word_monsters(coord_def where, int pow, int caster, actor *attacker) { - pow = std::min(300, pow); + //Safeguard for future changes. + pow = std::min(200, pow); int retval = 0; @@ -141,8 +142,11 @@ int holy_word_monsters(coord_def where, int pow, int caster, if (monster == NULL) return (retval); - if (!monster->alive() || !monster->undead_or_demonic()) + if ((!monster->alive() || !monster->undead_or_demonic()) + && !is_evil_god(monster->god)) + { return (retval); + } int hploss; @@ -150,7 +154,7 @@ int holy_word_monsters(coord_def where, int pow, int caster, if (attacker == monster) hploss = std::max(0, monster->hit_points / 2 - 1); else - hploss = roll_dice(2, 15) + (random2(pow) / 3); + hploss = roll_dice(4, 20) + (random2avg(pow, 2) / 3); if (hploss) simple_monster_message(monster, " convulses!"); @@ -172,10 +176,11 @@ int holy_word_monsters(coord_def where, int pow, int caster, if (attacker != NULL) behaviour_event(monster, ME_ANNOY, attacker->mindex()); - if (monster->speed_increment >= 25) - monster->speed_increment -= 20; - - monster->add_ench(ENCH_FEAR); + // Monsters with higher HD have less chance of being affected, + // and recover more quickly. Paralysis chances: + // HD10 or less = 100%, HD15 = 67%, HD20 = 50%, HD27 = 37% + if ((random2(monster->hit_dice) - 9) <= 0) + monster->add_ench(ENCH_PARALYSIS); } } else @@ -190,7 +195,7 @@ int holy_word(int pow, int caster, const coord_def& where, bool silent, { if (!silent && attacker) { - mprf("%s %s a Word of immense power!", + mprf("%s %s a Word of immense power, asking for The Shining One's aid!", attacker->name(DESC_CAP_THE).c_str(), attacker->conj_verb("speak").c_str()); } @@ -200,7 +205,7 @@ int holy_word(int pow, int caster, const coord_def& where, bool silent, los.update(); int r = 0; for (radius_iterator ri(&los); ri; ++ri) - r += holy_word_monsters(*ri, 0, caster, attacker); + r += holy_word_monsters(*ri, pow, caster, attacker); return (r); } diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc index e14c344..4fa47bb 100644 --- a/crawl-ref/source/item_use.cc +++ b/crawl-ref/source/item_use.cc @@ -5778,8 +5778,8 @@ void read_scroll(int slot) if (is_good_god(you.religion)) { - pow += (you.religion == GOD_SHINING_ONE) ? you.piety : - you.piety / 2; + pow += (you.religion == GOD_SHINING_ONE) ? you.piety / 2: + you.piety / 3; } const bool success = holy_word(pow, HOLY_WORD_SCROLL, you.pos(), diff --git a/crawl-ref/source/mon-place.cc b/crawl-ref/source/mon-place.cc index 3184e02..0466b97 100644 --- a/crawl-ref/source/mon-place.cc +++ b/crawl-ref/source/mon-place.cc @@ -1344,11 +1344,15 @@ static int _place_monster_aux(const mgen_data &mg, } } } - // 1 out of 7 non-priestly orcs are unbelievers. + // 1 out of 3 non-priestly orcs are unbelievers, or 1 in 6 in the mines. else if (mons_genus(mg.cls) == MONS_ORC) { - if (!one_chance_in(7)) + if ((player_in_branch(BRANCH_ORCISH_MINES) && !coinflip()) + || !one_chance_in(3)) + { mon->god = GOD_BEOGH; + } + } // The royal jelly belongs to Jiyva. else if (mg.cls == MONS_ROYAL_JELLY) -- 1.6.5.1