18.12.2010, 19:36
pawn Код:
if(text[0] == '&')
{
new string[128],name[30];
GetPlayerName(playerid, name, 30);
format(string, sizeof(string), "CHAT: %s [ID: %d]: %s", name, playerid, text[1]);
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(GetPlayerTeam(playerid) == GetPlayerTeam(i)) // Send message to all players of the player which typed: & + text
{
SendClientMessage(i,0x00FFFFFF,string);
return 0;
}
}
return 0;
}