summaryrefslogtreecommitdiff
path: root/src/being.h
diff options
context:
space:
mode:
authorGuillaume Melquiond <guillaume.melquiond@gmail.com>2006-12-29 13:43:24 +0000
committerGuillaume Melquiond <guillaume.melquiond@gmail.com>2006-12-29 13:43:24 +0000
commit291ad04d5b5c4ab08d85eadde116f968cd579b77 (patch)
treee4dced5715a5d9792cfdc0455a6b3ee6d3116079 /src/being.h
parent3d404e743105bb9168c89e3451cf35d7d59120b1 (diff)
downloadmanaserv-291ad04d5b5c4ab08d85eadde116f968cd579b77.tar.gz
manaserv-291ad04d5b5c4ab08d85eadde116f968cd579b77.tar.bz2
manaserv-291ad04d5b5c4ab08d85eadde116f968cd579b77.tar.xz
manaserv-291ad04d5b5c4ab08d85eadde116f968cd579b77.zip
Physically split the server into one tmwserv-acount program (account +
chat + database) and multiple tmwserv-game programs (selected with respect to the maps). Cleaned the repository by moving server-specific source files into dedicated directories.
Diffstat (limited to 'src/being.h')
-rw-r--r--src/being.h29
1 files changed, 10 insertions, 19 deletions
diff --git a/src/being.h b/src/being.h
index bf35d9fc..80d5d696 100644
--- a/src/being.h
+++ b/src/being.h
@@ -31,7 +31,7 @@
#include "object.h"
#include "utils/countedptr.h"
-class Controller;
+class MapComposite;
/**
* Element attribute for beings, actors and items.
@@ -189,41 +189,32 @@ class Being : public MovingObject
/**
* Takes a damage structure, computes the real damage based on the
* stats, deducts the result from the hitpoints and adds the result to
- * the HitsTaken list
+ * the HitsTaken list.
*/
- virtual void damage(Damage);
+ void damage(Damage);
/**
- * Get the damage list
+ * Gets the damage list.
*/
- Hits getHitsTaken() const
+ Hits const &getHitsTaken() const
{ return mHitsTaken; }
/**
- * Clears the hit list.
- * When a controller is set, updates the controller.
+ * Clears the damage list.
*/
- virtual void
- update();
-
- virtual void
- performAttack(MapComposite*);
+ void clearHitsTaken()
+ { mHitsTaken.clear(); }
/**
- * Notification that this being is now possessed by the given
- * controller. This means that events regarding what happens to this
- * being should be send there.
+ * Performs an attack.
*/
- void
- possessedBy(Controller *controller)
- { mController = controller; }
+ void performAttack(MapComposite *);
private:
Being(Being const &rhs);
Being &operator=(Being const &rhs);
Statistics mStats; /**< stats modifiers or computed stats */
- Controller *mController;
int mHitpoints; /**< Hitpoints of the being */