PDA

View Full Version : Hot to create a tele


MarkzD
18/07/2012, 12:40 PM
Ho to create a teleport?

Andi_Evandy
18/07/2012, 12:57 PM
You can use "SetPlayerPos" (Basic) to do that.
More Information here: http://wiki.sa-mp.com/wiki/SetPlayerPos

Tutorial: http://forum.sa-mp.com/showthread.php?t=230341

MarkzD
18/07/2012, 12:58 PM
Thnx!

MarkzD
18/07/2012, 01:28 PM
C:\Users\Ìàêñ\Desktop\Swm.pwn(308) : warning 209: function "OnPlayerCommandText" should return a value
wtf?

public OnPlayerCommandText(playerid, cmdtext[])
if((strcmp("/stunt1", cmdtext, true) == 0) || (strcmp("/stunt", cmdtext, true) == 0))
{
SetPlayerPos(playerid, 2066.0442,-2608.5068, 13.5469);
SetPlayerFacingAngle(playerid, 180);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 14, 1);
SetPlayerVirtualWorld(playerid, 5);
SendClientMessage(playerid, 0x00FFFFAA, "You have been teleported to Stunt 1.");
return 1;
}

IstuntmanI
18/07/2012, 01:34 PM
public OnPlayerCommandText(playerid, cmdtext[])
{
if((strcmp("/stunt1", cmdtext, true) == 0) || (strcmp("/stunt", cmdtext, true) == 0))
{
SetPlayerPos(playerid, 2066.0442,-2608.5068, 13.5469);
SetPlayerFacingAngle(playerid, 180);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 14, 1);
SetPlayerVirtualWorld(playerid, 5);
SendClientMessage(playerid, 0x00FFFFAA, "You have been teleported to Stunt 1.");
return 1;
}
return 0;
}

Look on other scripts, don't start questions like these...