11.12.2014, 18:01
Here is my command
It works but when i type `/check [any other id that isn't connected] it also send me "Player has a license" what should i do ??
PHP Code:
CMD:check(playerid,params[])
{
new targetid;
if(sscanf(params,"d",targetid)) return SendClientMessage(playerid,-1,"Usage: /check [playerid]");
if(PInfo[playerid][pDriver] == 1)
{
SendClientMessage(playerid,-1,"Player has a license.");
}
else if(PInfo[playerid][pDriver] == 0)
{
SendClientMessage(playerid,-1,"Player doesnt have a license.");
}
else if(!IsPlayerConnected(id))
{
SendClientMessage(playerid,-4,"That player is not connected!");
}
return 1;
}