SetPlayerWeather
From SA-MP Wiki
Description:
Set a player's weather.
(playerid, weather)
playerid | The ID of the player whose weather to set. |
weather | The weather to set. |
Return Values:
This function does not return any specific values.
public OnPlayerCommandText(playerid, cmdtext[]) { if(!strcmp(cmdtext, "/storm", true)) { SetPlayerWeather(playerid, 8); return 1; } return 0; }
Tip | If TogglePlayerClock is enabled, weather will slowly change over time, instead of changing instantly. |
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- SetWeather: Set the global weather.
- SetGravity: Set the global gravity.