08.10.2011, 15:05
This is my Teleport code:
The CarMenu addon is from: https://sampforum.blast.hk/showthread.php?tid=125683
pawn Код:
#include <a_samp>
#define FILTERSCRIPT
#define DIALOGID 3700
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/tp", cmdtext, true, 10) == 0)
{
ShowPlayerDialog(playerid, DIALOGID, DIALOG_STYLE_LIST, "Teleport", "Mount Chillad\nHigh House", "Go", "Cancel");
}
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(listitem == 0)
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, -2317.7593,-1634.1985,483.7031);
SendClientMessage(playerid, 0x00FFFFAA, "You've been teleported to Mount Chillad.");
}
if(listitem == 1)
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1549.2537,-1353.4073,329.4670);
SendClientMessage(playerid, 0x00FFFFAA, "You've been teleported to High House.");
}
}
The CarMenu addon is from: https://sampforum.blast.hk/showthread.php?tid=125683