28 #ifndef HPL_IMAGE_ENTITY_H 29 #define HPL_IMAGE_ENTITY_H 31 #include "common/array.h" 32 #include "hpl1/engine/graphics/GraphicsTypes.h" 33 #include "hpl1/engine/scene/Entity2D.h" 41 class cImageEntityData;
42 class cImageAnimation;
49 const cRect2f &GetBoundingBox();
50 bool UpdateBoundingBox();
51 tString GetEntityType() {
return "ImageEntity"; }
55 void UpdateLogic(
float afTimeStep);
59 bool LoadEntityData(
tString asDataName,
int alAnimNum = 0);
66 bool SetAnimation(
const tString &asName,
bool abLoop =
true);
67 const tString &GetCurrentAnimation()
const;
68 bool AnimationIsLooped() {
return mbLoopAnimation; }
69 bool AnimationIsPlaying();
72 void SetAnimationSpeed(
float afSpeed) { mfAnimSpeed = afSpeed; }
73 float GetAnimationSpeed() {
return mfAnimSpeed; }
75 void SetFrameNum(
float afFrame) { mfFrameNum = afFrame; }
76 float GetFrameNum() {
return mfFrameNum; }
79 void SetAnimationPaused(
bool abX) { mbAnimationPaused = abX; }
80 bool GetAnimationPaused() {
return mbAnimationPaused; }
82 void SetFlipH(
bool abX);
83 bool GetFlipH() {
return mbFlipH; }
84 void SetFlipV(
bool abX);
85 bool GetFlipV() {
return mbFlipV; }
90 void SetAlpha(
float afX);
91 float GetAlpha() {
return mfAlpha; }
93 void Flash(
float afAdd);
95 bool IsCollidable() {
return mbCollidable; }
108 bool mbAutoDeleteData;
114 bool mbRotationHasChanged;
115 bool mbSizeHasChanged;
116 float mfCurrentAngle;
123 bool mbAnimationPaused;
124 bool mbLoopAnimation;
140 #endif // HPL_IMAGE_ENTITY_H
Definition: ImageEntityData.h:57
T * iterator
Definition: array.h:54
Definition: ImageEntityData.h:70
Definition: Resources.h:160
Definition: Entity2D.h:39
Definition: tinyxml.h:864
Definition: Graphics.h:46
Definition: ImageEntity.h:44