27.09.2012, 14:28
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;
}
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;
}
EDIT: a sec late from v.