diff options
author | David Athay <ko2fan@gmail.com> | 2009-02-11 09:30:26 +0000 |
---|---|---|
committer | David Athay <ko2fan@gmail.com> | 2009-02-11 09:30:26 +0000 |
commit | 91111ca5d13072ea3b834e23835df9c077329e39 (patch) | |
tree | f0af8dd08b766164835cf9b5412a9aa3267dbad7 /src/simpleanimation.cpp | |
parent | 8046bb2626b30fecdcea54eb0aa3349cdb7d277b (diff) | |
parent | 63ac001daa7dfc0735dfefd9c2829c8786b4edaf (diff) | |
download | mana-client-91111ca5d13072ea3b834e23835df9c077329e39.tar.gz mana-client-91111ca5d13072ea3b834e23835df9c077329e39.tar.bz2 mana-client-91111ca5d13072ea3b834e23835df9c077329e39.tar.xz mana-client-91111ca5d13072ea3b834e23835df9c077329e39.zip |
Merge branch 'master' of git@gitorious.org:tmw/eathena
Diffstat (limited to 'src/simpleanimation.cpp')
-rw-r--r-- | src/simpleanimation.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/simpleanimation.cpp b/src/simpleanimation.cpp index 8abb4a67..48f2f6a5 100644 --- a/src/simpleanimation.cpp +++ b/src/simpleanimation.cpp @@ -19,15 +19,21 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "simpleanimation.h" - -#include "graphics.h" #include "log.h" +#include "simpleanimation.h" +#include "resources/animation.h" #include "resources/image.h" -#include "resources/resourcemanager.h" #include "resources/imageset.h" +#include "resources/resourcemanager.h" +SimpleAnimation::SimpleAnimation(Animation *animation): + mAnimation(animation), + mAnimationTime(0), + mAnimationPhase(0), + mCurrentFrame(mAnimation->getFrame(0)) +{ +} SimpleAnimation::SimpleAnimation(xmlNodePtr animationNode): mAnimationTime(0), @@ -43,7 +49,7 @@ SimpleAnimation::SimpleAnimation(xmlNodePtr animationNode): // Get animation frames for ( xmlNodePtr frameNode = animationNode->xmlChildrenNode; - frameNode != NULL; + frameNode; frameNode = frameNode->next) { int delay = XML::getProperty(frameNode, "delay", 0); |