Tutorials: Sprite Construction


A picture must be formatted as a series of boxes. The first box contains only a single pixel that determines the sprite's offset from an objects x- and y-position. (This dot is usually placed near the feet of a walking character.) If the sprite has no offset (i.e. the offset is zero and the center point of the sprite is the top left corner), the box must still exist, but without a center pixel. The background color of the box determines the transparent color of the sprite. Since there is no tolerance (as it is sometimes called), each transparent pixel must be exactly the same color.

The sequence of frames is determined by the position of the top left pixel in each frame. The picture is scanned from left to right and from top to bottom. Here is an example of a rather odd arrangement for demonstration purposes:

Notice how the top and leftmost frame has only a single dot. The number inside each frame tells which order it would be sequenced using the above rules.

See Also...