Shunter
2006.06.23, 08:51 PM
I'm using a camera control in my 2D platformer game (using BlitzMax if that matters) to 'handle' my image drawing; ie drawing images at (image.x - camera.x),(image.y - camera.y).
Then I had the idea to use layers, which also works OK; drawing to ((image.x*image.layer) - camera.x),((image.y*image.layer) - camera.y)
Now I'd like to add in zooming, and I seem to have hit a brick wall. I thought it would be something like (((image.x*image.layer) - camera.x)*size),(((image.y*image.layer) - camera.y)*size), but that doesn't seem to work right :cry: . I've tried a few other cominations, but no luck.
Does anyone have any advice?
Thanks in advance
Then I had the idea to use layers, which also works OK; drawing to ((image.x*image.layer) - camera.x),((image.y*image.layer) - camera.y)
Now I'd like to add in zooming, and I seem to have hit a brick wall. I thought it would be something like (((image.x*image.layer) - camera.x)*size),(((image.y*image.layer) - camera.y)*size), but that doesn't seem to work right :cry: . I've tried a few other cominations, but no luck.
Does anyone have any advice?
Thanks in advance