Quote:
Originally Posted by maramizo
This is the correct weather code.
pawn Код:
if(strcmp(cmd, "/weather", true) == 0) { if(IsPlayerConnected(playerid)) { if(PlayerInfo[playerid][AdmLvl] < 2) { SendClientMessage(playerid, COLOR_GRAD1, "** You are not authorized to use that command!"); return 1; } tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, COLOR_WHITE, "USAGE: /weather [weatherid]"); return 1; } new weather; weather = strval(tmp); if(weather < 0||weather > 45) return SendClientMessage(playerid, COLOR_GREY, " Weather ID can't be below 0 or above 45!"); SetWeather(weather); DefaultWeather = weather; } return 1; }
|
Oh yeah, i get wrong in [AdmLvl] XD