SA-MP Forums Archive
[HELP] Want to tele when I go into Pickup..how? - 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] Want to tele when I go into Pickup..how? (/showthread.php?tid=112748)



[HELP] Want to tele when I go into Pickup..how? - ParmeSan - 09.12.2009

Can someone please give me a FS witch wich i can go into a pickup and get teleported then?
I am new and I want to see how such script looks like.


Re: [HELP] Want to tele when I go into Pickup..how? - lolumadd - 09.12.2009

pawn Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
if(pickupid == ....)
{
SetPlayerPos(the teleport pos
}
}



Re: [HELP] Want to tele when I go into Pickup..how? - ParmeSan - 09.12.2009

yeah i know that but if i get this in pawno i gets me 4 errors
can someony PLEASE write the whole FS for such thing..?


Re: [HELP] Want to tele when I go into Pickup..how? - BP13 - 09.12.2009

Quote:
Originally Posted by ParmeSan
yeah i know that but if i get this in pawno i gets me 4 errors
can someony PLEASE write the whole FS for such thing..?
Here's a example

pawn Код:
#include <a_samp>

new pickup1; //The pickup

public OnGameModeInit() //Use public OnFilterScriptInit() if its a filterscript.
{
    pickup1 = CreatePickup(1318, 2, -423.699341, 2201.723145, 42.926292); //Position of the pickup
    return 1;
}

public OnPlayerPickUpPickup(playerid, pickupid)
{
    if (pickupid == pickup1) //If they piccked up pickup 1
    {
       SetPlayerPos(playerid,3935.8965,-1096.5420,3.2836); //Position to teleport to
    }
    return 1;
}