There's no concise tutorial or code I can track down that could help explain to me how to call and control multiple 8x8 sprites as one. I'd like to use 4 8x8 spirtes as a larger character. There aren't many games that do this and I'm not yet good enough to really parse where in the code this gets described. If anyone knows where I could find this info I'd really appreciate it!
" spr n x y [w h] [flip_x] [flip_y]
draw sprite n (0..255) at position x,y
width and height are 1,1 by default and specify how many sprites wide to blit.
Colour 0 drawn as transparent by default (see palt())
flip_x=true to flip horizontally
flip_y=true to flip vertically"
From the manual. The w and h values control how many sprites you blit together. 2,2 for 16x16 pixels. Basically, you choose the top left sprite for the n value, and then blit right and down.
For example, "spr(32,0,0,2,2,true,false)"
for sprite 32 in the spritesheet, blitted right and down on the spritesheet for a 16x16 sprite, at point 0,0, flipped on the x-axis, but not flipped on the y.
Thank you! Because of course it's in the readme. :p
[Please log in to post a comment]