Pick ups - 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: Pick ups (
/showthread.php?tid=180786)
Pick ups -
XxerykxX - 02.10.2010
Hey guys.
I have few questions:
1.How to make Pick Ups? Like A Pill gives you nitro when you are in car or a skull means that you blow up?
I want to add them to a Track with checkpoints.
2.How to make score saving? and when the score is 100 player color is chaning to red and if 500 its going blue etc.?
Re: Pick ups -
Chaprnks - 02.10.2010
You will need to code the functions under
OnPlayerPickUpPickup.
Example:
pawn Код:
// Add a new variable named "pickup_nitro"
new pickup_skull;
public OnGameModeInit()
{
// Assign the newly created pickup to that id
pickup_skull = CreatePickup(1254, 2, 0.0, 0.0, 0.9);
return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
// Once picked up, initiate the code below
if(pickupid == pickup_skull)
{
GameTextForPlayer(playerid, "~r~SKULL", 3000, 4);
SetVehicleHealth(GetPlayerVehicleID(playerid), 0.0);
}
return 1;
}
Re: Pick ups -
XxerykxX - 02.10.2010
Well you didnt get me. I want pick up that loads with track. On server there are over 30 tracks and i have to make pick ups for each of them.