# setSunColor (Client)

> Changes the colour of the sun, over the time cycle, until `resetSunColor` restores it.

- **Platform**: MY Multiplayer (MYMP)
- **Kind**: Lua Function
- **Side**: Client
- **Category**: World and weather
- **URL**: https://wiki.mymp.gg/en/setSunColor

## Syntax

```lua
bool setSunColor(color color)
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `color` | `color` | Three numbers `r, g, b` (integers from 0 to 255) or a `tocolor` value. Alpha is ignored. |

## Returns

`true` once the colour is set.

## Example

```lua
setSunColor(255, 120, 40)
```

## See also

- [getSunColor (Client)](https://wiki.mymp.gg/en/getSunColor.md): Returns the colour of the sun in use: the one setSunColor set or, without it, the time cycle's.
- [resetSunColor (Client)](https://wiki.mymp.gg/en/resetSunColor.md): Undoes setSunColor: the sun's colour follows the time cycle again.
