# sm.color.lerp

Linearly interpolates between two colors

**Kind:** Function

**Environments:** Game, Terrain

## Game

``` { .lua .api-signature }
sm.color.lerp( color1, color2, t )
```

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

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `color1` | [Color](../Game-Script-Environment/Userdata/Color.md) | The first color. |
| `color2` | [Color](../Game-Script-Environment/Userdata/Color.md) | The second color. |
| `t` | number | Interpolation amount between the two inputs. |

**Returns:**

| Type | Description |
| --- | --- |
| [Color](../Game-Script-Environment/Userdata/Color.md) | Interpolated color. |

## Terrain

``` { .lua .api-signature }
sm.color.lerp( color1, color2, t )
```

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

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `color1` | [Color](../Terrain-Script-Environment/Userdata/Color.md) | The first color. |
| `color2` | [Color](../Terrain-Script-Environment/Userdata/Color.md) | The second color. |
| `t` | number | Interpolation amount between the two inputs. |

**Returns:**

| Type | Description |
| --- | --- |
| [Color](../Terrain-Script-Environment/Userdata/Color.md) | Interpolated color. |
