hashhhhh - 22/06/03 03:28 AM
Im having some trouble getting my head around this:
alias clonescan {
window -ak @Clones
var %chan = $iif($1,$1,$chan)
if (!%chan || $chr(35) !isin %chan) {
aline @clones No channel specified.
return
}
if (!$chan(%chan).ial) {
.ial on
.enable #ialupdate
.who %chan
echo @clones Updating IAL...
return
}
var %t = $ticks
aline @clones Scanning %chan $+ ...
if ($hget(clones)) hfree clones
hmake clones $nick(%chan,0)
var %x = 1
while (%x <= $nick(%chan,0)) {
hadd clones $address($nick(%chan,%x),2) $+($hget(clones,$address($nick(%chan,%x),2)),$nick(%chan,%x),$chr(44))
inc %x
}
var %x = 1
while (%x <= $hget(clones,0)) {
if ($numtok($hget(clones,%x).item,44) > 1) {
echo -s aline @clones $hget(clones,%x) - $left($hget(clones,%x).item,2)),$calc($len($hget(clones,%x).item,2))) -1))
inc %x 1
}
hfree clones
aline @clones Scan Completed in $round($calc(($ticks - %t) / 1000),2) $+ s
linesep @clones
}
}
#ialupdate off
raw 352:*:haltdef
raw 315:*:{
clonescan $2
.disable #ialupdate
haltdef
}
#ialupdate end
menu channel {
Clonescan:clonescan
}
It was working last night now it isn't.
alias clonescan {
window -ak @Clones
var %chan = $iif($1,$1,$chan)
if (!%chan || $chr(35) !isin %chan) {
aline @clones No channel specified.
return
}
if (!$chan(%chan).ial) {
.ial on
.enable #ialupdate
.who %chan
echo @clones Updating IAL...
return
}
var %t = $ticks
aline @clones Scanning %chan $+ ...
if ($hget(clones)) hfree clones
hmake clones $nick(%chan,0)
var %x = 1
while (%x <= $nick(%chan,0)) {
hadd clones $address($nick(%chan,%x),2) $+($hget(clones,$address($nick(%chan,%x),2)),$nick(%chan,%x),$chr(44))
inc %x
}
var %x = 1
while (%x <= $hget(clones,0)) {
if ($numtok($hget(clones,%x).item,44) > 1) {
echo -s aline @clones $hget(clones,%x) - $left($hget(clones,%x).item,2)),$calc($len($hget(clones,%x).item,2))) -1))
inc %x 1
}
hfree clones
aline @clones Scan Completed in $round($calc(($ticks - %t) / 1000),2) $+ s
linesep @clones
}
}
#ialupdate off
raw 352:*:haltdef
raw 315:*:{
clonescan $2
.disable #ialupdate
haltdef
}
#ialupdate end
menu channel {
Clonescan:clonescan
}
It was working last night now it isn't.