Help with teleport - 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 with teleport (
/showthread.php?tid=198551)
Help with teleport -
Negat1Ve - 12.12.2010
Hello!
Can someone tell me how to make random teleport system?
When i write /dm
i will spawn at 3 places not only 1.
When i write one time i will spawn in one place when i write again /dm i will spawn in another place. How to do it please help me.
Re: Help with teleport -
Randyy - 26.02.2011
I think You make a Fault or didnt close It. or you did make wrong CMD
Re: Help with teleport -
MP2 - 26.02.2011
pawn Код:
new Float:teleports[][4] = {
{x, y, z, angle},
{x, y, z, angle},
{x, y, z, angle}
};
To teleport to one of those randomly:
new rand = random(sizeof(teleports));
SetPlayerPos(playerid, teleports[rand][0], teleports[rand][1], teleports[rand][2]);
SetPlayerFacingAngle(playerid, teleports[rand][3]);