Raised This Month: $ Target: $400
 0% 

Hide chat Triggers


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Caldeum
Senior Member
Join Date: Jul 2010
Location: United Kingdom
Old 08-08-2012 , 04:27   Hide chat Triggers
Reply With Quote #1

Please can anyone convert this code to amxmodx? and add triggers.ini file where i can add custom triggers?

PHP Code:
public OnPluginStart()
{
    
RegConsoleCmd("say"OnSay);
    
RegConsoleCmd("say_team"OnSay);
    
    
HiddenChatTriggers CreateTrie( );
    
SetTrieValue(HiddenChatTriggers"rank"true);
}

public 
Action:OnSay(clientargs)
{
    
decl String:arg[8];
    
GetCmdArgString(argsizeof arg);
    
StripQuotes(arg);
    
    new 
dummy;
    
    if (
GetTrieValue(HiddenChatTriggersargdummy))
    {
        return 
Plugin_Handled;
    }
    
    switch (
arg[0])
    {
        case 
'/''!''.':
        {
            if (
GetTrieValue(HiddenChatTriggersarg[1], dummy))
            {
                return 
Plugin_Handled;
            }
        }
    }
    return 
Plugin_Continue;

__________________
Of all the things I lost, I miss my brain the most.
Caldeum 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 05:43.


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