Raised This Month: $51 Target: $400
 12% 

Solved client_print_color | It does not work properly


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
wilianmaique
BANNED
Join Date: Nov 2016
Old 06-16-2019 , 16:36   client_print_color | It does not work properly
Reply With Quote #1

I'm using it this way, but the color is not changed.


PHP Code:
new prefixchat[20
Register:
PHP Code:
myvar create_cvar("my_prefix""^4[PREFIX]"
Pulling:
PHP Code:
get_pcvar_string(myvarprefixchatcharsmax(prefixchat))
client_print_color(0print_team_default"%s"prefixchat
If I change the color inside the game does not work.

Except if I use this stock

PHP Code:
stock xClientPrintColor(const id, const input[], any:...)
{
    new 
count 1players[32]
    static 
msg[191]
    
vformat(msg190input3)
    
    
replace_all(msg190"!g""^4")
    
replace_all(msg190"!y""^1")
    
replace_all(msg190"!t""^3")
    
replace_all(msg190"!t2""^0")
    
    if (
idplayers[0] = id; else get_players(playerscount"ch")

    for (new 
0counti++)
    {
        if (
is_user_connected(players[i]))
        {
            
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("SayText"), _players[i])
            
write_byte(players[i])
            
write_string(msg)
            
message_end()
        }
    }

Instead of: ^1 ^2 ^3 etc
Use: !g !t !y

Last edited by wilianmaique; 06-17-2019 at 17:46. Reason: Solved
wilianmaique is offline
Send a message via Skype™ to wilianmaique
 



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 03:10.


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