From: Tegmine Date: Sat, 3 Mar 2012 21:51:23 +0000 (-0600) Subject: Added constructors for Actor. X-Git-Url: http://git.mmlx.us/?a=commitdiff_plain;h=0dcbb273fe47852b76c83250df577d9651ac9f61;p=IvanGame.git Added constructors for Actor. --- diff --git a/.gitignore b/.gitignore index f03e459..59029c4 100644 --- a/.gitignore +++ b/.gitignore @@ -31,6 +31,7 @@ SDL.dll *.sbr *.sdf *.opensdf +*.filters ipch/ obj/ [Bb]in diff --git a/Actor.cpp b/Actor.cpp index 54c636e..ad68834 100644 --- a/Actor.cpp +++ b/Actor.cpp @@ -7,3 +7,17 @@ Actor::Actor(Animation *anim): mAnimations.push_back(anim); } +Actor::Actor(std::vector anims): + mFrame(0), + mCurrentAnimation(0) +{ + mAnimations = anims; +} + +Actor::Actor(std::vector anims): + mFrame(0), + mCurrentAnimation(0) +{ + for(int i=0; i anims); + Actor(std::vector anims); int mFrame;/**< The frame # */ int mCurrentAnimation;/**< Index to the current loaded animation */ std::vector mAnimations;/**< Vector of pointers to all of this sprite's Animations */