From d6b704e74c1786d8a9a23aec9bea3d00bd91ff0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johnny=20Bergstr=C3=B6m?= Date: Fri, 25 Mar 2005 09:40:04 +0000 Subject: [PATCH] Updated from http://www.amxmodx.org/forums/viewtopic.php?p=99878 To ban LAN:ers by IP and not authid. --- plugins/plmenu.sma | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/plugins/plmenu.sma b/plugins/plmenu.sma index 53f96f60..6f256e5b 100755 --- a/plugins/plmenu.sma +++ b/plugins/plmenu.sma @@ -85,13 +85,19 @@ public plugin_init() { public actionBanMenu(id,key) { switch (key) { case 7: { + /* BEGIN OF CHANGES BY MISTAGEE + ADDED A FEW MORE OPTIONS */ ++g_menuOption[id] - g_menuOption[id] %= 3 + g_menuOption[id] %= 7 switch(g_menuOption[id]){ case 0: g_menuSettings[id] = 0 case 1: g_menuSettings[id] = 5 - case 2: g_menuSettings[id] = 60 + case 2: g_menuSettings[id] = 10 + case 3: g_menuSettings[id] = 15 + case 4: g_menuSettings[id] = 30 + case 5: g_menuSettings[id] = 45 + case 6: g_menuSettings[id] = 60 } displayBanMenu(id,g_menuPosition[id]) @@ -115,8 +121,10 @@ public actionBanMenu(id,key) { case 2: client_print(0,print_chat,"%L",LANG_PLAYER,"ADMIN_BAN_2",name,name2) case 1: client_print(0,print_chat,"%L",LANG_PLAYER,"ADMIN_BAN_1",name2) } - - if (equal("4294967295",authid2)) { /* lan */ + + /* ---------- check for Steam ID added by MistaGee -------------------- + IF AUTHID == 4294967295 OR VALVE_ID_LAN OR HLTV, BAN PER IP TO NOT BAN EVERYONE */ + if ( (equal("4294967295",authid2)) || (equal("HLTV",authid2)) || (equali("VALVE_ID_LAN",authid2))) { /* lan or HLTV!*/ /* END OF MODIFICATIONS BY MISTAGEE */ new ipa[32] get_user_ip(player,ipa,31,1) server_cmd("addip %d %s;writeip",g_menuSettings[id],ipa)