AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [HOWTO] Make a colormessage MultiLangual (https://forums.alliedmods.net/showthread.php?t=88964)

crazyeffect 03-31-2009 06:10

[HOWTO] Make a colormessage MultiLangual
 
<FONT color=black>
PHP Code:

        case 1//Red
        
{
            
ColorChat(0RED"Say /cm to see the validable Commands to you!");
            
set_task(float(get_pcvar_num(ad_time)), "ads");
        } 

</SPAN>

How to make this multilangual?

I tried this:

PHP Code:

        case 1//Red
        
{
            
ColorChat(0RED"%L"LANG_PLAYER"MESSAGE");
            
set_task(float(get_pcvar_num(ad_time)), "ads");
        } 

</SPAN>

But i don't sure know that it works or not :/

Arkshine 03-31-2009 06:35

Re: [HOWTO] Make a colormessage MultiLangual
 
Take a look in gungame or any plugin which use ML + color.

crazyeffect 03-31-2009 06:50

Re: [HOWTO] Make a colormessage MultiLangual
 
I looked, but the problem is that i don't know how to use it with random...

PHP Code:

new g_Barman[ ][ ] =
{
 
"msg1"
 "msg2"
 "msg3"
}; 

PHP Code:

public Barman_Says()
{
        if(
get_cvar_num("Say_Time") >= 1)
        {
 
                switch(
random_num(0,5))
                {
                        case 
1:
                        {
                                
ColorChat(0RED"%s"g_Barman);
                                
set_task(float(get_pcvar_num(Say_Time)), "Barman_Says");
                        }
                        case 
2:
                        {
                                
ColorChat(0BLUE"%s"g_Barman);
                                
set_task(float(get_pcvar_num(Say_Time)), "Barman_Says");
                        }
                        case 
3:
                        {
                                
ColorChat(0GREY"%s"g_Barman);
                                
set_task(float(get_pcvar_num(Say_Time)), "Barman_Says");
                        }
                        case 
4:
                        {
                                
ColorChat(0NORMAL"%s"g_Barman);
                                
set_task(float(get_pcvar_num(Say_Time)), "Barman_Says");
                        }
                        case 
5:
                        {
                                
ColorChat(0GREEN"%s"g_Barman);
                                
set_task(float(get_pcvar_num(Say_Time)), "Barman_Says");
                        }
                }
                return
        }



vato loco [GE-S] 03-31-2009 15:34

Re: [HOWTO] Make a colormessage MultiLangual
 
did you try something like this

PHP Code:

    new testmsg[256]
    
    
formatex(testmsg255"%L"LANG_PLAYER"TEST")
    
ColorChat(0REDtestmsg


One 03-31-2009 15:56

Re: [HOWTO] Make a colormessage MultiLangual
 
OFF: hihi ty crazy

AntiBots 03-31-2009 16:35

Re: [HOWTO] Make a colormessage MultiLangual
 
1 Attachment(s)
-->


All times are GMT -4. The time now is 02:25.

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