26.01.2013, 15:43
Hello SA-MP!
Today i made a teleport command for my server in a dialog, it compiles all fine but when i click the teleport nothing happens! And my dialog ID is not the same like another one
code:
And the OnDialogResponse
It compiles with no warnings or errors but when i click on a teleport nothing happens?
Today i made a teleport command for my server in a dialog, it compiles all fine but when i click the teleport nothing happens! And my dialog ID is not the same like another one
code:
pawn Код:
SendClientMessage(playerid, 0xFF9900AA, "Welcome! here are the server teleports!");
ShowPlayerDialog(playerid, DIALOG_TELES, DIALOG_STYLE_LIST, "Server Teleports:", "Antenna 1\nAntenna 2 \nAntenna 3 \nAntenna 4 \nCave 1 \nCave 2 \nCave 3 \nSkyDive \nDive \nParkour \nParkour 2 \nMiniGun DeathMatch \nHydra Deathmatch \nDeagle Deathmatch \nLos Santos AirPort \nSan Fierro Airport \nLas Venturas Airport \nBallon 1 \nBallon 2 \nTunnel FlyBy \n Cave 3 FlyBy (flyby 1) \nNrg Parkour \nBaseJumpTunnel \nAbandoned Airport", "Teleport", "Cancel");
pawn Код:
}
if(response)
{
switch(DIALOG_TELES)
{
case 1:
{
switch(listitem)
{
case 0: // antenna 1
{
SetPlayerPos(playerid,-2322.7739,-1686.6934,623.5859);
}
case 1: //antenna 2
{
SetPlayerPos(playerid,-2509.5818,-717.0885,279.7344);
}
case 2: //antenna 3
{
SetPlayerPos(playerid, -2132.7388,-1544.7836,451.5301);
}
case 3: // antenna 4
{
SetPlayerPos(playerid, -2579.2988,-1580.0002,519.6859);
}
case 4: //cave 1
{
SetPlayerPos(playerid,-5.79980469,7534.39941406,3041.60009766);
}
case 5: //cave 2
{
SetPlayerPos(playerid, 3443.69995117,540.90002441,2014.00000000);
}
case 6: //cave 3
{
SetPlayerPos(playerid, -497.2711,3845.8472,1348.2886);
}
case 7: //skydive
{
SetPlayerPos(playerid, -2375.5886,-1640.5045,706.6332);
}
case 8: //dive
{
SetPlayerPos(playerid,1867.1786,-146.1077,2465.8916);
}
case 9: //parkour
{
SetPlayerPos(playerid, 1857.4773,516.9883,686.0547);
}
case 10: //parkour 2
{
SetPlayerPos(playerid, 3846.7241,-1393.3911,341.2547);
}
case 11: // Mgdm
{
new Random = random(sizeof(RandomSpawns));
SetPlayerPos(playerid, RandomSpawns[Random][0], RandomSpawns[Random][1], RandomSpawns[Random][2]);
SetPlayerFacingAngle(playerid, RandomSpawns[Random][3]);
ResetPlayerWeaponsEx(playerid, 38);
}
case 12: // Hydra dm
{
new Random = random(sizeof(HydraSpawns));
SetPlayerPos(playerid, HydraSpawns[Random][0], HydraSpawns[Random][1], HydraSpawns[Random][2]);
SetPlayerFacingAngle(playerid, HydraSpawns[Random][3]);
ResetPlayerWeapons(playerid);
}
case 13: //Deagle DM
{
new RandomSpawn = random(sizeof(DESpawns));
SetPlayerPos(playerid, DESpawns[RandomSpawn][0], DESpawns[RandomSpawn][1], DESpawns[RandomSpawn][2]);
SetPlayerFacingAngle(playerid, DESpawns[RandomSpawn][3]);
ResetPlayerWeaponsEx(playerid, 24);
}
case 14: //Air ls
{
SetPlayerPos(playerid,2087.4424,-2502.4993,13.5391);
}
case 15: //air sf
{
SetPlayerPos(playerid,-1657.5786,-192.9511,14.1484);
}
case 16: // Air LV
{
SetPlayerPos(playerid,1466.7666,1740.3820,10.8125);
}
case 17: // Ballon 1
{
SetPlayerPos(playerid, -2867.1990,2632.0366,687.3877);
}
case 18: // Ballon 2
{
SetPlayerPos(playerid, -1103.5732,794.2228,230.4996);
}
case 19: // BJT FlyBy
{
SetPlayerPos(playerid,-1601.6671,-775.5167,862.7448);
}
case 20: // Cave 3 FlYbY
{
SetPlayerPos(playerid,-650.0091,3848.4526,1073.7462);
}
case 21: // NRG Parkour
{
SetPlayerPos(playerid, 2959.1812,2216.5710,37.2490);
}
case 22: // BJT
{
SetPlayerPos(playerid,-1594.6263,-756.2234,990.3872);
}
case 23: // AA
{
SetPlayerPos(playerid,388.5352,2499.5645,16.4844);
}
}
}
}
return 1;
}
return 0;