1.0.1 • Published 8 years ago

moray.js v1.0.1

Weekly downloads
1
License
ISC
Repository
-
Last release
8 years ago

moray.js

Sprite Animation Library

Animation Sample

Alt

Method

MethodDescription
setSet options
startStart the animation ( From the start option to end options )
stopStop at the current frame
resetFirst to return the frame

Options

// Option is required
let option = {
  start: { x: 0 , y: 0 },       // start frame (0 ~ N)
  end: { x: 0 , y: 0 },         // end frame (0 ~ N)
  frame: { column: 2, row: 1 }, // frame count (1 ~ N)
  fps: 100,                     // fps
  loop: true                    // loop flag (boolean)
}
let moray = new Moray(elm, option);

or

let moray = new Moray(elm);
moray.set(option);
1.0.1

8 years ago

1.0.0

8 years ago