03.07.2011, 04:57
Hello!
If I want to make this command:
Integration of strcmp and sscanf, how I do it?
Thanks in advance helpers
If I want to make this command:
pawn Код:
CMD:kick(playerid, params[])
{
if(!IsPlayerAdmin(playerid)) return 1;
new ID,Reason[128], string[128];
if(sscanf(params, "us[128]", ID, Reason)) return SendClientMessage(playerid,WHITE,"USAGE: /Kick [ID] [Reason]");
if(ID == INVALID_PLAYER_ID) return SendClientMessage(playerid,RED,"Player not found.");
format(string, sizeof(string),"*** %s Has been kicked by: %s. (%s)",GetName(ID),GetName(playerid),Reason);
SendClientMessageToAll(RED,string);
TogglePlayerControllable(ID,false);
Kick(ID);
return 1;
}
Thanks in advance helpers