diff options
author | tom <tom@ground-control> | 2016-05-02 22:31:59 -0500 |
---|---|---|
committer | tom <tom@ground-control> | 2016-05-02 22:31:59 -0500 |
commit | 6873831fa5c99f74609c60e2918692cdd46f1aa1 (patch) | |
tree | b48b25f3c26b6051dc7c7d0c52390c35d4060c9a /inc | |
parent | e7cac5098145d75a680e35787f7c504caf16965b (diff) |
reimplemented wandering
Diffstat (limited to 'inc')
-rw-r--r-- | inc/creature.hpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/inc/creature.hpp b/inc/creature.hpp index 7da82e5..c3d5fdb 100644 --- a/inc/creature.hpp +++ b/inc/creature.hpp @@ -12,8 +12,9 @@ class Creature: public Entity void Behavior(); void Action(); void Priority(); + void Move(Location l); void giveN(list<Entity*> n){N = n;}; - + Location getLocation(){return L;}; double Distance(Location A, Location B){return sqrt(pow(A.x-B.x,2)+pow(A.y-B.y,2));}; int getHealth(){return health;}; @@ -22,6 +23,8 @@ class Creature: public Entity private: bool hasTarget; + bool wander; + Location wTarget; int health; int maxHealth; int hunger; |