[HELP]:Vehicle System, Load And Save
#1

So... From This Tutorial I Write This. So How I Make Load And Save CallBacks Because I Don't Get It .
With Dini Of Course

pawn Код:
#include <a_samp>
#include <dini>

enum vInfo
{
vModelID,
vX,
vY,
vZ,
vA,
vC1,
vC2,
vOwned,
vOwner[MAX_PLAYER_NAME],
vPrice,
};

new VehicleShopInfo[MAX_VEHICLES][vInfo];
new bool:IsValidVehicle[MAX_VEHICLES];

stock GetFreeVehicleSlot()
{
for(new vID = 0; vID < sizeof(VehicleShopInfo); vID ++)
{
if(!VehicleShopInfo[i]) return i;
}
return -1;
}

stock CreateShopVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, owned, owner, price)
{
new vID = GetFreeVehicleSlot();

VehicleShopInfo[vID][vModelID] = modelid
VehicleShopInfo[vID][vX] = x
VehicleShopInfo[vID][vY] = y
VehicleShopInfo[vID][vZ] = z
VehicleShopInfo[vID][vA] = angle
VehicleShopInfo[vID][vC1] = color1
VehicleShopInfo[vID][vC2] = color2
VehicleShopInfo[vID][vOwned] = owned
VehicleShopInfo[vID][vOwner] = owner
VehicleShopInfo[vID][vPrice] = price

IsValidVehicle[vID] = true;

CreateVehicle(modelid, x, y, z, angle, color1, color2, 0);
return vID;
}
Reply


Messages In This Thread
[HELP]:Vehicle System, Load And Save - by eDz0r - 03.04.2011, 14:11
Re: [HELP]:Vehicle System, Load And Save - by eDz0r - 05.04.2011, 11:44
Re: [HELP]:Vehicle System, Load And Save - by Medal Of Honor team - 05.04.2011, 14:17
Re: [HELP]:Vehicle System, Load And Save - by eDz0r - 06.04.2011, 10:48

Forum Jump:


Users browsing this thread: 1 Guest(s)