SA-MP Forums Archive
Loses 100$ - 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: Loses 100$ (/showthread.php?tid=483679)



Loses 100$ - Noliax8 - 27.12.2013

Hi,

This is normal that my player loses 100$ at respawn after the dead with the money (not the textdraw : original http://image.noelshack.com/fichiers/...-sa-mp-041.png ) ?

I thinks not it's my GM... It's impossible

Help me
Thanks


Re: Loses 100$ - Littlehelper - 27.12.2013

Please provide the code inside your OnPlayerDeath and OnPlayerSpawn callback.


Re : Loses 100$ - Noliax8 - 27.12.2013

PHP Code:
public OnPlayerSpawn(playerid)
{
    
TogglePlayerClock(playerid0);
    return 
1;
}

public 
OnPlayerDeath(playeridkilleridreason)
{
    
/*
    ResetPlayerMoney(playerid);
    GivePlayerMoney(playerid, pInfo[playerid][pP__argent]);
       */
    
return 1;




Re: Loses 100$ - xVIP3Rx - 27.12.2013

Player loses $100 by default when he dies..
If you want to disable that you should give him 100$ when he dies..


Re: Loses 100$ - HardRock - 27.12.2013

Wrong*


Re: Loses 100$ - Littlehelper - 27.12.2013

EDIT: ....


Re: Loses 100$ - Konstantinos - 27.12.2013

By default when a player dies, the money goes $-100.

Use server-side money and it can solve that problem, plus it will not allow cheaters to get "fake" money.


Re : Re: Loses 100$ - Noliax8 - 27.12.2013

Quote:
Originally Posted by Konstantinos
View Post
By default when a player dies, the money goes $-100.

Use server-side money and it can solve that problem, plus it will not allow cheaters to get "fake" money.
Exactly, I am creating my anticheat, and I do not know if my code was wrong or if by default when a player loses $100!
So my players was ban because the money was different

Thanks a you for the confirm!


Re: Loses 100$ - Konstantinos - 27.12.2013

I wouldn't recommend you to ban the players if you're going to use server-side money because there're ways of loosing/earning money from the client side. It'd be better to just reset and give the registered money after few minutes.


Re : Loses 100$ - Noliax8 - 27.12.2013

Please explique more :
there are ways of losing/earning money from the client side
Bonus stunt ?