stock parkVehicles(vehicleid, int, vw)
{
new Float:x, Float:y, Float:z;
GetVehiclePos(Vehicles[vehicleid][vehicleData], x, y, z);
GetVehicleZAngle(Vehicles[vehicleid][vehicleData], Vehicles[vehicleid][vehPos][3]);
Vehicles[vehicleid][vehPos][0] = x;
Vehicles[vehicleid][vehPos][1] = y;
Vehicles[vehicleid][vehPos][2] = z;
Vehicles[vehicleid][vehInt] = int;
Vehicles[vehicleid][vehVW] = vw;
saveVehicles(vehicleid);
return 1;
}
new i = Player[playerid][carVCP];
parkVehicles(i, GetPlayerInterior(playerid), GetPlayerVirtualWorld(playerid));
Server(playerid, "Your Vehicle will be spawned here next time.");
new car[MAX_PLAYERS]; new Float, Float:y, Float:z,Floatrot; GetPlayerPos(playerid, x, y, z); GetPlayerFacingAngle(playerid,Floatrot); car[playerid] = AddStaticVehicle(493, x, y, z, xrot,-1, -1); |
this is a false syntax i have the same problem with '' Vehicles[vehicleid][vehPos][0] = x ''
just create Vehicles[vehicleid][vehPosX] Vehicles[vehicleid][vehPosY] Vehicles[vehicleid][vehPosZ] |
SetVehiclePos(vehicleid, Vehicles[vehicleid][vehPos][0], Vehicles[vehicleid][vehPos][1], Vehicles[vehicleid][vehPos][2]);
stock parkVehicles(vehicleid, int, vw)
{
new Float:x, Float:y, Float:z;
GetVehiclePos(Vehicles[vehicleid][vehicleData], x, y, z);
GetVehicleZAngle(Vehicles[vehicleid][vehicleData], Vehicles[vehicleid][vehPos][3]);
Vehicles[vehicleid][vehPos][0] = x;
Vehicles[vehicleid][vehPos][1] = y;
Vehicles[vehicleid][vehPos][2] = z;
Vehicles[vehicleid][vehInt] = int;
Vehicles[vehicleid][vehVW] = vw;
DestroyVehicle(Vehicles[vehicleid][vehicleData]);
Vehicle_AddStatic(Vehicles[vehicleid][vehModel], Vehicles[vehicleid][vehPos][0], Vehicles[vehicleid][vehPos][1], Vehicles[vehicleid][vehPos][2], Vehicles[vehicleid][vehPos][3], Vehicles[vehicleid][vehColor][0], Vehicles[vehicleid][vehColor][1], 360000);
saveVehicles(vehicleid);
return 1;
}