By salin
Date 2009-04-09 12:51
Hi.
How can I load a multi-row tileset? For example a 256x256 image containing 256 square tiles (16 pixels). If I put 16,16 into the load method it only loads the first row, if it put 256,256 into the load method it doesn't work altho' the method description implies that it should:
self.load_tiles(window, filename_or_rmagick_image, tile_width, tile_height, hard_borders): tile_width is either the width of one tile in pixels or the number of columns, tile_height is its vertical equivalent
Any suggestions? Obviously I could just have my tileset as one very long image 16 pixels in height but would be nice not to have to do this.
Cheers.
By jlnr (dev)
Date 2009-04-09 13:02
Edited 2009-04-09 15:47
(Whoops, there was a bad typo in the Reference. It can either be the width of a column, or the number of columns multiplied by -1. Corrected that now, sorry :))
So in your case, both 16,16 and -16,-16 are correct and should do just what you are trying to achieve. Can you show the line of code or the image that are causing the problem?
Loading...