Is this command right ?
#9

Quote:
Originally Posted by antonio112
Посмотреть сообщение
Try it this way:
pawn Код:
CMD:cpw(playerid, params[])
{
    if(pInfo[playerid][Adminlevel] <= 2)
    {
        new count = 0, str[128];
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                new Weapon = GetPlayerWeapon(i);
                new pName[MAX_PLAYER_NAME];
                if(Weapon == 16 || Weapon == 35 || Weapon == 36 || Weapon == 37 || Weapon == 38 || Weapon == 39)
                {
                    GetPlayerName(i, pName, sizeof(pName));
                    format(Str, sizeof(Str), "{FF8000}>>{FFFFFF} Player {FF0000}(%s[%d]){FFFFFF} Possible Weapon Hacking", pName, playerid);
                    SendClientMessage(playerid, -1, Str);
                    count ++;
                }
             }
        }
        if(count == 0) SendClientMessage(playerid, -1, "{FF8000}>>{FFFFFF} No Weapon Hackers Detected");
    }
    else return 0;
    return 1;
}
Thanks it worked like a charm.
Reply


Messages In This Thread
Is this command right ? - by Glint - 22.09.2012, 07:48
Re: Is this command right ? - by InfinityCOD - 22.09.2012, 07:49
Re: Is this command right ? - by antonio112 - 22.09.2012, 07:52
Re: Is this command right ? - by mobiliz - 22.09.2012, 07:53
Re: Is this command right ? - by antonio112 - 22.09.2012, 07:55
Re: Is this command right ? - by Glint - 22.09.2012, 07:59
Re: Is this command right ? - by antonio112 - 22.09.2012, 08:03
Re: Is this command right ? - by mobiliz - 22.09.2012, 08:06
Re: Is this command right ? - by Glint - 22.09.2012, 08:06

Forum Jump:


Users browsing this thread: 1 Guest(s)