massjoin socket on test... :=)
on *:sockopen:c: {
if ($sockerr > 0) .halt
.var %rv.nik`usr = $+($gettok(i l I,$r(1,3),32),I,$gettok(i l I,$r(1,3),32),i,$gettok(i l I,$r(1,3),32),l,$gettok(i l I,$r(1,3),32),il,$gettok(i l I,$r(1,3),32)), %rv`nik.ver = %nik.ver
.sockwrite -tn c user %rv.nik`usr x x $+(celeron,$crlf,nick %rv.nik`usr)
}
on *:sockread:c: {
.var %c
.sockread %c
.tokenize 32 %c
if ($1 == PING) { .sockwrite -tn c pong $2 }
if ($2 == 001) {
.set %ownip $gettok($mask($11,4),2-3,46)
.sockwrite -tn c nick kekekeke
}
if ($1 == error) { titlebar Error: $1- | .timer`er 1 4 f1 }
if ($2 == 221) { .sockwrite -tn c invite %channel }
if ($2 == KICK) {
if (%knick == %ownick) {
.inc %mykick
}
if ($4 == %ownick) {
echo @kick $1-
inc %kena
if ($istok(1.2.3,%kena,46)) {
set %kickers %knick
sockwrite -nt c cs deop %channel %kickers
sockwrite -nt c cs invite %channel
}
else f1
}
}
if ($2 == JOIN) {
.var %rv.msk4 = $gettok($mask($1,4),2-3,46)
inc -u1 $+(%,mass,%channel)
if ($($+(%,mass,%channel),2) > 3) {
.add2hash
.set %channel $remove($gettok($3,1,33),:)
if (%rv.msk4 !isin %mj) .set %mj %mj $+ $+($chr(44),*,%rv.msk4,*)
$hget(a,a)
.timerkikmj2.5 -m 1 500 .unset %mj
}
if ($numtok(%mj,44) > 2) { $hget(a,b) | .timerkikmj2.d -m 1 500 .unset %mj }
}
}
;--------------------------- f
alias f1 { unset %kena | sockclose c | .sockopen c irc.webchat.org 6667 }
alias f2 { set %nik.sock $$?="nick:" | set %nik.pas $$?="Password:" | set %channel $$?="Channel:" | f1 }
alias f3 {
.timercx 1 5 sockwrite -nt c ping irc.webchat.org 6667
.hfree -sw a
.unset %mj*
sockwrite -nt c privmsg %channel 4Total kick 0 $iif(%mykick,%mykick,0) :
.timer 1 2 unset %mykick
}
;--------------------------- l
alias logo2 return 4-1,8 E x 1 1,8 P 4-
alias logo3 return 4-1,0 E x 2 1,0 P 4-
alias logo4 return 4-1,4 E x 3 1,4 P 4-
;--------------------------- h