can somebody give me an example because i know how to make command but i dont know how to make like the car to a person name etc
I can show you how to spawn a car with all those parameters but i don't know much about GodFather's saving system so you have to save it yourself.
Код:
dcmd_buyveh(playerid,params[])
{
new tmp[128],tmp2[128],tmp3[128],model,color1,color2,veh,Index; new Float:x, Float:y, Float:z, Float:rot;
GetPlayerPos(playerid,x,y,z);
GetPlayerFacingAngle(playerid,rot);
tmp=strtok(params,Index);
tmp2=strtok(params,Index);
tmp3=strtok(params,Index);
if(!strlen(tmp) || !strlen(tmp2) || !strlen(tmp3)) return SendClientMessage(playerid, oxffffffaa, " Usage: /buyveh model color1 color2 ");
model=strval(tmp);
color1=strval(tmp2);
color2=strval(tmp3);
veh = CreateVehicle(model,x+3,y+3,z+1,rot,color1,color2,5000);
PutPlayerInVehicle(playerid,veh,0);
return 1;
}