SA-MP Forums Archive
Help! Money Hack - 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: Help! Money Hack (/showthread.php?tid=615508)



Help! Money Hack - DandyCorleone - 23.08.2016

What the script to Auto Kicked and Close Connection for player use Unlimited Money (Money Hack) ?


Re: Help! Money Hack - Luis- - 23.08.2016

There's plenty of tutorials & filterscripts for this, search instead of asking people to do your work.


Re: Help! Money Hack - DeeadPool - 23.08.2016

Here you go:-
At top of your script:-
PHP код:
new pOldMoney[MAX_PLAYERS];
new 
pNewMoney[MAX_PLAYERS]; 
Somewhere in your script:-
PHP код:
forward GivePlayerMoneyEx(playerid,ammount);
public 
GivePlayerMoneyEx(playerid,ammount)
{
     
      
pOldMoney[playerid] = GetPlayerMoney(playerid)
      
pNewMoney[playerid] = ammount;
   
      
GivePlayerMoney(playerid,ammount);
      
      return 
1;

Under GameModeInIt:-
PHP код:
SetTimer("CheckMoney",2000,true); 
Somewhere in the script:-
PHP код:
forward CheckMoney();
public 
CheckMoney()
{
      for(new 
0MAX_PLAYERSI++)
      {
               if(
IsPlayerConnected(i))
               {
                        if(
GetPlayerMoney(i) > pNewMoney[i])
                        {
                                  
ResetPlayerMoney(i);
                                  
GivePlayerMoney(i,pOldMoney[i]);
                                  
Kick(i);       
                        }
               }
      }
      return 
1;

Under OnPlayerConnect:-
PHP код:
OnPlayerConnect(playerid)
{
     
pNewMoney[playerid] = GetPlayerMoney(playerid);
     return 
1;




Re: Help! Money Hack - Shinja - 23.08.2016

Quote:
Originally Posted by DeeadPool
Посмотреть сообщение
Here you go:-
At top of your script:-
PHP код:
new pOldMoney[MAX_PLAYERS];
new 
pNewMoney[MAX_PLAYERS]; 
Somewhere in your script:-
PHP код:
forward GivePlayerMoneyEx(playerid,ammount);
public 
GivePlayerMoneyEx(playerid,ammount)
{
     
      
pOldMoney[playerid] = GetPlayerMoney(playerid)
      
pNewMoney[playerid] = ammount;
   
      
GivePlayerMoney(playerid,ammount);
      
      return 
1;

Under GameModeInIt:-
PHP код:
SetTimer("CheckMoney",2000,true); 
Somewhere in the script:-
PHP код:
forward CheckMoney();
public 
CheckMoney()
{
      for(new 
0MAX_PLAYERSI++)
      {
               if(
IsPlayerConnected(i))
               {
                        if(
GetPlayerMoney(i) > pNewMoney[i])
                        {
                                  
ResetPlayerMoney(i);
                                  
GivePlayerMoney(i,pOldMoney[i]);
                                  
Kick(i);       
                        }
               }
      }
      return 
1;

Under OnPlayerConnect:-
PHP код:
OnPlayerConnect(playerid)
{
     
pNewMoney[playerid] = GetPlayerMoney(playerid);
     return 
1;

https://sampforum.blast.hk/showthread.php?tid=292898
You really had to copy this?


Anyway use server sided money, best example i found
http://forum.sa-mp.com/showthread.ph...er+Sided+Money


Re: Help! Money Hack - DeeadPool - 23.08.2016

Quote:
Originally Posted by Shinja
Посмотреть сообщение
https://sampforum.blast.hk/showthread.php?tid=292898
You really had to copy this?


Anyway use server sided money, best example i found
http://forum.sa-mp.com/showthread.ph...er+Sided+Money
Oh, Thanks i had used this same tutorial for my server. I'll add the credits.

(Sorry for plagiarism)