Anti Cheat
#5

Quote:
Originally Posted by SAMPHacker
Посмотреть сообщение
Lets say you want to ban any one who have a minigun,
PHP код:
forward AntiCheat(); //forwarding a public function so we can use it later
public AntiCheat() //the function we forwarded later
{
    for(new 
0MAX_PLAYERSi++) //loop through all the players
    
{
        if(
IsPlayerConnected(i)) //check for the result from the loop
        
{
            new 
Weapon//creating var named Weapo
            
Weapon GetPlayerWeapon(i); //putting info in the var weapon
            
if(Weapon == 38 && PInfo[playerid][Level] == 0)//if the current weapon is 38 (minigun) and the player isn't admin
            
{
                
BanEx(i,"Minigun");//ban the player
            
}
        }
    }
}
public 
OnGameModeInit()
{
    
SetTimer("AntiCheat",1,true);//call the function AntiCheat every 1 milisec

Hi, I tried this but I got errors
Код:
gamemodes\DM.pwn(3455) : error 017: undefined symbol "PInfo"
gamemodes\DM.pwn(3455) : error 017: undefined symbol "playerid"
gamemodes\DM.pwn(3455) : error 029: invalid expression, assumed zero
gamemodes\DM.pwn(3455) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase

4 Errors.
Reply


Messages In This Thread
Anti Cheat - by Biess - 25.01.2013, 17:00
AW: Anti Cheat - by Blackazur - 25.01.2013, 17:05
Re: Anti Cheat - by Biess - 25.01.2013, 17:06
Re: Anti Cheat - by SAMPHacker - 25.01.2013, 17:13
Respuesta: Re: Anti Cheat - by RiChArD_A - 25.01.2013, 17:36
Re: Anti Cheat - by Biess - 25.01.2013, 18:23
Re: Anti Cheat - by DaRk_RaiN - 25.01.2013, 18:26
Re: Anti Cheat - by SAMPHacker - 25.01.2013, 18:48
Re: Anti Cheat - by Biess - 25.01.2013, 19:45
Re: Anti Cheat - by Biess - 26.01.2013, 06:21

Forum Jump:


Users browsing this thread: 5 Guest(s)