admin chat is not working...
#5

That's mine working 100%
pawn Код:
forward SendAdminMessage(color, string[]);
public SendAdminMessage(color, string[])
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            if(PlayerInfo[i][pAdmin] > 0)
            {
                SendClientMessage(i, COLOR_YELLOW, string);
            }
        }
    }
}

//command
dcmd_ac(playerid,params[])
{
    new string[128];
    new pname[MAX_PLAYER_NAME];
    GetPlayerName(playerid,pname,sizeof(pname));
    if(!strlen(params))
    {
        SendClientMessage(playerid,COLOR_ERROR,"[USAGE] /ac (Message)");
        return 1;
    }
    format(string,sizeof(string),"[ADMIN CHAT]  %s(%d): %s",pname,playerid,params);
    SendAdminMessage(COLOR_YELLOW,string);
    return 1;
}
Reply


Messages In This Thread
admin chat is not working... - by Anak - 23.07.2013, 15:52
Re: admin chat is not working... - by Anak - 23.07.2013, 16:45
Re: admin chat is not working... - by ThePhenix - 23.07.2013, 16:58
Re: admin chat is not working... - by Income - 23.07.2013, 21:15
Re: admin chat is not working... - by Vanter - 23.07.2013, 22:12

Forum Jump:


Users browsing this thread: 1 Guest(s)