Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ON !*:NICK: {
- set -l %t $comchan($newnick,0)
- if (!%t) || ($network !== All4Masti) { return }
- set -l %i 1
- while (%i <= %t) {
- set -l %c $comchan($newnick,%i)
- if (%c !== #test) { goto next }
- if (!$nick(%c,$me,@&~%) && (o !isin $usermode) { goto next }
- jclones_nick_check $newnick %c $ial($newnick).host
- :next
- inc %i
- }
- }
- alias jclones_nick_check {
- ; /jclones_nick_check <nickname> <#channel> <host>
- if ($0 !== 3) { return }
- set -l %hash_1 JCLONES_ $+ $2
- set -l %hash_2 JCLONESNICKS_ $+ $2
- set -l %nick_5chars $left($1,5)
- hinc -mu3 %hash_1 %nick_5chars 1
- hadd -m %hash_2 $1 $3
- set -l %nick_total $hget(%hash_1,%nick_5chars)
- if (%nick_total > 1) {
- if (!$timer([JCLONES_ [ $+ [ $2 ] $+ ] _LOCK])) {
- ;echo $chan -g 01,08 ( cloned nicks Flood ) !!!!! Channel Locked !!!!!
- .raw -q MODE $2 +MRb $+(%nick_5chars,*!*@*)
- .timer[JCLONES_ $+ $2 $+ _LOCK] 1 30 mode $unsafe($2) -MR
- }
- set -l %t $hget(%hash_2,0).item
- if (%t) {
- set -l %i 1
- while (%i <= %t) {
- set -l %n $hget(%hash_2,%i).item
- set -l %h $hget(%hash_2,%n)
- if (%n) && (%h) && (* $+ %nick_5chars $+ * iswm %n) {
- set -l %total_nicks $addtok(%total_nicks,%n,44)
- set -l %total_hosts $addtok(%total_hosts,$+(*@,%h),32)
- }
- inc %i
- }
- if (%total_hosts) { pushmodex $2 $+(+,$str(b,$numtok(%total_hosts,32))) %total_hosts }
- if (%total_nicks) { .raw -q KICK $2 %total_nicks !!! Indentical nicks !!! }
- }
- if ($hget(%hash_1)) { hfree $v1 }
- if ($hget(%hash_2)) { hfree $v1 }
- }
- }
Add Comment
Please, Sign In to add comment