public void parse(Parser context, Element xmlElement) { int height = Integer.parseInt(getValue(xmlElement)); if (sourceImage == null) throw ResourceException.syntaxException(); tileRows = sourceImage.getHeight() / height; tileIndex = 0; updateTiles(); }
public void parse(Parser context, Element xmlElement) { int width = Integer.parseInt(getValue(xmlElement)); if (sourceImage == null) throw ResourceException.syntaxException(); tileCols = sourceImage.getWidth() / width; tileIndex = 0; updateTiles(); }