28.05.2011, 03:56
Testa.
pawn Код:
if(dialogid == 7799)
{
new vehicleid = GetOwnedVehicleID(playerid);
new typeid = GetVehicleType(vehicleid);
if(response)
{
if(listitem == 0)
{
new vehicleid2 = GetOwnedVehicleID(playerid);
new Float:vida;
GetVehicleHealth(vehicleid2, vida);
if (GetVehicleModel(GetPlayerVehicleID(playerid) == vehicleid2))
{//
new v = GetOwnedVehicleID(playerid);
new m = GetVehicleModel(vehicleid);
new Float:a[4];
GetVehiclePos(vehicleid, a[0], a[1], a[2]);
GetVehicleZAngle(vehicleid, a[3]);
VehicleInfo[carid][vPX] = a[0];
VehicleInfo[carid][vPY] = a[1];
VehicleInfo[carid][vPZ] = a[2];
VehicleInfo[vehicleid][vPA] = a[3];
DestroyVehicle(carid);
AddStaticVehicleEx(m,VehicleInfo[vehicleid][vPX],VehicleInfo[vehicleid][vPY],VehicleInfo[vehicleid][vPZ]+1.0,VehicleInfo[vehicleid][vPA],VehicleInfo[vehicleid][vPaintjob],VehicleInfo[vehicleid][vPaintjob],60000);
format(string, sizeof string, "|CARRO| Seu veнculo foi estacionado neste local.");
SendClientMessage(playerid, COLOR_GRAD5, string);
VehicleInfo[vehicleid][vPark] = 1;
for(new m = 0; m < MAX_MODS; m++)
{
if (VehicleInfo[vehicleid][vMod][m] > 0)
{
AddVehicleComponent(vehicleid,VehicleInfo[vehicleid][vMod][m]);
}
}
if (VehicleInfo[v][vPaintjob] > -1)
{
ChangeVehiclePaintjob(vehicleid,VehicleInfo[vehicleid][vPaintjob]);
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, "Vocк nгo esta dentro de seu veнculo da concessionaria.");
return 0x01;
}//
}//