# sm.color

A <strong>color</strong> is represented using a red, green, blue and alpha component. Colors are prominently used for blocks and parts that are colored by the <em>Paint Tool</em>.

**Kind:** API page

**Environments:** Game, Terrain

## Game

[Open the full Game reference](../Game-Script-Environment/Static-Functions/sm.color.md)

To create one, use [sm.color.new](../Game-Script-Environment/Static-Functions/sm.color.md#new). It is possible to use hex `0xRRGGBBAA` or strings `"RRGGBBAA"`.

> **Note:**
> R, G, B, A values range between 0.0&ndash;1.0.

## Terrain

[Open the full Terrain reference](../Terrain-Script-Environment/Static-Functions/sm.color.md)

To create one, use [sm.color.new](../Terrain-Script-Environment/Static-Functions/sm.color.md#new). It is possible to use hex `0xRRGGBBAA` or strings `"RRGGBBAA"`.

> **Note:**
> R, G, B, A values range between 0.0&ndash;1.0.
