summaryrefslogtreecommitdiff
path: root/src/being.h
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2007-02-20 20:55:37 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2007-02-20 20:55:37 +0000
commite99b6aaeb119feabfa2f7c3c49908625981e9708 (patch)
tree00f599c90443be884b9b8b51618552c2f8834f2d /src/being.h
parenteadbe0cb009b8c8fec622946f0b0109a2f07b1f1 (diff)
downloadMana-e99b6aaeb119feabfa2f7c3c49908625981e9708.tar.gz
Mana-e99b6aaeb119feabfa2f7c3c49908625981e9708.tar.bz2
Mana-e99b6aaeb119feabfa2f7c3c49908625981e9708.tar.xz
Mana-e99b6aaeb119feabfa2f7c3c49908625981e9708.zip
Now different sounds can play when a monster misses the player.
Diffstat (limited to 'src/being.h')
-rw-r--r--src/being.h19
1 files changed, 14 insertions, 5 deletions
diff --git a/src/being.h b/src/being.h
index 91913385..9dda42a7 100644
--- a/src/being.h
+++ b/src/being.h
@@ -141,13 +141,22 @@ 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 text The text that should appear.
- * @param time The amount of time the text should stay in milliseconds.
+ * @param amount The amount of damage.
*/
- void setDamage(Sint16 amount, Uint32 time);
+ virtual void
+ takeDamage(int amount);
+
+ /**
+ * Handles an attack of another being by this being.
+ *
+ * @param victim The attacked being.
+ * @param damage The amount of damage dealt (0 means miss).
+ */
+ virtual void
+ handleAttack(Being *victim, int damage);
/**
* Returns the name of the being.