Raised This Month: $ Target: $400
 0% 

Help with ban script


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
123
Veteran Member
Join Date: Apr 2005
Location: Katy, TX
Old 10-17-2005 , 14:16   Help with ban script
Reply With Quote #1

Hey.
I have this script, that bans players for 30 minutes, when they reach 70 kills.
What I need to add to it is:
1. Admin immunity (Admins with the d flag)
2. Make it log the bans with AmxBans (I thought I did this, but they aren't logged.
I hope someone will help me.

Code:
#include <amxmodx> public plugin_init() {     // ..     register_plugin("Frag Ban", "1.0", "ShadowLeader")     register_event("ResetHUD", "newSpawn", "be")     register_cvar("frags_limit", "70")     register_cvar("frags_pct_chance", "10") } public newSpawn(id) {     if ( get_user_flags(id)&ADMIN_BAN ) return PLUGIN_HANDLED     new maxplayers = get_maxplayers()     if( maxplayers >= 4 ) {         if( get_user_frags(id) >= get_cvar_num("frags_limit") ) {             new randNum = random_num(0, 100)             if ( get_cvar_num("frags_pct_chance") >= randNum ) {                 server_cmd("banid 30 #%d", get_user_userid(id))                 server_cmd("kick #%d ^"Server overflowed^"", get_user_userid(id))             }         }     }     return PLUGIN_HANDLED }
__________________
//ShadowLeader - 123
123 is offline
 


Thread Tools
Display Modes

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 23:53.


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