# setWeather (Client)

> Changes this client's weather, at once or over a blend.

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

## Syntax

```lua
bool setWeather(string weather [, float blendMinutes = -1])
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `weather` | `string` | The weather's name (case-insensitive) or its id written as text, such as `"8"`. |
| `blendMinutes` | `float` | Game minutes the blend takes. Zero or less switches at once. *(default: `-1`)* |

## Returns

`true` if the weather exists and was set, `false` if it does not exist.

## Example

```lua
setWeather("RAINY", 10)
```

## See also

- [getWeather (Client)](https://wiki.mymp.gg/en/getWeather.md): Returns this client's current weather. During a blend, it is the weather being blended to.
- [getWeatherNames (Client)](https://wiki.mymp.gg/en/getWeatherNames.md): Lists the weathers the loaded packs declare.
