Why does this code sends me nothing, even a message?
INPUT: /clan invite
OUTPUT: USAGE: /clan invite [id]
INPUT: /clan invite 0
OUTPUT: Nothing
INPUT: /clan invite Player
OUTPUT: Nothing
INPUT: /clan invite
OUTPUT: USAGE: /clan invite [id]
INPUT: /clan invite 0
OUTPUT: Nothing
INPUT: /clan invite Player
OUTPUT: Nothing
Code:
CMD:clan(playerid, params[])
{
new type[128];
if(sscanf(params,"s[128]",type)) return SendClientMessage(playerid, -1, ""COL_GRAY"USAGE: /clan [create/leave/help]");
if(!strcmp(type, "invite"))
{
new id, string[128];
if(sscanf(params,"s[128]u",type,id)) return SendClientMessage(playerid, -1, ""COL_GRAY"USAGE: /clan invite [id/part of name]");
format(string, sizeof(string), ""COL_GRAY"You have been invited to join '%s (%d)'. To join them, please use /clan join.", GetPlayerClanName(playerid), GetPlayerClanID(playerid));
SendClientMessage(id, -1, string);
}
return 1;
}