Kick+ban Inviter/Flooder
Platform: mIRC
Published Mar 07, 2005
Updated Sep 04, 2008
This snippet is an advertiser and flooder detector which detects in Query and Channel.<br>
This snippet kick and ban the detected nick from all channel you are in and OP.<br>
To prevent kicking someone you protect, add the user in a friend list which u may add the user in channel nicklist or in query "popups".<br>
It will auto unban the user after 5 minutes, in all channel.<br><br>
The Flood protection only detect 5 row in 3 seconds. So, don't wonder why doesn't all flooder this snippet kick.
menu nicklist,query {
Protect
.List Friend:hlst
.-
.Add as A Friend:/auser MFnd $$1
.Del as A Friend:/ruser MFnd $$1
}
on *:text:*:*:{
if ($level($nick != MFnd)) {
$iif($tchk($1-),ka $v1 $regml(1),inc -u3 $+(%,flood.,$nick,.,$target)) | $iif($($+(%,flood.,$nick,.,$target),2) >= 5,ka Excess Flooding)
}
}
on *:notice:*:*:{
if ($level($nick != MFnd)) {
$iif($tchk($1-),ka $v1 $regml(1),inc -u3 $+(%,flood.,$nick,.,$target)) | $iif($($+(%,flood.,$nick,.,$target),2) >= 5,ka Excess Flooding)
}
}
on *:invite:#: $iif($level($nick != MFnd),ka Invting Detected)
alias tchk $iif($regex($1-,/(?:^| )(\/server|(http+(s\:|\:)+\/\/)|(w{3}\.{1}+((\w|\d).*)+\.{1}+\w{2,3}\b)|(#(\w|\d)\S+)|\/join|\/j)/gs),return Advertising,return 0)
alias ka {
ignore -u5 $nick | var %n = 1, %c, %kb
while (%n <= $comchan($nick,0)) {
%c = $comchan($nick,%n)
if ($me isop %c) && ($nick !isop %c) && ($nick ison %c) { kick %c $nick $1- | ban -u300 %c $nick 2 | %kb = %kb %c }
inc %n
}
$iif(%kb,echo -a 4---> Detected $+ $nick $+ Inviting. Kick/Ban Perform on $+ %kb $+ )
}
alias hlst { window @Friend | var %n = 1 | while (%n <= $ulist(*,0)) { if ($level($ulist(*,%n)) == MFnd) echo @Friend $ulist(*,%n) | inc %n } }