Raised This Month: $ Target: $400
 0% 

message doesn't shows when player connects


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-13-2010 , 17:12   Re: message doesn't shows when player connects
Reply With Quote #2

Your green_print() is incorrectly coded. Look at a colored print function and see how it is done there.

An example that I've used recently:

PHP Code:
// Prints chat in colours 
// use !g for green color 
// use !t for team color [Team color can be red ,blue or grey, It depends on players team] 
// use !y for yellow color 
stock client_colored_print(const id, const input[], any:...) 

    new 
iCount 1iPlayers[32

    static 
szMsg[191
    
vformat(szMsgcharsmax(szMsg), input3

    
replace_all(szMsg190"!g""^4"// green txt 
    
replace_all(szMsg190"!y""^1"// orange txt 
    
replace_all(szMsg190"!t""^3"// team txt 

    
if(idiPlayers[0] = id 
    
else get_players(iPlayersiCount"ch"

    for (new 
0iCounti++) 
    { 
        if (
is_user_connected(iPlayers[i])) 
        { 
            
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("SayText"), _iPlayers[i]) 
            
write_byte(iPlayers[i]) 
            
write_string(szMsg
            
message_end() 
        } 
    } 

__________________

Last edited by fysiks; 07-13-2010 at 17:16.
fysiks 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 07:06.


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