SLUDGE

addOverlay


Syntax:

addOverlay (thisFile, atX, atY);

Purpose:

Loads an image from the file handle thisFile and overlays it onto the screen. Bright magenta (255, 0, 255 or #FF00FF) is used as the transparency colour (except for 32-bit images, where the alpha channel is used!), making it possible to add irregular shapes.

The values atX and atY define the top left corner of the area into which the image will be added. If the value of atX is CENTRE (or CENTER) the image will be added halfway across the window. If the value of atY is CENTRE (or CENTER) the image will be added halfway down the window.

Return value:

No return value.

Example:

sub init () {
   addOverlay ('someImage.tga', CENTER, CENTER);
}

See also:

File Handling

The Background Image

darkBackground

mixOverlay

parallaxAdd