Licenses help
#5

I see the problem. It shows whether it's passed or not for playerb but the name of the licence is for playerid.

pawn Код:
CMD:showlicenses(playerid, params[])
{
    if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You need to login first before using any command.");
    new playerb;
    if(sscanf(params, "u", playerb)) return SendClientMessage(playerid, COLOR_WHITE, "[Usage]: /showlicenses [playerid]");
    if(!IsPlayerConnected(playerb)) return SendClientMessage(playerid, COLOR_GREY, "Invalid player id.");
    new string[43];
    format(string, sizeof(string), "|____ %s Licenses ____|", RPN(playerb));
    SendClientMessage(playerb, COLOR_LIGHTBLUE, string);
    format(string, sizeof(string), "Name: {FFFFFF}%s", RPN(playerb));
    SendClientMessage(playerb, COLOR_LIGHTBLUE, string);
    format(string, sizeof(string), "Driving License Status: {FFFFFF}%s", (PlayerInfo[playerb][pCarLic]) ? ("Passed") : ("Not Passed"));
    SendClientMessage(playerb, COLOR_LIGHTBLUE, string);
    format(string, sizeof(string), "Flying License Status: {FFFFFF}%s", (PlayerInfo[playerb][pFlyLic]) ? ("Passed") : ("Not Passed"));
    SendClientMessage(playerb, COLOR_LIGHTBLUE, string);
    format(string, sizeof(string), "Weapon License Status: {FFFFFF}%s", (PlayerInfo[playerb][pWepLic]) ? ("Passed") : ("Not Passed"));
    SendClientMessage(playerb, COLOR_LIGHTBLUE, string);
    return 1;
}
Reply


Messages In This Thread
Licenses help - by lulo356 - 27.03.2014, 09:51
Re: Licenses help - by AhmedMohamed - 27.03.2014, 09:56
Re: Licenses help - by Konstantinos - 27.03.2014, 09:57
Re: Licenses help - by lulo356 - 27.03.2014, 10:35
Re: Licenses help - by Konstantinos - 27.03.2014, 10:42
Re: Licenses help - by lulo356 - 27.03.2014, 11:54
Re: Licenses help - by Konstantinos - 27.03.2014, 12:07
Re: Licenses help - by lulo356 - 27.03.2014, 12:14
Re: Licenses help - by Konstantinos - 27.03.2014, 14:20

Forum Jump:


Users browsing this thread: 1 Guest(s)