Coffin object with money pickup after killed - 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: Coffin object with money pickup after killed (
/showthread.php?tid=468355)
Coffin object with money pickup after killed -
gotwarzone - 07.10.2013
Hello guys, I need help to make coffin object with money after player gets killed. And if someone picked the coffin he/she will get additional cash maybe around 2000.
Thanks looking forward to any help.
Re: Coffin object with money pickup after killed -
TomatoRage - 07.10.2013
pawn Код:
new MoneyPickup;
public OnPlayerDeath(playerid,killerid,reason)
{
MoneyPickup = CreatePickup(model, type, Float:X, Float:Y, Float:Z, Virtualworld);
return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == MoneyPickup)
{
GivePlayerMoney(playerid,any amount of cash you want);
}
return 1;
}
https://sampwiki.blast.hk/wiki/OnPlayerPickUpPickup
https://sampwiki.blast.hk/wiki/Pickup_IDs