[Help]: /report command!
#1

Hello!

Here is my /report command...Everything works fine, but for reason I can write MAX. 5 characters, I don't know why

/report:
pawn Код:
CMD:report(playerid, params[])
{
    new targetid;
    new reason[60];
    new string[200];
    if(sscanf(params, "us", targetid, reason))return SCM(playerid, COLOR_GREY, "[USAGE]: /report [playerid] [reason]");
    if(!IsPlayerConnected(targetid))return SCM(playerid, COLOR_RED, "[ERROR]: This player is not connected.");
    SendClientMessage(playerid, COLOR_GREEN, "[SYSTEM]: Your Report have been send to an online Administartor (/admins)! Thank you For Reporting!");
    format(string, sizeof(string), "{80FF00}[REPORT]: {FB0435}%s(ID:%d) {00FF00}has Reported {FB0435}%s(ID:%d){00FF00}! {FB0435}|| {00FF00}Reason: {FB0435}%s", GetName(playerid), playerid, GetName(targetid), targetid, reason);
    SendAdminMessage(string);
    return 1;
}
SendAdminMessage:

pawn Код:
stock SendAdminMessage(const string[])
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
    if(pInfo[i][Adminlevel] >= 1)
    SendClientMessage(i, -1, string);
    }
    return 1;
}
Thanks
Reply


Messages In This Thread
[Help]: /report command! - by Areax - 02.06.2013, 06:43
Re: [Help]: /report command! - by Littlehelper - 02.06.2013, 07:04
Re: [Help]: /report command! - by Areax - 02.06.2013, 08:56
Re: [Help]: /report command! - by park4bmx - 02.06.2013, 09:33
Re: [Help]: /report command! - by Areax - 02.06.2013, 11:14

Forum Jump:


Users browsing this thread: 2 Guest(s)