diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-08 21:31:51 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-08 21:31:51 +0000 |
commit | ca54ca53590788e28c47f0ea7f6c072d65a640d9 (patch) | |
tree | 4bcfe3c14e06d51289054a5dde3e28d4fdf4abca /crawl-ref/source/food.cc | |
parent | 1b08247fbd1c4a95902188cd01e5510e8c2e79d3 (diff) | |
download | crawl-ref-ca54ca53590788e28c47f0ea7f6c072d65a640d9.tar.gz crawl-ref-ca54ca53590788e28c47f0ea7f6c072d65a640d9.zip |
Make vampires' spell (and ability) hunger dependent on their hunger state.
Thirsty: 75%
Very thirsty: 50%
Near Bloodless: 25%
Bloodless: None
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4933 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/food.cc')
-rw-r--r-- | crawl-ref/source/food.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/crawl-ref/source/food.cc b/crawl-ref/source/food.cc index 77b99b3569..cccbf8bcbc 100644 --- a/crawl-ref/source/food.cc +++ b/crawl-ref/source/food.cc @@ -72,11 +72,14 @@ static void _heal_from_food(int hp_amt, int mp_amt, bool unrot, ************************************************** */ -void make_hungry( int hunger_amount, bool suppress_msg ) +void make_hungry( int hunger_amount, bool suppress_msg, bool allow_reducing ) { if (you.is_undead == US_UNDEAD) return; + if (allow_reducing) + hunger_amount = calc_hunger(hunger_amount); + if (hunger_amount == 0 && !suppress_msg) return; @@ -1842,7 +1845,7 @@ int you_min_hunger() if (you.is_undead == US_UNDEAD) return 6000; - // vampires can never starve to death + // Vampires can never starve to death. if (you.species == SP_VAMPIRE) return 701; |