24.12.2014, 15:14
Hello i created the following command
But i want that only admins (IsPlayerAdmin) can /kick players and if a simple user (not admin) try to use it get a message " You are not Admin".
PHP код:
CMD:kick(playerid,params[])
{
new id;
if(sscanf(params, "d", id))return SendClientMessage(playerid, 0xFFFFFFFF, "How to use: '/kick [playerid]'");
else if(!IsPlayerConnected(id))return SendClientMessage(playerid, 0xFF0000FF, "Invalid Player ID");
else
{
Kick(id);
}
return 1;
}