Help (scripting player Money) - 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 (scripting player Money) (
/showthread.php?tid=307338)
Help (scripting player Money) -
smashed390 - 30.12.2011
Does anyone know or have a script to change the players money..
EXAMPLE : Player joins the server for the 1st time they start with 10 thousand dollars. and if they die they lose 100 dollars....Becuase the script im working on they just keep spawning with 50000 even after they die.
What im looking for is where their money does not reset everytime they die.
AnyHelp?[Because i have no idea how to do this.]
I dont know if i explained this well but hopefully someone can help me.
Re: Help (scripting player Money) -
SnG.Scot_MisCuDI - 30.12.2011
If it keeps reseting there cash look for SetPlayerCash. If its under onplayerspawn then take it off
For death
pawn Код:
public OnPlayerDeath(playerid)
{
GivePlayerCash(playerid,-100);
return 1;
}
Re: Help (scripting player Money) -
AustinJ - 30.12.2011
It is proably an anti-cheat system and you have to find where it is checking to see the money. Make sure that you remove their money the way the anti-cheat system does. Look under OnPlayerUpdate, OnPlayerSpawn, or and other similar callbacks.