summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/fight.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-23 14:28:16 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-23 14:28:16 +0000
commitee70db5d6a4c06918ae40c5110f2e5390dfc27ea (patch)
treec6a2f8fbe594e23a9d5ec250952b69e9f85afa9c /crawl-ref/source/fight.cc
parent26f69a4fe082aa588e0e2f5f8bccd7114a2ef688 (diff)
downloadcrawl-ref-ee70db5d6a4c06918ae40c5110f2e5390dfc27ea.tar.gz
crawl-ref-ee70db5d6a4c06918ae40c5110f2e5390dfc27ea.zip
Remove unused ravenous hunger state, and clean up food state checks a
bit more. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4535 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/fight.cc')
-rw-r--r--crawl-ref/source/fight.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/crawl-ref/source/fight.cc b/crawl-ref/source/fight.cc
index 7290bb752d..0bf23ee931 100644
--- a/crawl-ref/source/fight.cc
+++ b/crawl-ref/source/fight.cc
@@ -187,13 +187,13 @@ static int calc_your_to_hit_unarmed(int uattack = UNAT_NO_ATTACK,
if (vampiric)
{
- if (you.hunger_state <= HS_STARVING)
+ if (you.hunger_state == HS_STARVING)
your_to_hit += 2;
else if (you.hunger_state < HS_SATIATED)
your_to_hit += 1;
}
}
- else if (you.species != SP_VAMPIRE && you.hunger_state <= HS_STARVING)
+ else if (you.species != SP_VAMPIRE && you.hunger_state == HS_STARVING)
your_to_hit -= 3;
your_to_hit += slaying_bonus(PWPN_HIT);
@@ -1308,7 +1308,7 @@ int melee_attack::player_apply_misc_modifiers(int damage)
if (you.duration[DUR_MIGHT] > 1)
damage += 1 + random2(10);
- if (you.hunger_state <= HS_STARVING && you.species != SP_VAMPIRE)
+ if (you.species != SP_VAMPIRE && you.hunger_state == HS_STARVING)
damage -= random2(5);
return (damage);
@@ -2677,7 +2677,7 @@ int melee_attack::player_to_hit(bool random_factor)
your_to_hit += slaying_bonus(PWPN_HIT);
// hunger penalty
- if (you.hunger_state <= HS_STARVING)
+ if (you.hunger_state == HS_STARVING)
your_to_hit -= 3;
// armour penalty