PALETTE - source-solutions/HELP GitHub Wiki

PALETTE


PALETTE [attrib, color]

Assigns a color to an attribute. All pixels with that attribute will change color immediately. If no parameters are specified, PALETTE resets to the initial setting.

Parameters

  • attrib is a numeric expression from [0 to 63].
  • color is a numeric expression between [0 and 255]

Notes

Colors are entered in compressed RGB format (lowest to highest bit). The red and green levels are each stored in three bits (0 to 7) while the blue level is stored in two bits (0 to 3). The easiest way to enter values is in octal (@BGR). For example, to set attribute to maximum blue, you would enter: PALETTE attribute, @300.

Errors

  • attrib or colour has a string value: Type mismatch.
  • attrib or colour is not in [0 to 32767]: Overflow
  • attrib or colour is not in range: Illegal function call
⚠️ **GitHub.com Fallback** ⚠️