diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-11-23 04:40:34 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-11-24 03:32:57 +0300 |
commit | 8e5861c3cfd41574351547a1a518efcf9007666a (patch) | |
tree | 8d941791c1bbd296b7125475fa0abb9581df632f /src/being.h | |
parent | 004aa3358c6efeb469045785baa891a449dde5a4 (diff) | |
download | manaplus-8e5861c3cfd41574351547a1a518efcf9007666a.tar.gz manaplus-8e5861c3cfd41574351547a1a518efcf9007666a.tar.bz2 manaplus-8e5861c3cfd41574351547a1a518efcf9007666a.tar.xz manaplus-8e5861c3cfd41574351547a1a518efcf9007666a.zip |
Add ability to play different animation depend on monster hp.
Disabled for legacy servers because monster hp unknown and
compilated hp can be wrong (version <= 0).
For usage need add to action tag attribute hp="xx"
Example:
<action name="stand" hp="50" imageset="base">
...
</action>
Here 50 mean 50% of health or less.
Default action tag mean hp=100
Diffstat (limited to 'src/being.h')
-rw-r--r-- | src/being.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/being.h b/src/being.h index 9ee60fcdf..1a5644929 100644 --- a/src/being.h +++ b/src/being.h @@ -767,6 +767,8 @@ class Being : public ActorSprite, public ConfigListener void attack2(Being *target = nullptr, bool keep = false, bool dontChangeEquipment = false); + void updatePercentHP(); + protected: /** * Sets the new path for this being. @@ -909,6 +911,7 @@ class Being : public ActorSprite, public ConfigListener bool mShop; bool mAway; bool mInactive; + unsigned mNumber; }; extern std::list<BeingCacheEntry*> beingInfoCache; |