From a10146ff5a744a2add4b50d697f28bc785ba2217 Mon Sep 17 00:00:00 2001 From: dolorous Date: Sun, 17 May 2009 01:29:38 +0000 Subject: When using Elyvilon's weapon destruction against missiles, count each missile individually, as we do with Nemelex already. Also, increase the value of large rocks; they're mundane, but they do massive damage, so they should be worth more than ordinary darts or stones. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9787 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/religion.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'crawl-ref/source/religion.cc') diff --git a/crawl-ref/source/religion.cc b/crawl-ref/source/religion.cc index 7217147444..d7fb25671a 100644 --- a/crawl-ref/source/religion.cc +++ b/crawl-ref/source/religion.cc @@ -3872,7 +3872,6 @@ static bool _destroyed_valuable_weapon(int value, int type) return (true); // Medium valuable items are more likely to net piety at low piety. - // This includes missiles in sufficiently large quantities. if (random2(value) >= random2(100) && one_chance_in(1 + you.piety / 50)) { @@ -3915,7 +3914,8 @@ bool ely_destroy_weapons() continue; } - const int value = item_value(item, true); + // item_value() multiplies by quantity. + const int value = item_value(item, true) / item.quantity; #ifdef DEBUG_DIAGNOSTICS mprf(MSGCH_DIAGNOSTICS, "Destroyed weapon value: %d", value); #endif @@ -6303,7 +6303,8 @@ static void _give_sac_group_feedback(int which) static piety_gain_t _sacrifice_one_item_noncount(const item_def& item) { piety_gain_t relative_piety_gain = PIETY_NONE; - // item_value() multiplies by quantity + + // item_value() multiplies by quantity. const int value = item_value(item) / item.quantity; switch (you.religion) -- cgit v1.2.3-54-g00ecf