Raised This Month: $ Target: $400
 0% 

[HELP]Strange error (hud messages)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Flick3rR
Veteran Member
Join Date: Feb 2014
Location: Bulgaria, Stara Zagora
Old 03-18-2014 , 16:41   [HELP]Strange error (hud messages)
Reply With Quote #1

Hello, this is the code and I couldn't fix the error. Thanks for help!

PHP Code:
   #include <amxmodx> 
   #include <dhudmessage>

    #define PLUGIN "WinMSG" 
    #define VERSION "0.0.2" 

    
new Trie:g_tReplacements 


    
public plugin_init() 

        
register_plugin(PLUGINVERSION""
        
register_message(get_user_msgid("TextMsg"), "Message_TextMsg"
    
}

public 
hud_message(id)
{
    new 
g_name[32]
    
get_user_name(idg_name[id], 32)
    
g_tReplacements TrieCreate()  
    
TrieSetString(g_tReplacements"#Bomb_Planted",              "[CS-MaxGaminG.iNFO]^n%s zaloji bombata!"g_name);
    
TrieSetString(g_tReplacements"#CTs_Win",                   "[CS-MaxGaminG.iNFO]^nCounter-Teroristite specheliha!");
    
TrieSetString(g_tReplacements"#Terrorists_Win",            "[CS-MaxGaminG.iNFO]^nTeroristite specheliha!");
    
TrieSetString(g_tReplacements"#Round_Draw",                "[CS-MaxGaminG.iNFO]^nRundut se provali!");
    
TrieSetString(g_tReplacements"#Target_Saved",              "[CS-MaxGaminG.iNFO]^nCelta beshe zapazena!");
    
TrieSetString(g_tReplacements"#Game_Commencing",           "[CS-MaxGaminG.iNFO]^nDavaite, boi!");
    
TrieSetString(g_tReplacements"#Bomb_Defused",              "[CS-MaxGaminG.iNFO]^n%s obezvredi bombata!"g_name);
    
TrieSetString(g_tReplacements"#Target_Bombed",              "[CS-MaxGaminG.iNFO]^nBombata izbuhna!");
    
TrieSetString(g_tReplacements"##Auto_Team_Balance_Next_Round""[CS-MaxGaminG.iNFO]^nAvto Team Balance sled runda!");
}

    
    public 
Message_TextMsg(iMsgIdiMsgDestid
    { 
        if( !
id && get_msg_arg_int(1) == print_center 
        { 
            new 
szMessage[64
            
get_msg_arg_string(2szMessagecharsmax(szMessage)) 
            if( 
TrieGetString(g_tReplacementsszMessageszMessagecharsmax(szMessage)) ) 
            { 
                
set_dhudmessage(255255255, -1.00.212010.00.10.2)
                
show_dhudmessage(0szMessage
                return 
PLUGIN_HANDLED 
            

        } 
        return 
PLUGIN_CONTINUE 
    

And this is the error:
PHP Code:
ErrorNumber of arguments does not match definition on line 22 
and
PHP Code:
ErrorNumber of arguments does not match definition on line 28 
These are lines where in the hud i used g_name...
Flick3rR is offline
Send a message via Skype™ to Flick3rR
 



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


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