SA-MP Forums Archive
[HELP]Problems with death 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [HELP]Problems with death money (/showthread.php?tid=123680)



[HELP]Problems with death money - Zafire2008 - 26.01.2010

Hey any one can help me?... when i death... my money is -100.. for example i have 1500 when i death now its 1400 and if i death again.. its 1300...

I dont understand becausee here is my onplayerdeath line:

Код:
public OnPlayerDeath(playerid, killerid)
{
	return 1;
}
and when i enter on a taxi car my money is +12 .. i haveee 500 and if i enter the taxi know is 512... please help me!


Re: [HELP]Problems with death money - AlExAlExAlEx - 26.01.2010

Maybe OnPlayerSpawn ?


Re: [HELP]Problems with death money - Zafire2008 - 26.01.2010

No men :S in any place appears giveplayermoney -12 or something like that


Re: [HELP]Problems with death money - actiwe - 26.01.2010

public OnPlayerDeath(playerid, killerid)
{
GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
return 1;
}


Re: [HELP]Problems with death money - Zafire2008 - 26.01.2010

Quote:
Originally Posted by actiwe
public OnPlayerDeath(playerid, killerid)
{
GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
return 1;
}
i use that but i dont know whyy when i dead its -100 of money.. but thanks


Re: [HELP]Problems with death money - SlashPT - 26.01.2010

Код:
public OnPlayerDeath(playerid, killerid)
{
if(GetPlayerMoney(playerid) => 100)
{
GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
}
else
{
new Money = GetPlayerMoney(playerid);
GivePlayerMoney(playerid, -Money);
SendClientMessage(playerid, 0xF60000AA, "You donґt have money enough so we removed all money you have...");
}
return 1;
}
i think this one is better :P

and fixed the problem


Re: [HELP]Problems with death money - [HiC]TheKiller - 26.01.2010

pawn Код:
public OnPlayerDeath(playerid, killerid)
{
   GivePlayerMoney(playerid, 100);
   GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
   return 1;
}



Re: [HELP]Problems with death money - SlashPT - 26.01.2010

Quote:
Originally Posted by DarK_TeaM PT
Код:
public OnPlayerDeath(playerid, killerid)
{
if(GetPlayerMoney(playerid) => 100)
{
GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
}
else
{
new Money = GetPlayerMoney(playerid);
GivePlayerMoney(playerid, -Money);
SendClientMessage(playerid, 0xF60000AA, "You donґt have money enough so we removed all money you have...");
}
return 1;
}
i think this one is better :P

and fixed the problem
look at mine and

Quote:
Originally Posted by [HiC
TheKiller ]
pawn Код:
public OnPlayerDeath(playerid, killerid)
{
   GivePlayerMoney(playerid, 100);
   GivePlayerMoney(playerid, GetPlayerMoney(playerid) -100);
   return 1;
}
it is going only to give him 100 and remove 100?


Re: [HELP]Problems with death money - s0nic - 26.01.2010

Zafire2008..by any chance do use mysql?.. Because i remember that one mysql plugin would have a money bug..and would do the exact same thing.


Re: [HELP]Problems with death money - Zafire2008 - 26.01.2010

Quote:
Originally Posted by Killaz/s0nic
Zafire2008..by any chance do use mysql?.. Because i remember that one mysql plugin would have a money bug..and would do the exact same thing.
yes i use mysql brro :S .. i have

* SA:MP - MySQL Native Functions
* © Copyright 2008-2009, G-sTyLeZzZ