[Include] [INC] PCash - Tired of money hackers?
#41

Finally an advanced Money Hack detector...

I was tired from Those money hack anti-cheat scripts...
Which use's GetPlayerMoney
Reply
#42

I'm Sure Like OnPlayerUpdate You Can Do Textdraws

Reply
#43

Help me!!!!

How to Write PCash To Player File
Reply
#44

Quote:
Originally Posted by Jafri
Help me!!!!

How to Write PCash To Player File
bump
Reply
#45

Quote:
Originally Posted by Jafri
Quote:
Originally Posted by Jafri
Help me!!!!

How to Write PCash To Player File
bump
Gawd. Anyone Help pl0x
Reply
#46

Hey Jafri!

I don't know what type of file system you have or if you have a login system, but something like this is easy to do with dini. You'll need to download the dini include.

Something like this would work:

Save the pcash on disconnect

Код:
public OnPlayerDisconnect(playerid, reason)
{
	  new file[128], pname[MAX_PLAYER_NAME];
	  GetPlayerName(playerid, pname, sizeof(pname));
	  format(file, sizeof(file), "%s.ini", pname);

      if(!dini_Exists(file))
      {
          dini_Create(file);
      }

	  dini_IntSet(file, "PCash", GetPlayerPCash(playerid));

      ResetPlayerPCash(playerid); //reset Pcash for security

      return 1;
}
Give the player their PCash when they connect (or add something like this to your login system otherwise anyone with the same name could join and get the pcash)

Код:
public OnPlayerConnect(playerid)
{
	  new file[128], pname[MAX_PLAYER_NAME];
	  GetPlayerName(playerid, pname, sizeof(pname));
	  format(file, sizeof(file), "%s.ini", pname);

      if(dini_Exists(file))
      {
          GivePlayerPCash(playerid, dini_Int(file, "PCash"));
      }

      return 1;
}
Hope this helps
Reply
#47

Quote:
Originally Posted by wil2140
Hey Jafri!

I don't know what type of file system you have or if you have a login system, but something like this is easy to do with dini. You'll need to download the dini include.

Something like this would work:

Save the pcash on disconnect

Код:
public OnPlayerDisconnect(playerid, reason)
{
	  new file[128], pname[MAX_PLAYER_NAME];
	  GetPlayerName(playerid, pname, sizeof(pname));
	  format(file, sizeof(file), "%s.ini", pname);

      if(!dini_Exists(file))
      {
          dini_Create(file);
      }

	  dini_IntSet(file, "PCash", GetPlayerPCash(playerid));

      ResetPlayerPCash(playerid); //reset Pcash for security

      return 1;
}
Give the player their PCash when they connect (or add something like this to your login system otherwise anyone with the same name could join and get the pcash)

Код:
public OnPlayerConnect(playerid)
{
	  new file[128], pname[MAX_PLAYER_NAME];
	  GetPlayerName(playerid, pname, sizeof(pname));
	  format(file, sizeof(file), "%s.ini", pname);

      if(dini_Exists(file))
      {
          GivePlayerPCash(playerid, dini_Int(file, "PCash"));
      }

      return 1;
}
Hope this helps
Hey Wil.

I'm Using LA:RP Script. So i think this might work Also i am Jafri's Cousin I'm using his account for now.
Reply
#48

Hi there, i know Jafri from WS

I haven't seen LA:RP but its probably has a system which saves players money using GetPlayerMoney, so in theory replacing all the GetPlayerMoney with GetPlayerPCash would save it with the rest of the players data.

btw nice include Zezombia
Reply
#49

Quote:
Originally Posted by wil2140
Hi there, i know Jafri from WS

I haven't seen LA:RP but its probably has a system which saves players money using GetPlayerMoney, so in theory replacing all the GetPlayerMoney with GetPlayerPCash would save it with the rest of the players data.

btw nice include Zezombia
It's Actually SafeGetPlayerMoney :S
Reply
#50

GG Zezombia
Nice include

Reply
#51

true but if it was more compatible with more functions would be better
Reply
#52

How i can make a command like /change that changes the PCash to the normal cash?
Reply
#53

Quote:
Originally Posted by [ECR
SancheZ ]
How i can make a command like /change that changes the PCash to the normal cash?
simple.

GetPlayerPCash
GivePlayerMoney
Reply
#54

Quote:
Originally Posted by [ECR
SancheZ ]
How i can make a command like /change that changes the PCash to the normal cash?
Whoops my fault, there just was a cmd that does that.

But can someone help me making a bar that shows the PCash just below the normal cash ? Thanks.
Reply
#55

A function for it:
Код:
stock SetPlayerPCash(playerid, value)
{
   PCash[playerid] = 0;
   PCash[playerid] = PCash[playerid] + value;
   return PCash[playerid];
}
Reply
#56

Does this work with the godfather gm?
Reply
#57

the download link for the .inc is dead can anyone send me working please?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)