How can i add teleports - 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: How can i add teleports (
/showthread.php?tid=264592)
How can i add teleports -
bulgarianmaniacs - 26.06.2011
Hi people. I want to add more teleports in my server. See example from my teleports script:
Код:
//--------------------------------------------TELEPORT cardealer
if(strcmp(cmdtext, "/cardealer", true) == 0)
{new cartype = GetPlayerVehicleID(playerid);
new State=GetPlayerState(playerid);
SetPlayerInterior(playerid,0);
{if(State!=PLAYER_STATE_DRIVER)
{SetPlayerPos(playerid,-1974.2872,270.7369,35.1719);}
else if(IsPlayerInVehicle(playerid, cartype) == 1)
{SetVehiclePos(cartype,-1974.2872,270.7369,35.1719);
SetVehicleZAngle(cartype,359.7314);}
else
{SetPlayerPos(playerid,-1974.2872,270.7369,35.1719);}
GameTextForPlayer(playerid,"Welcome to Car Dealer",2500,3);}
return 1;}
I know how to add more teleports but don't know from where i can get coordinats like "-1974.2872,270.7369,35.1719" for the new place? Can you help me with this?
Re: How can i add teleports -
Adil - 26.06.2011
Go in game and do /save. It will give you a coordinate of the place you were standing and typed the cmd. Copy it from the SavedCoordinates.txt in the place you installed SAMP.
Re: How can i add teleports -
bulgarianmaniacs - 26.06.2011
Thanks Adill! I will try this.
Re: How can i add teleports -
bulgarianmaniacs - 26.06.2011
The file is
savedpositions.txt and is situated in
My Documents/GTA San Andreas User Files/SAMP.
Thank you man!
Re: How can i add teleports -
[HiC]TheKiller - 26.06.2011
Go ingame, type /save then go into the same directory as your screenshots and find savedpositions.txt or whatever it is called. Your documents -> GTA San Andreas User Files -> Samp. Take the first 3 sets of numbers with a dot in them for the SetPlayer(Vehicle)pos and the fourth value with a dot for the angle.