Macaw OS C reference

Module Sprites and the map

#include <macaw.h>

Functions

spr
Draws one 16 x 16 sprite from your program's sprite sheet, gfx.pxl.
sprex
Draws a block of sprites together, flipped if you like.
sspr
Draws any rectangle of the sprite sheet, given in pixels rather than sprites.
fget
Reads a sprite's flags, from gfx.flags.
fset
Sets all 8 of a sprite's flags at once, while your program runs.
map
Draws tiles from your program's map, map.map, each one a 16 x 16 sprite.
mget
Reads one tile of the map.
mset
Changes one tile of the map while your program runs.
mapwidth
Tells you how many tiles across a map layer is.
mapheight
Tells you how many tiles down a map layer is.
maplayers
Tells you how many layers your map has.
maplayername
Gives you the name of one of the map's layers, to pass to map or mget.