SA-MP Forums Archive
Anti FakeKill - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Anti FakeKill (/showthread.php?tid=584463)



Anti FakeKill - NexySamp - 04.08.2015

I need a working anti fake kill fs/include or whatever,hackers are anoying my players.REP who helps me


Re: Anti FakeKill - CZ - 04.08.2015

pawn Код:
new PlayerShotPlayer[MAX_PLAYERS][MAX_PLAYERS];

public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    PlayerShotPlayer[issuerid][playerid] = 1;
    return 0;
}

public OnPlayerDeath(playerid,killerid,reason)
{
    if(killerid != INVALID_PLAYER_ID)
    {
        if(!PlayerShotPlayer[killerid][playerid])
        {
            Ban(playerid);
        }
    }
    foreach(Player,i)
    {
        PlayerShotPlayer[i][playerid] = 0;
    }
    return 1;
}



Re: Anti FakeKill - NexySamp - 05.08.2015

Quote:
Originally Posted by CZ
Посмотреть сообщение
pawn Код:
new PlayerShotPlayer[MAX_PLAYERS][MAX_PLAYERS];

public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    PlayerShotPlayer[issuerid][playerid] = 1;
    return 0;
}

public OnPlayerDeath(playerid,killerid,reason)
{
    if(killerid != INVALID_PLAYER_ID)
    {
        if(!PlayerShotPlayer[killerid][playerid])
        {
            Ban(playerid);
        }
    }
    foreach(Player,i)
    {
        PlayerShotPlayer[i][playerid] = 0;
    }
    return 1;
}
Where exactly should i add this piece of code?


Re: Anti FakeKill - NexySamp - 05.08.2015

Quote:
Originally Posted by CZ
Посмотреть сообщение
pawn Код:
new PlayerShotPlayer[MAX_PLAYERS][MAX_PLAYERS];

public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    PlayerShotPlayer[issuerid][playerid] = 1;
    return 0;
}

public OnPlayerDeath(playerid,killerid,reason)
{
    if(killerid != INVALID_PLAYER_ID)
    {
        if(!PlayerShotPlayer[killerid][playerid])
        {
            Ban(playerid);
        }
    }
    foreach(Player,i)
    {
        PlayerShotPlayer[i][playerid] = 0;
    }
    return 1;
}
It gave me these errors
Код:
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\include\Geo.inc(435) : error 017: undefined symbol "foreach"
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\include\Geo.inc(437) : error 017: undefined symbol "playerid"
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\include\Geo.inc(440) : error 017: undefined symbol "playerid"
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\gamemodes\YT.pwn(3254) : error 021: symbol already defined: "OnPlayerDeath"
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\gamemodes\YT.pwn(3262) : error 017: undefined symbol "foreach"
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\gamemodes\YT.pwn(3264) : error 017: undefined symbol "i"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase



Re: Anti FakeKill - Variable™ - 05.08.2015

Removed.


Re: Anti FakeKill - Abagail - 05.08.2015

https://sampforum.blast.hk/showthread.php?tid=582630

Your example can give false results, especially if the player is using a weapon with a minigun or whatever.


Re: Anti FakeKill - NexySamp - 05.08.2015

Ty man solved all the errors (Y)


Re: Anti FakeKill - NexySamp - 05.08.2015

Quote:
Originally Posted by Abagail
Посмотреть сообщение
https://sampforum.blast.hk/showthread.php?tid=582630

Your example can give false results, especially if the player is using a weapon with a minigun or whatever.
Код:
C:\Users\Korisnik\Desktop\Yugoslavia Trucking v.0.3.7\include\onplayerfakekill.inc(24) : error 025: function heading differs from prototype
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.



Re: Anti FakeKill - Abagail - 05.08.2015

You are using outdated SA-MP includes and or you are using YSI 3.0.