Anti C-bug help rep++
#2

Add this some where at the top,
pawn Код:
new CBugWarnings[MAX_PLAYERS];
Add this onplayerconnect
pawn Код:
CBugWarnings[playerid] = 0;
This is your keying.
pawn Код:
if ((oldkeys & KEY_FIRE) && (newkeys & KEY_CROUCH)&& GetPlayerWeapon(playerid)==24)
{
    if(CBugWarnings[playerid] >= 5)
    {
        SendClientMessage(playerid, -1, "You've been killed for Cbugging.");
        CBugWarnings[playerid] = 0;
        SetPlayerHealth(playerid,0);
                GameTextForPlayer(playerid, "~r~ C Bug not allowed.", 3000, 1);
        return 1;
    }
    new string[129];
    CBugWarnings[playerid] += 1;
    format(string, sizeof(string), "[WARNING] C-Bugging is not allowed! (%d/5)",CBugWarnings[playerid]);
    SendClientMessage(playerid, -1, string);
}
Something like that. I obviously didn't test it.
Reply


Messages In This Thread
Anti C-bug help rep++ - by Mijata - 16.03.2015, 20:10
Re: Anti C-bug help rep++ - by The__ - 16.03.2015, 20:20
Re: Anti C-bug help rep++ - by Mijata - 16.03.2015, 20:42
Re: Anti C-bug help rep++ - by Mijata - 16.03.2015, 21:47
Re: Anti C-bug help rep++ - by Mijata - 17.03.2015, 11:29
Re: Anti C-bug help rep++ - by JaKe Elite - 17.03.2015, 11:31
Re: Anti C-bug help rep++ - by CalvinC - 17.03.2015, 11:35
Re: Anti C-bug help rep++ - by Mijata - 17.03.2015, 11:39
Re: Anti C-bug help rep++ - by CalvinC - 17.03.2015, 11:42
Re: Anti C-bug help rep++ - by Mijata - 17.03.2015, 11:44

Forum Jump:


Users browsing this thread: 2 Guest(s)