Spritesheet - HermesPasser/Ramu GitHub Wiki
class
Spritesheet: Drawable
Description
Displays a region (spritesheet) of an image.
Constructor Parameters
Image Object
image: The image.Rect
sheetRect: The spritesheet to be displayed.int
x: Position in x.int
y: Position in y.int
width: Width.int
height: Height.bool
canDraw: Whether it will be drawn or not. (optional, default is true)
let img = Ramu.Utils.getImage("image.png");
let rec = new Rect(20, 20, 40, 40);
let sh = new Spritesheet(img, rec, 10, 10, 100, 100, true);