View Single Post
Author Message
leaky
Junior Member
Join Date: Jan 2006
Old 03-14-2006 , 23:17   Fullupdate + Kick
Reply With Quote #1

I took some code from a couple plugins and tried to make it kick anyone who uses fullupdate rather than just block it. I'm new to scripting so it might be a mess but the plugins compiles fine....it just doesn't load with the server.

Code:
/* AMX Mod X script.
*
*   fullupdate Blocker (fullupdate_blocker.sma)
*   
*   This plugin should be installed above all plugins you want
*   the resetHUD event caused by the client command "fullupdate"
*
*/

#include <amxmodx>
#include <engine>
#include <cstrike>
#include <amxmisc>
#include <fun> 
new bcount[33] 
public plugin_init() { 
    register_plugin("fullupdate Blocker","1.0","JTP10181 / Uzeal") 
    register_clcmd("fullupdate","fullupdate") 
} 
public fullupdate(id) { 
    new bname[33] 
    get_user_name(id, bname, 32) 
    client_print(0,print_chat,"%s Has attempted to use *fullupdate* and was kicked.  (%i/3)", bname, bcount[id]) 
    client_print(0,print_chat,"%s Has abused the command *fullupdate* and has been kicked",bname) 
    server_cmd("amx_kick #%i", get_user_userid(id))   
    return PLUGIN_HANDLED 
}
leaky is offline