Problem with Health antihack
#1

pawn Код:
new Float:fHealth;
public Antihack()
{
    new x;
    new Float:rHealth;
    for(x=0;x<MAX_PLAYERS;x++)
    {

    GetPlayerHealth(x, rHealth);

    if(rHealth != GetPVarFloat(x, "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(rHealth > GetPVarFloat(x, "faPlayerHealth"))
      {
        /* He has gained health! Cheating? Write your own scripts here to figure how a player
            gained health! */

      }
      else
      {
        /* He has lost health! */
      }

      SetPVarFloat(x, "faPlayerHealth", rHealth);
    }
    }
}
Errors are:
\gamemodes\plaster.pwn(8294) : error 017: undefined symbol "GetPVarFloat"
\gamemodes\plaster.pwn(8299) : error 017: undefined symbol "GetPVarFloat"
\gamemodes\plaster.pwn(8309) : error 017: undefined symbol "SetPVarFloat"
why those errors?
Reply


Messages In This Thread
Problem with Health antihack - by whitedragon - 24.06.2010, 20:42
Re: Problem with Health antihack - by SiJ - 24.06.2010, 20:43
Re: Problem with Health antihack - by whitedragon - 24.06.2010, 20:47
Re: Problem with Health antihack - by ReVo_ - 24.06.2010, 20:48
Re: Problem with Health antihack - by Kar - 24.06.2010, 21:14

Forum Jump:


Users browsing this thread: 1 Guest(s)