#1

Hi Guys i Need Help.
this is anti Godmod But how to make if Player Admin Don't Work i mean i use /onduty and the hp be :9999999
i want edit this Code +rep if u helped me
PHP код:
#include <a_samp>
#include <YSF> //r11
#undef MAX_PLAYERS
const MAX_PLAYERS 500;
new 
ShotsTotal[MAX_PLAYERS], ShotsDoneEffect[MAX_PLAYERS];
public 
OnPlayerTakeDamage(playeridissueridFloat:amountweaponid//calling only with no cheat
{
    if(!
IsPlayerPaused(playerid) && IsPlayerControllable(playerid)) ShotsDoneEffect[playerid]++;
    else { 
ShotsTotal[playerid] = 0ShotsDoneEffect[playerid] = 0; }
    return 
1;
}
public 
OnPlayerWeaponShot(playeridweaponidhittypehitidFloat:fXFloat:fYFloat:fZ//calling ALWAYS and BEFORE OnPlayerTakeDamage
{
    if(
hittype == BULLET_HIT_TYPE_PLAYER)
    {
        if(!
IsPlayerPaused(hitid) && IsPlayerControllable(hitid))
        {
            
ShotsTotal[hitid]++;
            if(
ShotsTotal[hitid] - ShotsDoneEffect[hitid] > 1)
            {
                
Kick(hitid); //cheater
            
}
        }
    }
    return 
1;
}
public 
OnPlayerDisconnect(playeridreason)
{
    
ShotsTotal[playerid] = 0;
    
ShotsDoneEffect[playerid] = 0;
    return 
1;

Reply


Messages In This Thread
Help - by anassmaroc - 05.10.2015, 12:36
Re: Help - by Gammix - 05.10.2015, 12:38
Re : Help - by anassmaroc - 05.10.2015, 13:03
Re: Help - by raizo - 05.10.2015, 13:28

Forum Jump:


Users browsing this thread: 1 Guest(s)