summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/food.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-07 11:58:54 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-07 11:58:54 +0000
commit167ae03b160a0ccadd7934b2bfe557d491f1cb1f (patch)
treec1ee0ef626b416c5eee0f62082da72cb9f4137c3 /crawl-ref/source/food.cc
parent33dc7cedd5a65d3bd1ce8eff9006e4517a3390dd (diff)
downloadcrawl-ref-167ae03b160a0ccadd7934b2bfe557d491f1cb1f.tar.gz
crawl-ref-167ae03b160a0ccadd7934b2bfe557d491f1cb1f.zip
Another clean up, and add some new weapon speech.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6439 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/food.cc')
-rw-r--r--crawl-ref/source/food.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/crawl-ref/source/food.cc b/crawl-ref/source/food.cc
index 6c92065f09..b915203df7 100644
--- a/crawl-ref/source/food.cc
+++ b/crawl-ref/source/food.cc
@@ -1773,7 +1773,7 @@ void vampire_nutrition_per_turn(const item_def &corpse, int feeding)
// Human blood gives extra healing during feeding.
if (hp_amt >= duration)
hp_amt /= duration;
- else if (random2(duration) < hp_amt)
+ else if (x_chance_in_y(hp_amt, duration))
hp_amt = 1;
_heal_from_food(hp_amt, 0, one_chance_in(duration/2),
@@ -2259,7 +2259,7 @@ static int _determine_chunk_effect(int which_chunk_type, bool rotten_chunk)
// saprovores get rotting meat effect from clean chunks, since they
// love rotting meat.
if (wearing_amulet(AMU_THE_GOURMAND)
- && random2(GOURMAND_MAX) < you.duration[DUR_GOURMAND])
+ && x_chance_in_y(you.duration[DUR_GOURMAND], GOURMAND_MAX))
{
if (player_mutation_level(MUT_SAPROVOROUS) == 3)
{