Vip Chat![Help] [+ Rep]
#6

pawn Код:
public OnPlayerText(playerid, text[])
{
if(text[0] == '.' && PlayerInfo[playerid][pLevel] >= 1 || PlayerInfo[playerid][dRank] >= 1)
{
new string[128]; GetPlayerName(playerid,string,sizeof(string));
format(string,sizeof(string),"VIP.Chat: %s: %s",string,text[1]);
MessageToVips(COLOR_PINK,string);
return 0;
}
return 1;
}
MessageToVips
pawn Код:
forward MessageToVips(color,const string[]);
public MessageToVips(color,const string[])
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i) == 1) if (PlayerInfo[i][dRank] >= 1) SendClientMessage(i, color, string);
    }
    return 1;
}
DONE
EDIT: a sec late from v.
Reply


Messages In This Thread
Vip Chat![Help] [+ Rep] - by Nirzor - 27.09.2012, 14:02
Re: Vip Chat![Help] [+ Rep] - by kbalor - 27.09.2012, 14:10
Re: Vip Chat![Help] [+ Rep] - by SmithyComp - 27.09.2012, 14:10
Re: Vip Chat![Help] [+ Rep] - by Nirzor - 27.09.2012, 14:24
Re: Vip Chat![Help] [+ Rep] - by .v - 27.09.2012, 14:26
Re: Vip Chat![Help] [+ Rep] - by Jarnu - 27.09.2012, 14:28
Re: Vip Chat![Help] [+ Rep] - by .v - 27.09.2012, 14:32
Re: Vip Chat![Help] [+ Rep] - by Nirzor - 27.09.2012, 14:44

Forum Jump:


Users browsing this thread: 1 Guest(s)