From ce6b35d717de85a7ac45fa98197edf13e1820c8a Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 8 May 2015 17:41:48 -0500 Subject: added removal of resources once eaten, from the L and R vector creatures that done move don't die right now, we need them to wander if they dont have a priority **difficult** --- src/resource.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/resource.cpp') diff --git a/src/resource.cpp b/src/resource.cpp index 6a228fe..4f12e2d 100644 --- a/src/resource.cpp +++ b/src/resource.cpp @@ -8,6 +8,8 @@ Resource::Resource(Window m, std::string s) //Constructor //Initialized random position coordinates yPosition = rand()%800; xPosition = rand()%1200; + + amount = 100; } Resource::Resource(Window m, std::string s, Location z) @@ -17,6 +19,8 @@ Resource::Resource(Window m, std::string s, Location z) yPosition = z.y; xPosition = z.x; + + amount = 100; } Location Resource::getLocation() //Returns resource object -- cgit v1.2.3