just small code/fix
#4

Check my update again.

pawn Код:
#define     CUTTER_RIMS     1079
#define     GOLD_RIMS       1080

CMD:cutterrims(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] < 2) return SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
    AddRims(playerid, CUTTER_RIMS, "Cutter Rims");
    return 1;
}


CMD:goldrims(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] < 2) return SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
    AddRims(playerid, GOLD_RIMS, "Gold Rims");
    return 1;
}

stock AddRims(playerid, type, name[])
{
    if(!IsPlayerInAnyVehicle(playerid))
    {
        new line[128];
        format(line, sizeof(line), "You must be in a car to add %s.", name);
        return SendClientMessageEx(playerid, line);
    }
    else
    {
        new line[128];
        AddVehicleComponent(GetPlayerVehicleID(playerid), type);
        format(line, sizeof(line), "%s Added To Vehicle!", name);
        SendClientMessageEx(playerid, COLOR_WHITE, line);
    }
    return 1;
}
Reply


Messages In This Thread
!-Solved-! !-Thanks-! - by Joe_Goro - 17.11.2013, 06:51
Re: just small code/fix - by Pottus - 17.11.2013, 06:57
Re: just small code/fix - by Joe_Goro - 17.11.2013, 07:01
Re: just small code/fix - by Pottus - 17.11.2013, 07:02
Re: just small code/fix - by Joe_Goro - 17.11.2013, 07:06
Solved - Working - by Joe_Goro - 17.11.2013, 07:20

Forum Jump:


Users browsing this thread: 1 Guest(s)