From 386279f378d49f6dddb276fbfde92fe1444b6ea1 Mon Sep 17 00:00:00 2001 From: Tom Barrett Date: Fri, 1 May 2015 14:02:12 -0500 Subject: needs cleaning, hasnt been tested --- src/creature.cpp~ | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 src/creature.cpp~ (limited to 'src/creature.cpp~') diff --git a/src/creature.cpp~ b/src/creature.cpp~ new file mode 100644 index 0000000..15b6577 --- /dev/null +++ b/src/creature.cpp~ @@ -0,0 +1,47 @@ +#include "creature.h" + +Creature::Creature(Window m, std::string s) +{ + texture = loadTexture(s, m); + renderer = m.getRenderer(); + x=y=500; + + //For the test resource + xT=yT=300; +} + +void Creature::Behavior() +{ + //Detection + + //Priorities + + //Action + this->Action(); +} + +void Creature::Action() +{ + //if(isclose) + // eat//reproduce//etc; + + if(x==xT) + { + if(y