Raised This Month: $ Target: $400
 0% 

Color Chat isn't working ?!


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
byetovice
Senior Member
Join Date: Nov 2009
Location: Turkey
Old 06-20-2011 , 04:35   Color Chat isn't working ?!
Reply With Quote #1

Code:
stock chat_color(const id, const input[], any:...)
{
 new count = 1, players[32]
 static msg[191]
 vformat(msg, 190, input, 3)
 
 replace_all(msg, 190, "!g", "^4")
 replace_all(msg, 190, "!y", "^1")
 replace_all(msg, 190, "!t", "^3")
 
 if (id) players[0] = id; else get_players(players, count, "ch")
 {
  for (new i = 0; i < count; i++)
  {
   if (is_user_connected(players[i]))
   {
    message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players[i])
    write_byte(players[i]);
    write_string(msg);
    message_end();
   }
  }
 }
}

it's the stock. I'm using that like :
chat_color(0,"[!g%s!y] Has been !tbanned !",playername)

And its printing like This :
[ byetovice ] Has been banned!
It's just printing space Help me please
__________________
Working on mods..
byetovice is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 23:26.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode