Think of a sprite as a 2D graphical bitmap image. The closest thing to explain it easily is to think of a spite like a GIF image. It doesn't need to be drawn by the CPU or graphics hardware in the same way as you have been trying to do in code. Instead it is a set sized image that is held in memory and can be manipulated, moved, scaled etc.
I would recommend you have a play around using AMOS to get a good understanding of sprites and how you can use them. While AMOS isn't the greatest basic programming language it does have a lot of direct support for sprites and the manipulation of them.
There are hardware limitations with sprites. All hardware has a maximum size it can handle to easily move and work with sprites. Coders get around this problem by building larger graphics using multiple sprites on screen and just moving the position of the sprites relative to each other when you want to move them around the screen.
You can also work with transparency within a sprite using something similar to a transparent colour in a gif file, or an alpha channel that removes pixels from the sprite that are a specific pixel colour.
Vector graphics in contrast are completely different. All that exists is the instructions explaining where the start and end points of a vector are on the screen and these end point co-ordinates can be changed to move the vector around the screen. A very different process, and it creates a completely different result.





Reply With Quote

