getSprite method

Sprite getSprite(
  1. int row,
  2. int column
)

Gets the sprite in the position (row, column) on the sprite sheet grid.

This is lazily computed and cached for your convenience.

Implementation

Sprite getSprite(int row, int column) {
  return getSpriteById(row * columns + column);
}