Hmm...damn...looks like I might have to have a double sized tileset. I do have a couple of ideas though.
How about going through each pixel of the 40x70 pixel tile (on the source surface), check the colour, and if it's not purple (the transparent colour), then blit/fill a 1x1 black pixel on the screen corresponding to that location? Pseudo code:
Or would this be really really really slow?Code:For x = 1 to 40 For y = 1 to 70 If not functiontogetcolourfromsource(x,y) = vbMagenta then blt to screenx/screeny from x/y Else 'this pixel is transparent - don't blit it ! End if Next y Next x
Another idea... What if I blitted the tile normally, but also sortof combined that with the fill command? (so it blit's it transparently, and fills the non-transparent area) Just a wild idea...




Reply With Quote