summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/player.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-02-22 17:36:57 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-02-22 17:36:57 +0000
commit03725e818345745c8c383f339cc10c51a82ffdf0 (patch)
tree173b5973602b821ac515d4ed6b7b2ccfe1ec896b /crawl-ref/source/player.cc
parente23410c57e1a84fc01deacb8b09cd1389148f514 (diff)
downloadcrawl-ref-03725e818345745c8c383f339cc10c51a82ffdf0.tar.gz
crawl-ref-03725e818345745c8c383f339cc10c51a82ffdf0.zip
Clean up gourmand-related routines: only check for gourmand duration
instead of checking for wearing the amulet *and* gourmand duration, account for gourmand (both the amulet and the mutation) in the output screen, and treat gourmand (both the amulet and the mutation) consistently with regard to potions of blood. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9153 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/player.cc')
-rw-r--r--crawl-ref/source/player.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc
index 2bf3a2170f..15abd4d22b 100644
--- a/crawl-ref/source/player.cc
+++ b/crawl-ref/source/player.cc
@@ -1292,10 +1292,11 @@ bool player_can_smell()
return (you.species != SP_MUMMY);
}
-bool player_likes_chunks()
+bool player_likes_chunks(bool permanently)
{
return (player_mutation_level(MUT_GOURMAND)
- || player_mutation_level(MUT_CARNIVOROUS) > 0);
+ || player_mutation_level(MUT_CARNIVOROUS) > 0
+ || (!permanently && you.duration[DUR_GOURMAND] > 0));
}
// If temp is set to false, temporary sources or resistance won't be counted.