/a(adminchat) problem
#1

I want to make an adminchat, but i can't get it finished, i want to send the client message to all admins but i don't have an idea to do that.

Im so far:

pawn Код:
if(strcmp(cmd, "/a", true) == 0)
        {
        if(pInfo[playerid][Admin] >= 0)
        {
        tmp = strtok(cmdtext,idx), tmp2 = strtok(cmdtext,idx);
        new player1, level;
            player1 = strval(tmp);
            level = strval(tmp2);
         if(!strlen(tmp))
         {
             SendClientMessage(playerid, COLOR_YELLOW, "USAGE: /a [text]");
         }
         else
         {
                GetPlayerName(player1, playername, sizeof(playername));   GetPlayerName(playerid, adminname, sizeof(adminname));
                format(string,sizeof(string),"Adminchat (%s): %s", playername, tmp);
                SendClientMessage(playerid, purple, string);
                }
         }
         return 1;
}
Reply


Messages In This Thread
/a(adminchat) problem - by geerdinho8 - 03.01.2012, 21:24
Re: /a(adminchat) problem - by coole210 - 03.01.2012, 23:08

Forum Jump:


Users browsing this thread: 1 Guest(s)