Help please with chat
#1

This works great,that is not the problem.
If Cops(green) types ;hello the chat windows says [TEAM][TLC]Bob:hello
What i want is for the team chat to be in maroon regardless of what team sends it so it would be:
[TEAM][TLC]Bob:hello


Here is the code:
Код:
public OnPlayerText(playerid, text[])
{
	if(text[0] == ';')
	{
		new string[256],name[24];
		GetPlayerName(playerid,name,24);
		format(string,256,"[TEAM] %s: %s",name,text[1]);
		for(new i = 0; i < MAX_PLAYERS; i++)
		{
			if(IsPlayerConnected(i))
			{
				if(gGroup[i] == gGroup[playerid])
				SendClientMessage(i, GetPlayerColor(playerid), string);
			}
		}
		return 0;
	}
	return 1;
}
Reply


Messages In This Thread
Help please with chat - by Mr_Finnigan - 12.07.2009, 18:54
Re: Help please with chat - by Weirdosport - 12.07.2009, 18:57
Re: Help please with chat - by Mr_Finnigan - 12.07.2009, 19:06
Re: Help please with chat - by Correlli - 12.07.2009, 19:08

Forum Jump:


Users browsing this thread: 5 Guest(s)