22.07.2011, 16:24
These do not work weather does not change and either does the time anyone help?
pawn Код:
}
if(strcmp("/changeweather", cmd, true) == 0)
{
new tmp[256], cmdid;
tmp = strtok(cmdtext, idx);
if(PlayerInfo[playerid][AdminLevel] < 1) return 0;
if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /changeweather [weatherid]");
cmdid = strval(tmp);
SetWeather(cmdid);
SendClientMessageToAll(COLOR_LIGHTGREEN,"An Admin has changed the weather!");
return 1;
}
if(strcmp("/changetime", cmd, true) == 0)
{
new tmp[256], cmdid;
tmp = strtok(cmdtext, idx);
if(PlayerInfo[playerid][AdminLevel] < 1) return 0;
if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /changetime [time]");
cmdid = strval(tmp);
if(cmdid < 0 || cmdid > 24) return SendClientMessage(playerid,COLOR_ORED,"Wrong Time!");
SetWorldTime(cmdid);
SendClientMessageToAll(COLOR_LIGHTGREEN,"An Admin has changed the time!");
return 1;
}