Difference between revisions of "NML:Warnings"

From GRFSpecs
Jump to navigationJump to search
(add nav template)
m (only changed headings)
 
(One intermediate revision by one other user not shown)
Line 4: Line 4:
   
 
==IMAGE at [x: X, y: Y]: I of J pixels (K%) are pure white'''==
 
==IMAGE at [x: X, y: Y]: I of J pixels (K%) are pure white'''==
This warning is generated when pixels with palette index 255, or RGB colour 0xFFFFFF, are found. These so-called pure white pixels are not used by OpenTTD, or TTDPatch, as they do not work with colour remaps such as the "transparency" colour remap. The pure white is used around the sprites in the PCX files that GRFCodec generates, which made pure white images with sprites common in NewGRF development. As such the pure white pixel test is also a way to detect so cases where the position or size of the sprite is incorrect, i.e. when it covers the white pixels around the sprite.
+
This warning is generated when pixels with palette index 255, or RGB colour 0xFFFFFF, are found. These so-called pure white pixels are not used by OpenTTD as they do not work with colour remaps such as the "transparency" colour remap. The pure white is used around the sprites in the image files that GRFCodec generates, which made pure white images with sprites common in NewGRF development. As such the pure white pixel test is also a way to detect so cases where the position or size of the sprite is incorrect, i.e. when it covers the white pixels around the sprite.
  +
  +
==Path "FILENAME" at the file system does not match path "FILENAME" given in the input (case mismatch in the last component)==
  +
This warning is generated when the filename given in the source (image or sound file) does not match the capitalization as found in the file system.
  +
  +
=="FILENAME", line X: Block 'BLOCKNAME' is not referenced, ignoring.==
  +
This warning is issued when NML detects a code block in the quoted file, at the given line number, which will have no effect as it is never referenced.

Latest revision as of 22:28, 20 February 2021

Sometimes NML gives warnings that might be cryptic or you have no idea why they are given. This section will list these warnings.

IMAGE at [x: X, y: Y]: I of J pixels (K%) are pure white

This warning is generated when pixels with palette index 255, or RGB colour 0xFFFFFF, are found. These so-called pure white pixels are not used by OpenTTD as they do not work with colour remaps such as the "transparency" colour remap. The pure white is used around the sprites in the image files that GRFCodec generates, which made pure white images with sprites common in NewGRF development. As such the pure white pixel test is also a way to detect so cases where the position or size of the sprite is incorrect, i.e. when it covers the white pixels around the sprite.

Path "FILENAME" at the file system does not match path "FILENAME" given in the input (case mismatch in the last component)

This warning is generated when the filename given in the source (image or sound file) does not match the capitalization as found in the file system.

"FILENAME", line X: Block 'BLOCKNAME' is not referenced, ignoring.

This warning is issued when NML detects a code block in the quoted file, at the given line number, which will have no effect as it is never referenced.