Trying to fix anticheat.
#1

Hello. I'm trying to fix the anticheat for my server and on the anti money hack part I found this line.
To make it easier to explain lets say GetPlayerMoney is 'O'
pawn Код:
if((GetPlayerMoney(i) - ScriptMoney[i]) >= 500 && (GetPlayerMoney(i) - ScriptMoney[i]) != 0)
If I'm correct now, this means :
if 'O' , minus the scriptmoney is equal or over 500 AND if 'O' minus scriptmoney is NOT 0.
Am I right?

If I am then can someone please explain what the he** it means cuz I got pretty confused when reading it.
I hope you can understand my explination.

EDIT: If it's called here
pawn Код:
if((GetPlayerMoney(i) - ScriptMoney[i]) >= 500 && (GetPlayerMoney(i) - ScriptMoney[i]) != 0)
                                {
                                    if(admins == 0)
                                    {
                                        format(string, sizeof(string), "%s (%d), Has been kicked by Anticheat for Possible Money Hacking.", plname, i);
                                        SendClientMessageToAll(COLOR_NICERED, string);
                                        format(string, sizeof(string), "You have Been Kicked by The Anticheat For Possible Weapon Money Hacking ($%d)",(GetPlayerMoney(i) - ScriptMoney[i]));
                                        SendClientMessage(i,COLOR_LIGHTBLUE, string);
                                        format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] Anticheat Has Kicked %s for: Money Hacking ($%d)",d,m,y,h,mi,s,plname,(GetPlayerMoney(i) - ScriptMoney[i]));
                                        KickLog(string);
                                        format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] Kicked by the Anticheat - Money Hacking.",d,m,y,h,mi,s,plname);
                                        AddPunishment(i, string);
                                        Kick(i);
                                    }
                                    format(string, sizeof(string), "|ERP-AC|: %s (%d) Is possibly Using Money Hacks; Use /spec and check him!", plname, i);
                                    SendAdminMessage(COLOR_YELLOW, string);
                                    PlayerSuspicious[i] = 1;
                                    PlayerMoneyHacking[i] = 1;
                                    PlayerSuspiciousMoney[i] = (GetPlayerMoney(i) - ScriptMoney[i]);
                                    PlayerGotSpottedRecently[i] = 1;
                                    SetTimerEx("ResetAcWarn", 300000, 0, "i", i);
                                }
Then shouldnt the line be
pawn Код:
if((GetPlayerMoney(i) - ScriptMoney[i]) >= 500 || (GetPlayerMoney(i) - ScriptMoney[i]) != 0)

Or am I'm just far of the wheels here?
Reply


Messages In This Thread
Trying to fix anticheat. - by Don_Cage - 10.09.2013, 22:21
Re: Trying to fix anticheat. - by Vince - 10.09.2013, 23:42
Re: Trying to fix anticheat. - by Don_Cage - 11.09.2013, 02:08
Re: Trying to fix anticheat. - by RobertK - 11.09.2013, 04:47
Re: Trying to fix anticheat. - by Don_Cage - 11.09.2013, 10:17

Forum Jump:


Users browsing this thread: 2 Guest(s)