From 6873831fa5c99f74609c60e2918692cdd46f1aa1 Mon Sep 17 00:00:00 2001 From: tom Date: Mon, 2 May 2016 22:31:59 -0500 Subject: reimplemented wandering --- inc/creature.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'inc/creature.hpp') 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 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; -- cgit v1.2.3