[FilterScript] The Best Anti Health-Hack [Works 100%][Bans every single HealthHacker]
#1

ANTI HEALTH-HACK


VERSION 1.1 (NEW RELEASE)


New in version 1.1:

- Changed PVarInt(s) to PVarFloat(s)
- Added BanPlayer option (true/false)
- Few more changes in script
__________________________________________________ __________________________________________________

VIDEO:

http://www.youtube.com/watch?v=TXAup...ature=*********

__________________________________________________ __________________________________________________

EXPLANATION:

Command to check health hack is /checkhh!

So, you must be logged in RCON to use this! Also, if you wanna have this in your admin script, then

find this:
pawn Code:
#define Admin IsPlayerAdmin
and change to this:
pawn Code:
#define Admin YourAdminScript
Lets begin!
Use /checkhh (playerid) to check target player! The target playerґs Z position will be raised for 15

and he/she will fall down! When the /checkhh command is performed, it will triger

"CheckTakenHealth" timer! This timer is set to check health after 1 second, but you can change it

(its recommended to leave 1 second check):
pawn Code:
#define TakenHealthTime 1000
to:
pawn Code:
#define TakenHealthTime DesiredTime
When "CheckTakenHealth" ends, it will set PVar named "CurrHealth" (stands for CurrentHealth)! Also,

it will start new timer, which is "CheckNewHealth"! Change "NewHealthTime" from this:
pawn Code:
#define NewHealthTime 1000
into this:
pawn Code:
#define NewHealthTime DesiredTime
Then, "CheckNewHealth" finishes, stores new player health - also in PVar ("NewHealth") - and starts

timer "BanIfHacker" (timer wont be started if player lost health)! If player did not lose health,

system will automaticly ban him/her!
"BanIfHacker" timer is set to 1 second, but again, you can freely change it:
pawn Code:
#define BanHackerTime 1000
to:
pawn Code:
#define BanHackerTime DesiredTime
If player got banned, it will show him/her DIALOG_STYLE_MSGBOX with ban info and website where

he/she can post his unban app:
pawn Code:
#define Website yourwebsite
Choosing either to ban player or send message to admin bout possible HHacker!
pawn Code:
#define BanPlayer true //"true" -> it will ban player if he/she has HH | "false" -> it will send message to admin that player might be HHacking
__________________________________________________ _______________________________________________

IMPORTANT:

If you have AFK and/or Unlimited Health command, be sure you prevent checking immediately on command performing!

__________________________________________________ _______________________________________________

CREDITS:

fiki574_CRO - script
ZeeX - zcmd
****** - sscanf

__________________________________________________ _______________________________________________

BUGS:

Shouldnt be any, but report if found!

__________________________________________________ _______________________________________________

DOWNLOAD:

Pastebin (v1.1)
Mediafire (v1.1)
Reply
#2

very nice, thanks for this
Reply
#3

Quote:
Originally Posted by Nikk123
View Post
very nice, thanks for this
You are seriously one hell of a spammer. 70% of your posts, are posted in old old threads, until you've bumped them, and you say "nice, very nice, thanks, etc..".

On-topic:
Very nice job. I think I'm going to be using this.

Also..

