Sziasztok elkezdtem egy dialogos tuning aútó lehívót csinálni, de valamiért nem rakja le a kocsit ha kiválasztom a menüböl
#include <a_samp>
#define dialog_1 100
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp(\"/tuningcars\", cmdtext, true, 10) == 0)
{
ShowPlayerDialog(playerid, dialog_1, DIALOG_STYLE_LIST, \"Tuningolt autók\", \"Sultan\\nElegy\\nJester\", \"Spawn\", \"Kilépés\");
return 1;
}
return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == dialog_1)
{
if(response)
{
if(listitem == 0)
{
new car, Float:X, Float:Y, Float:Z, string[64], pName[64];
GetPlayerPos(playerid, X, Y, Z);
car = CreateVehicle(560, X+1, Y+1, Z, 195.5766, 86, 86, 0);
ChangeVehiclePaintjob(car, 0); //F�nyez�s 1
AddVehicleComponent(car, 1028); //Kipufog�
AddVehicleComponent(car, 1169); //Els� l�kh�r�t�
AddVehicleComponent(car, 1141); //H�ts� l�kh�rit�
AddVehicleComponent(car, 1033); //Tet�
AddVehicleComponent(car, 1139); //Spoiler
AddVehicleComponent(car, 1031); //K�sz�b
AddVehicleComponent(car, 1030); //K�sz�b
AddVehicleComponent(car, 1078); //Felni
AddVehicleComponent(car, 1087); //Hiaraulika
AddVehicleComponent(car, 1010); //Nitr�;
GetPlayerName(playerid, pName, 64);
format(string, 64, \"%s Lespawnolt egy Petya álltal tuningolt Sultan-t\", pName);
SendClientMessageToAll(0x33CCFFAA, string);
}
if(listitem == 1)
{
new car, Float:X, Float:Y, Float:Z, string[64], pName[64];
GetPlayerPos(playerid, X, Y, Z);
car = CreateVehicle(562, X+1, Y+1, Z, 195.5766, 86, 86, 0);
ChangeVehiclePaintjob(car, 0); //F�nyez�s 1
ChangeVehicleColor(car, 79,79); //Szin
AddVehicleComponent(car, 1034); //Kipufog�
AddVehicleComponent(car, 1171); //Els� l�kh�r�t�
AddVehicleComponent(car, 1149); //H�ts� l�kh�rit�
AddVehicleComponent(car, 1035); //Tet�
AddVehicleComponent(car, 1146); //Spoiler
AddVehicleComponent(car, 1039); //K�sz�b
AddVehicleComponent(car, 1041); //K�sz�b
AddVehicleComponent(car, 1078); //Felni
AddVehicleComponent(car, 1087); //Hiaraulika
AddVehicleComponent(car, 1010); //Nitr�;
GetPlayerName(playerid, pName, 64);
format(string, 64, \"%s Lespawnolt egy Petya álltal tuningolt Elegy-et\", pName);
SendClientMessageToAll(0x33CCFFAA, string);
}
if(listitem == 2)
{
new car, Float:X, Float:Y, Float:Z, string[64], pName[64];
GetPlayerPos(playerid, X, Y, Z);
car = CreateVehicle(559, X+1, Y+1, Z, 195.5766, 86, 86, 0);
ChangeVehiclePaintjob(car, 2); //F�nyez�s 1
ChangeVehicleColor(car, 79,79); //Szin
AddVehicleComponent(car, 1065); //Kipufog�
AddVehicleComponent(car, 1160); //Els� l�kh�r�t�
AddVehicleComponent(car, 1159); //H�ts� l�kh�rit�
AddVehicleComponent(car, 1162); //Spoiler
AddVehicleComponent(car, 1069); //K�sz�b
AddVehicleComponent(car, 1071); //K�sz�b
AddVehicleComponent(car, 1078); //Felni
AddVehicleComponent(car, 1087); //Hiaraulika
AddVehicleComponent(car, 1010); //Nitr�;
GetPlayerName(playerid, pName, 64);
format(string, 64, \"%s Lespawnolt egy Petya álltal tuningolt Jester-t\", pName);
SendClientMessageToAll(0x33CCFFAA, string);
}
}
}else{
SendClientMessage(playerid, 0x400000FF, \"Kiléptél\");
}
return 0;
}
Eddig müködik
https://fbcdn-sphotos-f-a.akamaihd.net/hphotos-ak-prn1/68237_179768555496999_2095508889_n.jpg[/img]
A kocsi lerakása biztos hogy jó mert abba már segítettek és már használtam parrancsal.
A segítséget elõre is köszönöm