Colors
#4

Quote:
Originally Posted by WThieves
Quote:
Originally Posted by CalgonX
pawn Код:
public OnPlayerText(playerid, text[])
{
    new string[128], name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "%s (%d): %s", name, playerid, text);
   
    switch(GetPlayerTeam(playerid))
    {
        case 0: SendClientMessageToAll(GREEN, string);
        case 1: SendClientMessageToAll(YELLOW, string);
        case 2: SendClientMessageToAll(RED, string);
        default: SendClientMessageToAll(WHITE, string);
    }
   
    return 0;
}
I haven't defined the colours, you'll have to change them, they were there as an example.
Yes but this changes the whole string to a colour, but it should be only the id and the name , so the text is white!
Not possible by team.

https://sampwiki.blast.hk/wiki/OnPlayerText
Reply


Messages In This Thread
Colors - by WThieves - 11.01.2010, 19:12
Re: Colors - by Calgon - 11.01.2010, 19:26
Re: Colors - by WThieves - 11.01.2010, 19:28
Re: Colors - by Calgon - 11.01.2010, 19:36
Re: Colors - by WThieves - 11.01.2010, 19:38
Re: Colors - by Calgon - 11.01.2010, 19:42
Re: Colors - by WThieves - 11.01.2010, 19:43
Re: Colors - by Calgon - 11.01.2010, 19:45
Re: Colors - by WThieves - 11.01.2010, 19:58
Re: Colors - by MadeMan - 11.01.2010, 20:04

Forum Jump:


Users browsing this thread: 1 Guest(s)