dcmd /admins [+REP]
#1

Hey all i dont know how do make /admins command for dcmd
i know all that

pawn Код:
dcmd(admins,6,cmdtext);
EnyOne can help?
Reply
#2

What's your enum used to define that a player is admin or not.
Until i know that i can't give the code although the way is to loop through all the players and see if a player is admin send his name in message else don't send.
Reply
#3

Never Mind! i got that coommand
Reply
#4

"EnyOne"? lol'd
Reply
#5

here you are:
pawn Код:
dcmd_admins(playerid, params[])
{
    SendClientMessage(playerid, COLOR_YELLOW, "Online admins:");
    new chose;
    for(new i=0;i<MAX_PLAYERS;i++)
    {
        if(AccountInfo[i][aLevel] > 0)
        {
            new name[60], string[100];
            GetPlayerName(i, name, 60);
            format(string, 100, "%s[%i] Level: %i", name, i, AccountInfo[i][aLevel]);
            SendClientMessage(playerid, COLOR_WHITE, string);
            chose = 1;
        }
    }
    if(chose == 0)
    {
        SendClientMessage(playerid, COLOR_WHITE, "No administrators online!");
    }
    return 1;
    #pragma unused params
}
Reply
#6

Quote:
Originally Posted by MAVERICKS
Посмотреть сообщение
here you are:
pawn Код:
dcmd_admins(playerid, params[])
{
    SendClientMessage(playerid, COLOR_YELLOW, "Online admins:");
    new chose;
    for(new i=0;i<MAX_PLAYERS;i++)
    {
        if(AccountInfo[i][aLevel] > 0)
        {
            new name[60], string[100];
            GetPlayerName(i, name, 60);
            format(string, 100, "%s[%i] Level: %i", name, i, AccountInfo[i][aLevel]);
            SendClientMessage(playerid, COLOR_WHITE, string);
            chose = 1;
        }
    }
    if(chose == 0)
    {
        SendClientMessage(playerid, COLOR_WHITE, "No administrators online!");
    }
    return 1;
    #pragma unused params
}
Read the comment.He says that he has found out the CMD
Reply
#7

Bumpius! - How to put this in Dialog form? (DCMD) And I will give you rep :3
Reply
#8

Quote:
Originally Posted by NeonPotatoz
Посмотреть сообщение
Bumpius! - How to put this in Dialog form? (DCMD) And I will give you rep :3
You can't even rep. Didn't you take any time at all to read the forum rules before posting? *sigh*
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)