Anti Health Hack.
#1

pawn Код:
#define FILTERSCRIPT

#include <a_samp>

forward Hacking();

public OnPlayerUpdate(playerid)
{
    new Float:fHealth;

    GetPlayerHealth(playerid, fHealth);

    if(fHealth != GetPVarFloat(playerid, "faPlayerHealth"))
    {
        // Player health has changed since the last update -> server, so obviously thats the thing updated.
        // Lets do further checks see if he's lost or gained health, anti-health cheat? ;)

        if(fHealth > GetPVarFloat(playerid, "faPlayerHealth"))
        {
             SetTimer("Hacking", 2000, false);
             SendClientMessageToAll(0xDEEE20FF, "TEST");
        }
        else
        {
            /* He has lost health! */
        }

        SetPVarFloat(playerid, "faPlayerHealth", fHealth);
    }
}
I have that but when the player spawn it sends the message, its really annoying, How to fix it?
If you wanna join me read my signature.
Reply


Messages In This Thread
Anti Health Hack. - by Alex_Obando - 29.07.2011, 19:41
Re: Anti Health Hack. - by Snipa - 29.07.2011, 19:46
Respuesta: Anti Health Hack. - by Alex_Obando - 29.07.2011, 19:54
Re: Anti Health Hack. - by Mean - 29.07.2011, 19:55
Respuesta: Anti Health Hack. - by Alex_Obando - 29.07.2011, 19:57
Re: Anti Health Hack. - by Mean - 29.07.2011, 20:21
Re: Anti Health Hack. - by MadeMan - 29.07.2011, 20:47
Respuesta: Anti Health Hack. - by Alex_Obando - 29.07.2011, 21:20
Respuesta: Anti Health Hack. - by Alex_Obando - 29.07.2011, 21:45
Re: Respuesta: Anti Health Hack. - by MadeMan - 30.07.2011, 09:19

Forum Jump:


Users browsing this thread: 1 Guest(s)