29.03.2013, 13:30
Guys i copied the vehicle menu from Rajat_pawar's 0.3x Model Preveiw Script.My script compiling fine,showing me the menu but it wont spawn car.Here is the code
pawn Код:
public OnPlayerModelSelection(playerid, response, listid, modelid)
{
if(listid == alist)
{
if(response)
{
if(modelid==411)
{
ShowModelSelectionMenu(playerid,vlist,"Car menu.");
return 1;
}
}
if(listid==vlist)
{
if(response)
{
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
CreateVehicle(modelid,x+2,y+2,z+2,0,0,0,0);
SendClientMessage(playerid,COLOR_ORANGE,"You have spawned the required car.");
selectingcar[playerid]=0;
}
}
}
return 1;
}