summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/fight.cc
diff options
context:
space:
mode:
authorVsevolod Kozlov <zaba@thorium.homeunix.org>2009-11-06 11:48:29 +0300
committerRobert Vollmert <rvollmert@gmx.net>2009-11-06 09:56:26 +0100
commit37dddc69c063b655d028bdb33e5ab831b4af8a55 (patch)
tree55f621318adec99bda23eb02da3f8895381cd80e /crawl-ref/source/fight.cc
parentdbdfb48c0639aa101f25d210496e66bd6326873b (diff)
downloadcrawl-ref-37dddc69c063b655d028bdb33e5ab831b4af8a55.tar.gz
crawl-ref-37dddc69c063b655d028bdb33e5ab831b4af8a55.zip
Add actor::petrified, which replaces mons_is_petrified.
Signed-off-by: Robert Vollmert <rvollmert@gmx.net>
Diffstat (limited to 'crawl-ref/source/fight.cc')
-rw-r--r--crawl-ref/source/fight.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/crawl-ref/source/fight.cc b/crawl-ref/source/fight.cc
index 003b546b59..c1b4217e97 100644
--- a/crawl-ref/source/fight.cc
+++ b/crawl-ref/source/fight.cc
@@ -321,7 +321,7 @@ unchivalric_attack_type is_unchivalric_attack(const actor *attacker,
unchivalric = UCAT_PETRIFYING;
// petrified
- if (def && mons_is_petrified(def))
+ if (defender->petrified())
unchivalric = UCAT_PETRIFIED;
// paralysed
@@ -1685,7 +1685,7 @@ int melee_attack::player_apply_monster_ac(int damage)
damage -= random2(1 + defender->armour_class());
}
- if (mons_is_petrified(defender_as_monster()))
+ if (defender->petrified())
damage /= 3;
return (damage);