Difference between revisions of "NML:Alternative sprites"

From GRFSpecs
Jump to navigationJump to search
(content of nml r1625)
 
(add nav template)
Line 1: Line 1:
  +
{{NMLNavBlocksyntax}}
  +
 
A <code style="color:darkgreen">alt_sprites</code> block allows you to specify alternative 32bpp sprites that are drop-in replacements for some real sprites in your grf. The syntax is as follows:
 
A <code style="color:darkgreen">alt_sprites</code> block allows you to specify alternative 32bpp sprites that are drop-in replacements for some real sprites in your grf. The syntax is as follows:
   

Revision as of 16:37, 21 August 2011

Block Syntax

A alt_sprites block allows you to specify alternative 32bpp sprites that are drop-in replacements for some real sprites in your grf. The syntax is as follows:

alt_sprites(block_name, zoom_level[, filename]) {
	list of realsprites
}

block_name is the name of the replace/replace_new/fontglyph/spriteset-block for which you want to provide 32bpp sprites. zoom_level can be one of ZOOM_LEVEL_NORMAL, ZOOM_LEVEL_Z0, ZOOM_LEVEL_Z1 or ZOOM_LEVEL_Z2. Please note that ZOOM_LEVEL_NORMAL and ZOOM_LEVEL_Z2 are exactly the same. Specifying a filename is optional, it's only useful if you have multiple sprites in the same file. If every sprite is in a separate file you'll have to specify the filename for each realsprite anyway, so you can leave it out of the alt_sprites-block.