SpriteBatch:addLayer
Adds a sprite to a batch created with an Array Texture.
spriteindex = SpriteBatch:addLayer( layerindex, x, y, r, sx, sy, ox, oy, kx, ky )
layerindex number The index of the layer to use for this sprite.
x (0) number The position to draw the sprite (x-axis).
y (0) number The position to draw the sprite (y-axis).
r (0) number Orientation (radians).
sx (1) number Scale factor (x-axis).
sy (sx) number Scale factor (y-axis).
ox (0) number Origin offset (x-axis).
oy (0) number Origin offset (y-axis).
kx (0) number Shearing factor (x-axis).
ky (0) number Shearing factor (y-axis).
spriteindex number The index of the added sprite, for use with SpriteBatch:set or SpriteBatch:setLayer.
spriteindex = SpriteBatch:addLayer( layerindex, quad, x, y, r, sx, sy, ox, oy, kx, ky )
layerindex number The index of the layer to use for this sprite.
quad Quad The subsection of the texture's layer to use when drawing the sprite.
x (0) number The position to draw the sprite (x-axis).
y (0) number The position to draw the sprite (y-axis).
r (0) number Orientation (radians).
sx (1) number Scale factor (x-axis).
sy (sx) number Scale factor (y-axis).
ox (0) number Origin offset (x-axis).
oy (0) number Origin offset (y-axis).
kx (0) number Shearing factor (x-axis).
ky (0) number Shearing factor (y-axis).
spriteindex number The index of the added sprite, for use with SpriteBatch:set or SpriteBatch:setLayer.
spriteindex = SpriteBatch:addLayer( layerindex, transform )
layerindex number The index of the layer to use for this sprite.
transform Transform A transform object.
spriteindex number The index of the added sprite, for use with SpriteBatch:set or SpriteBatch:setLayer.
spriteindex = SpriteBatch:addLayer( layerindex, quad, transform )
layerindex number The index of the layer to use for this sprite.
quad Quad The subsection of the texture's layer to use when drawing the sprite.
transform Transform A transform object.
spriteindex number The index of the added sprite, for use with SpriteBatch:set or SpriteBatch:setLayer.