Cycles the x value of the background-position of an element to create sprite animations. Helpful for creating javascript game animations or ajax loadings spinners.
First set your image up to be a sequence of equal-width, horizontal frames.
var animation = new SpriteAnimation('animation',{ frameWidth: 80, frames: 4, frameRate: 120 });
View the MooDoc for usage and examples.
A note on comments here: These comments are moderated. No comments will show up until they are approved. Comments that are not productive (i.e. inflammatory, rude, etc) will not be approved.
Found a bug in this plugin? Please report it this repository's Github Issues.
blog comments powered by Disqus