CMD:car help little
#2

You cannot have vehicle name before color1 and color2 unless you type only 1 word.

pawn Код:
CMD:car(playerid, params[])
{
    if (PlayerInfo[playerid][pAdmin] < 4 && !IsPlayerAdmin(playerid)) return SendClientMessage(playerid,COLOR_RED,"You do not have the right admin permissions for this command!");
    if (isnull(params)) return SendClientMessage(playerid, COLOR_GREY,"Syntax /car [vehicle name]");
    new vid = GetVehicleModelIDFromName(params);
    if (vid == -1) return SendClientMessage(playerid,COLOR_RED,"Invalid Vehicle");
    new Float:X, Float:Y, Float:Z, Float:Angle;
    GetPlayerPos(playerid, X, Y, Z);
    GetPlayerFacingAngle(playerid, Angle);
    LinkVehicleToInterior(vid, GetPlayerInterior(playerid));
    PlayerCar[playerid] = CreateVehicle(vid, X, Y, Z, Angle, random(255), random(255), 60);
    return 1;
}
Reply


Messages In This Thread
CMD:car help little - by ReD_HunTeR - 27.03.2014, 10:50
Re: CMD:car help little - by Konstantinos - 27.03.2014, 10:57
Re: CMD:car help little - by ReD_HunTeR - 27.03.2014, 10:59

Forum Jump:


Users browsing this thread: 1 Guest(s)