From 65fe4389269de4c14c9b9adbc6ef0308f2059dbd Mon Sep 17 00:00:00 2001 From: dolorous Date: Thu, 8 Jan 2009 23:01:33 +0000 Subject: Clean up the rotting routines a bit. For the record, rotting attacks from monsters currently have the same problem that draining attacks used to, due to monsters::rot()'s directly modifying the monster's max HP, as well as its directly calling monsters::hurt(). git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8340 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/externs.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'crawl-ref/source/externs.h') diff --git a/crawl-ref/source/externs.h b/crawl-ref/source/externs.h index 86d93be0d4..ea5e82a2e2 100644 --- a/crawl-ref/source/externs.h +++ b/crawl-ref/source/externs.h @@ -334,9 +334,10 @@ public: virtual bool can_mutate() const = 0; virtual bool can_safely_mutate() const = 0; virtual bool mutate() = 0; - virtual int hurt(const actor *attacker, int amount, - beam_type flavour = BEAM_MISSILE, - bool cleanup_dead = true) = 0; + virtual void rot(actor *attacker, int rotlevel, int immed_rot) = 0; + virtual int hurt(const actor *attacker, int amount, + beam_type flavour = BEAM_MISSILE, + bool cleanup_dead = true) = 0; virtual void heal(int amount, bool max_too = false) = 0; virtual void banish(const std::string &who = "") = 0; virtual void blink(bool allow_partial_control = true) = 0; @@ -347,7 +348,6 @@ public: virtual void petrify(actor *attacker, int strength) = 0; virtual void slow_down(actor *attacker, int strength) = 0; virtual void confuse(actor *attacker, int strength) = 0; - virtual void rot(actor *attacker, int rotlevel, int immediate_rot) = 0; virtual void expose_to_element(beam_type element, int strength = 0) = 0; virtual void drain_stat(int stat, int amount, actor* attacker) { } virtual void put_to_sleep(int power = 0) { }; @@ -1070,8 +1070,8 @@ public: void petrify(actor *, int str); void slow_down(actor *, int str); void confuse(actor *, int strength); - void rot(actor *agent, int rotlevel, int immed_rot); void heal(int amount, bool max_too = false); + void rot(actor *attacker, int rotlevel, int immed_rot); int hurt(const actor *attacker, int amount, beam_type flavour = BEAM_MISSILE, bool cleanup_dead = true); @@ -1499,7 +1499,7 @@ public: void petrify(actor *, int str); void slow_down(actor *, int str); void confuse(actor *, int strength); - void rot(actor *agent, int rotlevel, int immed_rot); + void rot(actor *, int rotlevel, int immed_rot); int hurt(const actor *attacker, int amount, beam_type flavour = BEAM_MISSILE, bool cleanup_dead = true); -- cgit v1.2.3-54-g00ecf