Raised This Month: $ Target: $400
 0% 

Improve Autobuy bug fixer?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
DreamWorks
Senior Member
Join Date: Mar 2012
Old 06-15-2012 , 09:59   Re: Improve Autobuy bug fixer?
Reply With Quote #1

Here you go ;)
PHP Code:
#include <amxmodx>

#define PLUGIN_NAME    "Fix AutoBuy Bug"
#define PLUGIN_VERSION    "1.1"
#define PLUGIN_AUTHOR    "PomanoB & UFPS.Team"

new g_logfile[64]

public 
plugin_init( )
{
    
register_pluginPLUGIN_NAMEPLUGIN_VERSIONPLUGIN_AUTHOR )

    
register_clcmd"cl_setautobuy""cmd_check" )
    
register_clcmd"cl_setrebuy""cmd_check" )

    
get_time "autobuy_%Y%m.log"g_logfilecharsmax g_logfile ) )
}

public 
plugin_cfg() 

    if(
is_plugin_loaded("Pause Plugins") > -1
        
server_cmd("amx_pausecfg add ^"Fix AutoBuy Bug^""); 
}

public 
cmd_checkid )
{
    static 
arg[512], argsi
    args 
read_argc( )

    for( 
1args; ++)
    {
        
read_argviargcharsmaxarg ) )

        if( 
is_cmd_longargcharsmaxarg ) ) )
        {
            
log_autobuyid )
            return 
PLUGIN_HANDLED
        
}
    }

    return 
PLUGIN_CONTINUE
}

stock bool:is_cmd_longstring[], const len )
{
    static 
cmd[512]

    while( 
strlen( string ) )
    {
        
strtokstringcmdcharsmaxcmd ), stringlen ' ')

        if( 
strlencmd ) > 31 ) return true
    
}

    return 
false
}

stock log_autobuyid )
{
    static 
name[32], steamid[44], ip[16]
    
get_user_ipidipcharsmaxip ), )
    
get_user_authididsteamidcharsmaxsteamid ) )
    
get_user_nameidnamecharsmaxname ) )


    
set_hudmessage(255000.600.6026.012.00.10.52)
    
show_hudmessage(0"%s is using Autobuy ! Get lost lammer"name

    
log_to_fileg_logfile"AutoBuyBug used by: %s [%s] [%s]"nameipsteamid )

DreamWorks is offline
kbr
Member
Join Date: Sep 2011
Old 06-16-2012 , 03:53   Re: Improve Autobuy bug fixer?
Reply With Quote #2

Quote:
Originally Posted by DreamWorks View Post
Here you go ;)
PHP Code:
#include <amxmodx>

#define PLUGIN_NAME    "Fix AutoBuy Bug"
#define PLUGIN_VERSION    "1.1"
#define PLUGIN_AUTHOR    "PomanoB & UFPS.Team"

new g_logfile[64]

public 
plugin_init( )
{
    
register_pluginPLUGIN_NAMEPLUGIN_VERSIONPLUGIN_AUTHOR )

    
register_clcmd"cl_setautobuy""cmd_check" )
    
register_clcmd"cl_setrebuy""cmd_check" )

    
get_time "autobuy_%Y%m.log"g_logfilecharsmax g_logfile ) )
}

public 
plugin_cfg() 

    if(
is_plugin_loaded("Pause Plugins") > -1
        
server_cmd("amx_pausecfg add ^"Fix AutoBuy Bug^""); 
}

public 
cmd_checkid )
{
    static 
arg[512], argsi
    args 
read_argc( )

    for( 
1args; ++)
    {
        
read_argviargcharsmaxarg ) )

        if( 
is_cmd_longargcharsmaxarg ) ) )
        {
            
log_autobuyid )
            return 
PLUGIN_HANDLED
        
}
    }

    return 
PLUGIN_CONTINUE
}

stock bool:is_cmd_longstring[], const len )
{
    static 
cmd[512]

    while( 
strlen( string ) )
    {
        
strtokstringcmdcharsmaxcmd ), stringlen ' ')

        if( 
strlencmd ) > 31 ) return true
    
}

    return 
false
}

stock log_autobuyid )
{
    static 
name[32], steamid[44], ip[16]
    
get_user_ipidipcharsmaxip ), )
    
get_user_authididsteamidcharsmaxsteamid ) )
    
get_user_nameidnamecharsmaxname ) )


    
set_hudmessage(255000.600.6026.012.00.10.52)
    
show_hudmessage(0"%s is using Autobuy ! Get lost lammer"name

    
log_to_fileg_logfile"AutoBuyBug used by: %s [%s] [%s]"nameipsteamid )

Thnaks! it's perfect
kbr is offline
Reply



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:38.


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