pawn Code:
new Float:CurrHealth;
GetPlayerHealth(target,CurrHealth);
SetPVarInt(target,"CurrHealth",GetPlayerHealth(target,CurrHealth));
I don't think that's going to work properly (you've used GetPlayerHealth 2 times, wtf ), however, instead of Int, try Float.

pawn Code:
new Float:CurrHealth;
GetPlayerHealth(target,CurrHealth);
SetPVarFloat(target,"CurrHealth",CurrHealth);
And instead of using GetPVarInt, you use GetPVarFloat.

Very nice, wish I could give you Rep+, but I already did for the NPC creator, and now I have to spread it around first.
Reply
#4

I don't understand, you set their position so they fall down, then a second later you save their health and then another second later check their health? why would you even delay the first check?
also like Emmet_ said you're not using the PVar's properly but also you're not using the timers properly either

pawn Code:
SetTimer("CheckTakenHealth",TakenHealthTime,false);

public CheckTakenHealth() //contains target

SetTimer("CheckNewHealth",NewHealthTime,false);

CheckNewHealth() //contains target

SetTimer("BanIfHacker",BanHackerTime,false);

public BanIfHacker() //contains target
I'm wondering if you even tried to compile this, because that'd give you heaps of undefined errors with the target

also also
pawn Code:
if(sscanf(params, "uis", target))
only needs the u parameter.

you're not taking into consideration that players lag.
Reply
#5

I made this in a hurry... Should be useful....
http://pastebin.com/PNYK4JL8
pawn Code:
#include <YSI\y_timers>
#include <foreach>

new PlayerHealth[MAX_PLAYERS];
new Spawned[MAX_PLAYERS] = 1;

public OnPlayerConnect(playerid)
{
    Spawned[playerid] = 0;
    PlayerHealth[playerid] = 0;
    return 1;
}

public OnPlayerSpawn(playerid)
{
    new Float:Health;
    GetPlayerHealth(playerid, Health);
    PlayerHealth[playerid] = Health;
    Spawned[playerid] = 1;
    return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
    Spawned[playerid] = 0;
    return 1;
}

Timer:CheckHP[5000]()
{
    foreach(Player, i)
    {
        if(Spawned[i] == 1)
        {
            new Float:Health, string[58 + MAX_PLAYER_NAME];
            GetPlayerHealth(i, Health);
            if(Health > PlayerHealth[i])
            {
                Kick(i);
                format(string, sizeof(string),"Player %d has been kicked by AntiCheat. Reason: HealthHack");
                SendClientMessage(playerid, -1, string);
            }
            else
            {
                PlayerHealth[i] = Health;
            }
        }
    }
    return 1;
}

forward ACSetPlayerHealth(playerid, Float:health)
public ACSetPlayerHealth(playerid, Float:health) //Use this to SetPlayerHealth
{
    PlayerHealth[playerid] = health;
    SetPlayerHealth(playerid, health);
    return 1;
}
DraGoN's AntiCheat [ame]http://www.youtube.com/watch?v=PxDfGKDFtcg[/ame]
Reply
#6

useful. But fix bugs which cessil told you.
Reply
#7

Quote:
Originally Posted by Nikk123
View Post
very nice, thanks for this
Thank you!

Quote:
Originally Posted by Emmet_
View Post
You are seriously one hell of a spammer. 70% of your posts, are posted in old old threads, until you've bumped them, and you say "nice, very nice, thanks, etc..".

On-topic:
Very nice job. I think I'm going to be using this.

Also..

pawn Code:
new Float:CurrHealth;
GetPlayerHealth(target,CurrHealth);
SetPVarInt(target,"CurrHealth",GetPlayerHealth(target,CurrHealth));
I don't think that's going to work properly (you've used GetPlayerHealth 2 times, wtf ), however, instead of Int, try Float.

pawn Code:
new Float:CurrHealth;
GetPlayerHealth(target,CurrHealth);
SetPVarFloat(target,"CurrHealth",CurrHealth);
And instead of using GetPVarInt, you use GetPVarFloat.

Very nice, wish I could give you Rep+, but I already did for the NPC creator, and now I have to spread it around first.
Ok! So, it will give same results! I tried with Float and Int, bans me with HH both way! :P

Quote:
Originally Posted by cessil
View Post
I don't understand, you set their position so they fall down, then a second later you save their health and then another second later check their health? why would you even delay the first check?
also like Emmet_ said you're not using the PVar's properly but also you're not using the timers properly either

pawn Code:
SetTimer("CheckTakenHealth",TakenHealthTime,false);

public CheckTakenHealth() //contains target

SetTimer("CheckNewHealth",NewHealthTime,false);

CheckNewHealth() //contains target

SetTimer("BanIfHacker",BanHackerTime,false);

public BanIfHacker() //contains target
I'm wondering if you even tried to compile this, because that'd give you heaps of undefined errors with the target

also also
pawn Code:
if(sscanf(params, "uis", target))
only needs the u parameter.

you're not taking into consideration that players lag.
Oh, my mystake (bout "uis")!
And timers work perfectly and do what they are supposed to do! Theres nothing wrong with timers! Just go and try it and you will see! :P
Reply
#8

Quote:
Originally Posted by Dragony92
View Post
I made this in a hurry... Should be useful....
http://pastebin.com/PNYK4JL8
you're really depending on the player not pausing and the player having a low ping, although, even if the player had a low ping and had their health set just before the check then they'd get a false positive.
Also you should be removing everything that gives health like fast food restaurants and vending machines
Reply
#9

I know, i made it different for my mod, works perfect whole anticheat (stops when that is necessary),....
I only used your tip with armour 99
Reply
#10

Ok! New version links are up! REDOWNLOAD!

@cessil
Params fixed, now its just "u" (tnx)

@Emmet_
Changed PVarInt(s) to PVarFloat(s)
Reply
#11

Why you don't try CreateExplosion
Reply
#12

Quote:
Originally Posted by Dragony92
View Post
I made this in a hurry... Should be useful....
http://pastebin.com/PNYK4JL8
pawn Code:
#include <YSI\y_timers>
#include <foreach>

new PlayerHealth[MAX_PLAYERS];
new Spawned[MAX_PLAYERS] = 1;

public OnPlayerConnect(playerid)
{
    Spawned[playerid] = 0;
    PlayerHealth[playerid] = 0;
    return 1;
}


public OnPlayerSpawn(playerid)
{
    new Float:Health;
    GetPlayerHealth(playerid, Health);
    PlayerHealth[playerid] = Health;
    Spawned[playerid] = 1;
    return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
    Spawned[playerid] = 0;
    return 1;
}

Timer:CheckHP[5000]()
{
    foreach(Player, i)
    {
        if(Spawned[i] == 1)
        {
            new Float:Health, string[58 + MAX_PLAYER_NAME];
            GetPlayerHealth(i, Health);
            if(Health > PlayerHealth[i])
            {
                Kick(i);
                format(string, sizeof(string),"Player %d has been kicked by AntiCheat. Reason: HealthHack");
                SendClientMessage(playerid, -1, string);
            }
            else
            {
                PlayerHealth[i] = Health;
            }
        }
    }
    return 1;
}

forward ACSetPlayerHealth(playerid, Float:health)
public ACSetPlayerHealth(playerid, Float:health) //Use this to SetPlayerHealth
{
    PlayerHealth[playerid] = health;
    SetPlayerHealth(playerid, health);
    return 1;
}
DraGoN's AntiCheat http://www.youtube.com/watch?v=PxDfGKDFtcg
Hey man this is good (didnt test it just read the code) but if a person tries to make it as a filterscript it has a BIG bug you didnt do #include <a_samp>
Reply
#13

Quote:
Originally Posted by §с†¶e®РµРe
Посмотреть сообщение
Hey man this is good (didnt test it just read the code) but if a person tries to make it as a filterscript it has a BIG bug you didnt do #include <a_samp>
Good scripts usually compile. :>
Reply
#14

I got banned falsely for health hacking once - and slapping them was the cause.

I was lagging as i was downloading a torrent - everyone was literally frozen on my screen, i was the only one moving.

So this is not reliable, actually, no health hacks are reliable really. Can't 100% guarantee it's correct.
Reply
#15

Quote:
Originally Posted by GamingTurf
Посмотреть сообщение
I got banned falsely for health hacking once - and slapping them was the cause.

I was lagging as i was downloading a torrent - everyone was literally frozen on my screen, i was the only one moving.

So this is not reliable, actually, no health hacks are reliable really. Can't 100% guarantee it's correct.
In new version of this script, you can change "BanPlayer" from true to false! If its false, it will just send message to admin that selected player might be health hacker!
Reply
#16

@§с†¶e®РµРe That's only example code, not fs...
Reply
#17

Hello fiki574_CRO Plz Make It Like This
If Any Player Have Health Hack Your System Send Report To Admins
Thnx if u make it like this it will be awesome
Reply
#18

nice its working For me :
Reply
#19

Quote:
Originally Posted by Nikk123
View Post
very nice, thanks for this
LOL as some people say you always bump topics saying thanks etc..

and btw "Thanks for this" Will you learn to script sometime ? :P

On topic: Nice job again man
Reply
#20

Some information which you should take care of: All of these will lead to a false ban.

1.) This script will ban players who are Desynced.
2.) This script will ban players who fall on a vehicle.
3.) This script will ban players who are in water.
4.) This script will ban players who are Skydiving or falling in the sky.
5.) This script will ban players who are AFK.
6.) This script will ban players who just received a Timeout while checking process runs.
7.) This script will ban players who have a huge lag.
8.) This script will ban players who are frozen.
9.) This script will ban players who are in Ammu-Nation/Restaurant menu.
10.) This script will ban players who refresh their health in a pickup or snack machine while the checking process runs.

(Don't know about tuning shops, bomb shop and Pay'N'Sprays and when entering an interior.)

You should add all these things as exceptions to your script. Then you can really say it is the Best anti Health Hack script. And believe me, all of these things can be checked. I know this because I made one for my server.

Many Greetings,
Jeffry
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)