SA-MP Forums Archive
Anti Health Hack Help +REP! - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Anti Health Hack Help +REP! (/showthread.php?tid=332092)



Anti Health Hack Help +REP! - TheMightyEddy - 07.04.2012

So I'm trying to follow this tutorial:

https://sampforum.blast.hk/showthread.php?tid=303695

And when it says
Код:
#define Admin IsPlayerAdmin
what should I put to replace IsPlayerAdmin? I don't want all rcon admins. I'm want to use the Lux Admin system instead of the rcon admin system which the lux admin script is located here: https://sampforum.blast.hk/showthread.php?tid=120724

Please help?


Re: Anti Health Hack Help +REP! - Reklez - 07.04.2012

Combinig them?

then do

pawn Код:
#define AccInfo[playerid][Level]
?


Re: Anti Health Hack Help +REP! - TheMightyEddy - 07.04.2012

No not combining. Lux Admin is a seperate filterscript. I want it so that I can put the anti-health hack in my GM script and when an admin health hacks or uses admin commands to add health or put god mode on, then he/she won't get banned.


Re: Anti Health Hack Help +REP! - Reklez - 07.04.2012

pawn Код:
#define AccInfo[playerid][Level]



Re: Anti Health Hack Help +REP! - TheMightyEddy - 07.04.2012

Quote:
Originally Posted by Reklez
Посмотреть сообщение
pawn Код:
#define AccInfo[playerid][Level]
Do I fill in the playerid and the level?


Re: Anti Health Hack Help +REP! - Reklez - 07.04.2012

yes but i don't know if it works. but give it a try


Re: Anti Health Hack Help +REP! - TheMightyEddy - 07.04.2012

Okay I will thanks but before I do that, what do I fill the playerid and the level in with?


Re: Anti Health Hack Help +REP! - Rob_Maate - 07.04.2012

What... No.

Create a function

pawn Код:
stock Admin(playerid, level)
{
    if(AccInfo[playerid][Level] >= level) return true;
    return false;
}
In your code, use the function as follows

pawn Код:
CMD:retard(playerid, params[])
{
    if(Admin(playerid, 2))
    {
        //Party
    }
}
To check if the player is NOT an admin of that level

if(!Admin(playerid, 3))


Re: Anti Health Hack Help +REP! - TheMightyEddy - 07.04.2012

Quote:
Originally Posted by Rob_Maate
Посмотреть сообщение
What... No.

Create a function

pawn Код:
stock Admin(playerid, level)
{
    if(AccInfo[playerid][Level] >= level) return true;
    return false;
}
In your code, use the function as follows

pawn Код:
CMD:retard(playerid, params[])
{
    if(Admin(playerid, 2))
    {
        //Party
    }
}
To check if the player is NOT an admin of that level

if(!Admin(playerid, 3))
Hmm I don't get it. I don't think it will work. Any other ways? I just need it so that I can replace "#define Admin YourAdminScript" YourAdminScript with mine but what do I put there for Lux Admin?


Re: Anti Health Hack Help +REP! - Rob_Maate - 07.04.2012

IsPlayerAdmin is the RCON administrator check correct?

My function simply returns if the player is a script admin of said level.