summaryrefslogtreecommitdiff
path: root/src/being.h
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2007-03-11 19:59:55 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2007-03-11 19:59:55 +0000
commitfc63e88f869919a8b035a5c41db8d05626526bde (patch)
tree8f1928d082ebbffc549c712a3f406c2141f43e01 /src/being.h
parent7b0f0ec315e66dcbdda58ada8b09a59bc5dcf6c9 (diff)
downloadMana-fc63e88f869919a8b035a5c41db8d05626526bde.tar.gz
Mana-fc63e88f869919a8b035a5c41db8d05626526bde.tar.bz2
Mana-fc63e88f869919a8b035a5c41db8d05626526bde.tar.xz
Mana-fc63e88f869919a8b035a5c41db8d05626526bde.zip
Merged 0.0 changes from revision 3065 to 3177 to trunk.
Diffstat (limited to 'src/being.h')
-rw-r--r--src/being.h24
1 files changed, 19 insertions, 5 deletions
diff --git a/src/being.h b/src/being.h
index 3c6b14c6..c3cba247 100644
--- a/src/being.h
+++ b/src/being.h
@@ -43,12 +43,17 @@ class Map;
class Graphics;
class Spriteset;
+/**
+ * A position along a being's path.
+ */
struct PATH_NODE
{
/**
* Constructor.
*/
- PATH_NODE(unsigned short x, unsigned short y);
+ PATH_NODE(unsigned short x, unsigned short y):
+ x(x), y(y)
+ { }
unsigned short x;
unsigned short y;
@@ -148,13 +153,19 @@ class Being : public Sprite
void setSpeech(const std::string &text, Uint32 time);
/**
- * Puts a damage bubble above this being for the specified amount
- * of time.
+ * Puts a damage bubble above this being for the specified amount of
+ * time.
*
* @param amount The amount of damage.
- * @param time The amount of time the text should stay in milliseconds.
*/
- void setDamage(Sint16 amount, Uint32 time);
+ virtual void
+ takeDamage(int amount);
+
+ /**
+ * Handles an attack of another being by this being.
+ */
+ virtual void
+ handleAttack();
/**
* Returns the name of the being.
@@ -384,6 +395,9 @@ class Being : public Sprite
Sint16 mStepX, mStepY;
Uint16 mStepTime;
+
+ static int instances; /**< Number of Being instances */
+ static Spriteset *emotionset; /**< Emoticons used by beings */
};
#endif