|
前段时间测试服务器没开任何反作弊。发现一个共性,就是很多开作弊器的进来都带有广告信息。估计是免费的。
修改了一下 yanexp老大以前发布的 插件
我只是修改了一下适合我使用,没有精简也没有删除代码
[PHP]/* AMX Mod Script.
*
* (c) Copyright 2002-2003, RAV
* This file is provided as is (no warranties).
*
* Swearing will be filtered.
*
* Changelog:
* 1.20 - Fixed some bugs
* 1.10 - Initial Release
*/
#include <amxmod>
// max number of words in word list
#define MAX_WORDS 64
/*
// Number of random messages.
#define MESSAGES 4
new g_messages[MESSAGES][] = {
"三次警告内容!",
"你再发广告我就踢你出去!",
"你再发广告我就封你IP!",
"你再发广告我就长封你IP!"}
*/
// file to read words from
new g_wordList[] = "addons/amxmodx/data/wordlist.txt"
new g_swears[MAX_WORDS][32]
new g_swearsNum
new count=0
public plugin_init()
{
register_plugin("Word_Auto_Ban","0.1","YanOnline")
register_clcmd("say","swearFilter")
register_clcmd("say_team","swearFilter")
register_cvar("amx_word_ban","60")
if (file_exists(g_wordList))
{
new len, i = 0
while( read_file(g_wordList,i++,g_swears[g_swearsNum],31,len) )
if (len) ++g_swearsNum
}
else log_message("[AMX] Swear file not found (name ^"%s^")",g_wordList)
}
public swearFilter(id)
{
new said[128],says[3],names[32],ips[16],bans[5]
read_args(said,127)
for (new i=0; i<g_swearsNum; ++i)
{
if ( containi(said,g_swears) != -1 )
{
count=count+1
if (count>1){
get_user_ip(id,ips,16)
numtostr(get_cvar_num( "amx_word_ban"),bans,5)
client_print(0,print_center,"*公告:[%s]使用外挂被系统自动封%s分钟!",ips,bans)
server_cmd("amx_ban %s %s",bans,ips)
count=0
}
get_user_name(id,names,31)
numtostr(count,says,3)
//client_cmd(id,"say %s %s",says,g_messages[ random_num(0,MESSAGES-1) ])
//if (count>0)
//client_print(0,print_chat,"*第%s次警告[%s], %s",says,names,g_messages[count])
new userid = get_user_userid( id)
server_cmd( "kick #%d ^"请文明游戏,不要作弊!^"", userid)
return PLUGIN_HANDLED
}
}
return PLUGIN_CONTINUE
} [/PHP]
附上作弊器的广告词 也就是我用的wordlist.txt文件 经测试还是有一定的反作弊效果的。
Hook
C.C.A
-=911=-
-=TJC=-
-=CB=-
-=52Q=-
[H]*oo*[K]
*][-=uCa=-][*
-=w00t=-
-=[Emix]=-
--==M!ss==--
-==] C B [==-
-=D.G=-
Tiv0.01
-=D/G=-
***sky***
33660668
I feel lucky
www.cs.sushko.net
WWW.HouDao.CoM
www.cn762.com
united-cheaters
forumable.net/tc cfegames.com
ecoo168.com
飓风
飓風
顶级暴力
飄移路
5d6d
topzj.com
[老头]
[Mo Gui]
效果可以去我签名的2#服务器测试。只需要按Y输入 如Hook 就可以。 |
|