29 #ifndef NOMLIB_ANIMATED_SPRITE_HPP
30 #define NOMLIB_ANIMATED_SPRITE_HPP
37 #include "nomlib/config.hpp"
38 #include "nomlib/graphics/sprite/SpriteBatch.hpp"
39 #include "nomlib/system/AnimationTimer.hpp"
85 int32
frame (
void )
const;
88 AnimatedSprite::AnimationStyle
style (
void )
const;
91 AnimatedSprite::AnimationStatus
status (
void )
const;
157 #endif // include guard defined
void initialize(void)
Initialize values to their respective defaults.
Extended bitmap object rendering – utilizes sprite sheets.
void play(void)
Play the animation.
virtual ~AnimatedSprite(void)
Destructor.
int32 max_frames
Total number of animation frames.
int32 frame_inc(void) const
Get the frame increment value of this object.
AnimatedSprite::AnimationStatus status(void) const
Get the current status of this animation.
void unpause(void)
Un-pause the animation playback.
void setMaxFrames(int32 max)
Set the total number of animated frames for this object.
void setCurrentFrame(int32 frame)
int32 total_frames(void) const
Get the maximum number of animation frames for this object.
int32 current_frame
Current animation frame.
void update_animation(void)
Updates the playback of the animation.
enum AnimatedSprite::AnimationStatus animation_status
Status info.
AnimationTimer fps
Keeps record of our current tick and frame rate (think: frame delay)
int32 frame(void) const
Get the current frame of this object.
void setAnimationStatus(AnimatedSprite::AnimationStatus status)
Set a new status state for this object.
Specialized class container for the creation of sprite sheets via RFC 4627 JSON-compliant file input...
void setAnimationStyle(AnimatedSprite::AnimationStyle style)
Set a new style of animation for this object.
enum AnimatedSprite::AnimationStyle animation_style
Animation playback logic.
void setFrameRate(int32 rate)
void setFrameIncrement(int32 increment)
Set the increment value of each animated frame of this object.
AnimatedSprite::AnimationStyle style(void) const
Get the current animation style for this object.
int32 frame_increment
Value that we increment the current_frame by.
void pause(void)
Pause the animation playback.
void stop(void)
Stop the animation playback.