#include "creature.hpp" Creature::Creature(Window m, std::string s) //Constructor { texture = loadTexture(s, m); renderer = m.getRenderer(); health = 100; hunger = 0; //initializes random start coordinates for creature, target position is equivalent to it's position yPosition=yTarget=rand()%800; xPosition=xTarget=rand()%1200; } void Creature::Behavior() { health-=1; //Decrements health each time a behavior is executed this->Priority(); //Checks which action has priority (doesn't really do this right now) if(this->Action()) { health+=10; } } void Creature::Priority() { //Traverses location vector, if object at [i] is resource (2), then creature's target coordinates are set int i; for(i=0;ixTarget) { if(yPosition