Criminal Chat Problem [DCMD]
#5

Quote:
Originally Posted by Kwarde
Посмотреть сообщение
That is correct.
Also, here is your command again, fixed (atleast it should be :P) and a little speed improvement:
pawn Код:
dcmd_cchat(playerid, params[])
{
    if (!strlen(params)) return SendClientMessage(playerid, COLOR_ERROR, "USAGE: /cchat (Message)");
    if (GetPlayerWantedLevel(playerid) < 20) return SendClientMessage(playerid, -1, "You are not a hardened criminal");
    if (IsSpawned[playerid] == 0) return SendClientMessage(playerid, COLOR_ERROR, "You must be alive and spawned in order to be able to use this command.");
    new string[128];
    format(string, 128, "4[CRIM CHAT] %s(%d): %s", PlayerName(playerid), playerid, params);
    IRC_GroupSay(gGroupAdminID, IRC_ADMINCHANNEL, string);
    format(string, 128, "[CRIM CHAT] %s(%d): %s", PlayerNAme(playerid), playerid, params);
    for (new i = 0; i < MAX_PLAYERS; i++)
    {
        if (!IsPlayerConnected(i) || GetPlayerWantedLevel(i) < 20) continue;
        SendClientMessage(i, COLOR_RED, string);
    }
    return 1;
}
Thank you very much
Reply


Messages In This Thread
Criminal Chat Problem [DCMD] - by CNRLIFE - 09.05.2013, 15:47
Re: Criminal Chat Problem [DCMD] - by Kwarde - 09.05.2013, 15:51
Re: Criminal Chat Problem [DCMD] - by CNRLIFE - 09.05.2013, 15:55
Re: Criminal Chat Problem [DCMD] - by Kwarde - 09.05.2013, 16:04
Re: Criminal Chat Problem [DCMD] - by CNRLIFE - 09.05.2013, 16:29

Forum Jump:


Users browsing this thread: 1 Guest(s)