From 37dddc69c063b655d028bdb33e5ab831b4af8a55 Mon Sep 17 00:00:00 2001 From: Vsevolod Kozlov Date: Fri, 6 Nov 2009 11:48:29 +0300 Subject: Add actor::petrified, which replaces mons_is_petrified. Signed-off-by: Robert Vollmert --- crawl-ref/source/beam.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'crawl-ref/source/beam.cc') diff --git a/crawl-ref/source/beam.cc b/crawl-ref/source/beam.cc index 48a28d0076..af014304af 100644 --- a/crawl-ref/source/beam.cc +++ b/crawl-ref/source/beam.cc @@ -2665,9 +2665,9 @@ bool mass_enchantment( enchant_type wh_enchant, int pow, int origin, void bolt::apply_bolt_paralysis(monsters *monster) { - if (!monster->has_ench(ENCH_PARALYSIS) + if (!monster->paralysed() && monster->add_ench(ENCH_PARALYSIS) - && (!monster->has_ench(ENCH_PETRIFIED) + && (!monster->petrified() || monster->has_ench(ENCH_PETRIFYING))) { if (simple_monster_message(monster, " suddenly stops moving!")) @@ -2685,7 +2685,7 @@ void bolt::apply_bolt_paralysis(monsters *monster) void bolt::apply_bolt_petrify(monsters *monster) { int petrifying = monster->has_ench(ENCH_PETRIFYING); - if (monster->has_ench(ENCH_PETRIFIED)) + if (monster->petrified()) { // If the petrifying is not yet finished, we can force it to happen // right away by casting again. Otherwise, the spell has no further @@ -5192,7 +5192,7 @@ mon_resist_type bolt::apply_enchantment_to_monster(monsters* mon) && !mons_is_stationary(mon) && mon->add_ench(ENCH_HASTE)) { - if (!mon->paralysed() && !mons_is_petrified(mon) + if (!mon->paralysed() && !mon->petrified() && simple_monster_message(mon, " seems to speed up.")) { obvious_effect = true; -- cgit v1.2.3-54-g00ecf