download other admin system and sure there this commands with admins system cool
try this im using this code. Working
Код:
//==============================================================================
CMD:v(playerid, params[])
{
if(dini_Int(pFile(playerid),"AdminLevel") >= 4)
{
if(AdminLogin[playerid] != 1) return SendClientMessage(playerid,COLOR_GREY,"Error: You are not logged in as Administrator!");
new veh[64], col1, col2, id, done;
if(sscanf(params, "s", veh))
{
SendClientMessage(playerid, COLOR_WHITE, "Usage: /v [ModelID/Name]");
SendClientMessage(playerid, COLOR_ORANGE, "Function: Will create a Car with specified Colours");
return 1;
}
new string[128];
if(!IsNumeric(veh))
id = GetVehicleModelIDFromName(veh);
else id = strval(veh);
if(id < 400 || id > 611) return SendClientMessage(playerid, red, "ERROR: Invalid Vehicle Model ID!");
col1 = random(126);
col2 = random(126);
new Float:X,Float:Y,Float:Z;
new Float:Angle,int1;
GetPlayerPos(playerid, X,Y,Z);
GetPlayerFacingAngle(playerid,Angle);
for(new i=0; i<MAX_ADMIN_VEHS; i++)
{
if(!Veh[i])
{
Veh[i] = CreateVehicle(id, X+3,Y,Z, Angle, col1, col2, -1);
LinkVehicleToInterior(Veh[i],int1);
format(string, sizeof(string), "You have Spawned a %s (Model: %d) with Colours: %d,%d", VehicleNames[id-400], id, col1, col2);
PutPlayerInVehicle(playerid, Veh[i], 0);
fuel[i] = fuel[i] = 100;
done = 1;
i = MAX_ADMIN_VEHS;
}
}
if(!done) format(string, sizeof(string), "There are no vehicle slots left.");
return SendClientMessage(playerid,COLOR_SYSTEM, string);
}
return 1;
}