-/*
- * SimpleAnimation.h
- *
- * Created on: Aug 11, 2012
- * Author: holy
- */
-
#ifndef GRAPHICS_SIMPLEANIMATION_H_
#define GRAPHICS_SIMPLEANIMATION_H_
static const int TYPE_ID = 408;
public:
- SimpleAnimation()
- : numFrames(0), col(0), row(0) { }
- SimpleAnimation(const Sprite *sprite, int frameTime, int numFrames, int col = 0, int row = 0, bool repeat = false)
- : Animation(sprite, frameTime, repeat), numFrames(numFrames), col(col), row(row) { }
+ SimpleAnimation();
+ SimpleAnimation(const Sprite *sprite, int frameTime, int numFrames,
+ int col = 0, int row = 0, bool repeat = false);
public:
void SetNumFrames(int n) { numFrames = n; }
static void Construct(void *);
protected:
- virtual int NumFrames() const { return numFrames; };
- virtual int Col(int frame) const { return col; }
- virtual int Row(int frame) const { return row + frame; }
+ virtual int NumFrames() const;
+ virtual int Col(int frame) const;
+ virtual int Row(int frame) const;
private:
int numFrames;
}
-#endif /* GRAPHICS_SIMPLEANIMATION_H_ */
+#endif