11.07.2010, 04:30
It's been a while since I've had to post here. But this is really stumping me. I've made a dialog teleport system, when I go in-game and try it out it teles me to one location out of the 10 or so on there. I've changed and re-made it twice. I don't get any error code either. Heres the code.
Command:
Command:
pawn Код:
if(!strcmp(cmdtext, "/teles", true))
{
ShowPlayerDialog(playerid, 0, DIALOG_STYLE_LIST, "Teleports","Las Venturas Teleport List\nSkyDive Teleport List","Go!","Cancel");
return 1;
}
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == 0)
{
switch(response)
{
case 1:
{
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "LV Teleports","Airport\nArea 51\nAbandon Airport\nBig Jump\nPirate Ship\nCraw Bar\nAmmunation","Go!","Cancel");
}
case 2:
{
ShowPlayerDialog(playerid, 2, DIALOG_STYLE_LIST, "LV SkyDives","Skydive #1\nSkydive #2\nSkydive #3\nSkydive #4","Go!","Cancel");
}
}
}
if(dialogid == 1)
{
switch(response)
{
case 1:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1529.1760,1592.9885,11.5522);
}
case 2:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 332.5118,1897.7848,18.3585);
}
case 3:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 250.0892,2510.0618,17.2614);
}
case 4:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, -728.7404,2397.4702,128.0639);
}
case 5:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2003.1655,1544.4967,13.5859);
}
case 6:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2437.9180,2054.7251,10.4362);
}
case 7:
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2532.6929,2083.1746,10.8203);
}
}
}
if(dialogid == 2)
{
switch(response)
{
case 1:
{
GivePlayerWeapon(playerid, 46, 1);
GameTextForPlayer(playerid, "Don't forget to pull your chute!", 5000, 5);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2057.8674,2435.8203,165.6172);
}
case 2:
{
GivePlayerWeapon(playerid, 46, 1);
GameTextForPlayer(playerid, "Don't forget to pull your chute!", 5000, 5);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1937.7056,1914.0211,122.0156);
}
case 3:
{
GivePlayerWeapon(playerid, 46, 1);
GameTextForPlayer(playerid, "Don't forget to pull your chute!", 5000, 5);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2054.0256,1574.7064,520.6119);
}
case 4:
{
GivePlayerWeapon(playerid, 46, 1);
GameTextForPlayer(playerid, "Don't forget to pull your chute!", 5000, 5);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1543.0779,-1354.4495,329.4720);
}
}
}
return 1;
}