Admin CMD help
#8

Quote:
Originally Posted by BenzoAMG
Посмотреть сообщение
Yes, and all 3 incorrect replies.

pawn Код:
CMD:admins(playerid, params[])
{
    if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You need to login first before using any command.");
    if(!PlayerInfo[playerid][pAdmin]) return SendClientMessage(playerid, COLOR_GREY, "You are not authorized to use this command!");
    new string[860], fstr[50], count = 0;
    format(string, sizeof(string), "|_____Philippine Roleplay[0.3z] Admin Team_____|{FF0000}\n\n");
    foreach(Player, i)
    {
        if(!PlayerInfo[i][pAdmin]) continue;
        count++;
        if(count > 15) continue;
        format(fstr, sizeof(fstr), " %s %s\n", RPALN(i), RPN(i));
        strcat(string, fstr);
    }
    if(!count) strcat(string, "There are no Administrators online.");
    else if(count > 15)
    {
        format(fstr, sizeof(fstr), "There are %d other Administrators online.", (count - 15));
        strcat(string, fstr);
    }
    ShowPlayerDialog(playerid, 1234, DIALOG_STYLE_MSGBOX, "Philippine Roleplay[0.3z] Admin Team", string, "Okay", "");
        //Replace '1234' with your own dialog ID.
    return 1;
}
Thanks it work.
Reply


Messages In This Thread
Admin CMD help - by Team_PRO - 01.06.2014, 04:10
Re: Admin CMD help - by rockhopper - 01.06.2014, 04:23
Re: Admin CMD help - by JeaSon - 01.06.2014, 04:23
Re: Admin CMD help - by MasonSFW - 01.06.2014, 04:24
Re: Admin CMD help - by rockhopper - 01.06.2014, 04:26
Re: Admin CMD help - by Threshold - 01.06.2014, 04:41
Re: Admin CMD help - by rockhopper - 01.06.2014, 04:50
Re: Admin CMD help - by Team_PRO - 01.06.2014, 05:02

Forum Jump:


Users browsing this thread: 3 Guest(s)