Members Chapter Previous Next

class CDXTile : public CDXSurface

This class name is somewhat deceptive given that a CDXTile object holds the bitmap information for all the tiles of a given map or sprite, rather than just one tile. CDXTile is derived from CDXSurface.

IMPORTANT NOTES: The bitmap file containing the tiles should have an empty tile at the start, this is because CDX treats the first tile to be transparent. Tiles should be stored from left to right down the bitmap and should fit exactly into the width of the bitmap, have a look at the tiles from one of the examples if this is unclear. Remember to set the colour key for the surface if you intend to draw the tiles transparently.

#include "cdxtile.h"