Raised This Month: $ Target: $400
 0% 

Strange Hudmessage


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Paladinrocker
Junior Member
Join Date: Jan 2007
Old 02-18-2007 , 01:36   Strange Hudmessage
Reply With Quote #1

I made a simple hlss blocking plugin, and it works (Thanks to some code I found here by Hawk), but unfortuantely my hud message doesn't work. Here's my code:

Code:
public verifyHlss(id, cvar[], value[])
{
    if(equal(value, "1"))
    {
        new playerName[32];
        get_user_name(id, playerName, 31);
    
        switch(g_blockhlssToggle)
        {
            case 1:
            {
                set_hudmessage(255, 0, 0, 0.20, 0.33, 0, 6.0, 3.0);
                show_hudmessage(0, "%s was gagged for using HLSS", playerName);
                set_speak(id, SPEAK_MUTED);
                client_cmd(id, "voice_inputfromfile 0");
                console_print(0, "[AMXX] Client ^"%s^" gagged for use of HLSS", playerName);
            }
            case 2:
            {
                set_hudmessage(255, 0, 0, 0.20, 0.33, 0, 6.0, 3.0);
                show_hudmessage(0, "%s was kicked for using HLSS", playerName);
                client_cmd(id, "voice_inputfromfile 0");
                server_cmd("kick #%i ^"The use of HLSS is prohibited^"", get_user_userid(id));
                console_print(0, "[AMXX] Client ^"%s^" kicked for use of HLSS", playerName);
            }
        }
    }
}
It's just a little code snippet where it verifies if a user has the cvar "voice_inputfromfile" on or off, and disciplines them according to a setting, but the hud message only displays on the gag, not on the kick. Not sure why, but I feel retarded over this. Thanks a lot guys if you can help.
Paladinrocker 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 00:42.


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