22.05.2016, 12:02
hello, i made this CMD for my Vip players so that they can set there weather not everyones:-
but it gives this error:-
And this the line where the error is coming:-
kindly tell me how to fix it?
PHP код:
CMD:vweather(playerid, params[])
{
if(GetPVarInt(playerid, "DonateRank") <= 1)
{
SendClientMessage(playerid, 0xAA3333AA, "You are not a VIP!");
return 1;
}
new weather;
if(sscanf(params, "d", weather)) return SendClientMessage(playerid, 0xFFFFFFFF, "USAGE: /vweather [weatherid]");
if(weather < 0||weather > 45) { SendClientMessage(playerid, 0xAA3333AA, "Weather ID can't be below 0 or above 45!"); return 1; }
SetPlayerWeather(playerid, weather);
SendClientMessage(playerid, 0xC2A2DAAA, "Weather Set!");
return 1;
}
PHP код:
D:\michael\filterscripts\Command(2).pwn(58) : error 035: argument type mismatch (argument 1)
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
1 Error.
PHP код:
if(sscanf(params, "d", weather)) return SendClientMessage(playerid, 0xFFFFFFFF, "USAGE: /vweather [weatherid]");