planar.MapSprite -- map hardware sprite to DMA channel (V2.0)
planar.MapSprite(id[, t])
This function maps the hardware sprite specified by id to a free sprite DMA channel. The hardware sprite specified by id must have been created using planar.CreateSprite() first.

Further parameters can be specified in the optional table argument. The following tags are currently recognized:

By default, planar.MapSprite() will choose a sprite DMA channel automatically. If you want to use a specific sprite DMA channel, you can set it using this tag. This must be a number between 1 and 7 (channel 0 is reserved for use by Intuition for the mouse pointer sprite). Note that if the sprite uses 16 colors you can only use channels 2, 4 or 6 because 16 color sprites occupy two adjacent sprite DMA channels.

This can be set to the identifier of a Hollywood display the sprite should appear on. This is normally not necessary and the sprite will just use the current Hollywood display.

Note that if the sprite DMA channel is automatically chosen by planar.MapSprite(), you can query the #ATTRSTATE attribute to find out the DMA channel your sprite has been mapped to after calling planar.MapSprite().

To unmap a hardware sprite from a DMA channel, use planar.UnmapSprite() See planar.UnmapSprite for details.

identifier of hardware sprite to map to DMA channel
optional: table containing further arguments (see above)
See planar.CreateSprite

Show TOC