mIRC Home    About    Download    Register    News    Help

Topic Options
#147444 - 18/04/06 08:44 PM IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
i dont understand

in help file it says for /updatenl

"Usually the channel nicknames list and IAL in a kick/part/quit script event are updated after the script finishes, this command updates them immediately."

but it does not, i have this command executed in clone scan
and it doesnt update ial addresses nor nothing

and if i understood correctly it should

so when i join channel with clones, script doesnt find them
until users (clones) do some action (like rejoin)

so is this bug or i'm missing something?


Edited by raZOR (18/04/06 08:45 PM)
_________________________
IceCapped

Top
#147445 - 18/04/06 09:48 PM Re: IAL
Bob57 Offline
Babel fish

Registered: 06/12/04
Posts: 66
Loc: Indiana, usa
When you join have a script do a /who, that will initialize the IAL for that channel. Iíve never used /updatenl, it seems specifically for use in On *:kick/part/quit: events, not general initialization of the IAL.

Top
#147446 - 18/04/06 10:00 PM Re: IAL
mIRCManiac Offline
Hoopy frood

Registered: 05/02/05
Posts: 681
Loc: Your dreams ;)
By 'updating the ial and nicklist' he means that the users nick
isn't removed from the nicklist and removed from the ial when
they quit, part or are kicked from the channel until after the
script finishes processing. /updatenl doesn't fill the ial, the IAL
is added to one nick/address at a time as they speak or join
or some kind of action on the channel, from mirc.hlp...

A user's address is added to the list either when they
join the channel, send a message to a channel, or make
a mode change.


The only way to fill the IAL when you join a channel is
to perform a /who on the channel when you join...

on ME:*:JOIN:#: {
$+(.timerWho.,$network,.,#) 1 $chan(0) if ( # ischan) who #
}
_________________________
mIRCManiac

Top
#147447 - 18/04/06 11:41 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
well look at this script:
green colored is added by me (additional)
and it still dont work altho i use /who $chan


Code:
 
;made by hixxy
;usage /clonescan

alias clones {
  [color:green].ial on [/color] 
 [color:green] .who $chan[/color] 
  if (!$chan($1).ial) updatenl
  var %clones, %i = 1
  while ($ialchan($address($2,2),$1,%i).nick) {
    if ($v1 != $2) || ($prop == ionick) %clones = %clones $ialchan($address($2,2),$1,%i).nick
    inc %i
  }
  return %clones
}

alias clonescan {
  if ($1 == $null) tokenize 32 $chan
  var %clones, %clonesdone, %i = 1
  echo $color(info) -abfilrt * Scanning for clones...
  while ($nick($1,%i)) {
    if (!$istok(%clonesdone,$v1,32)) {
      %clones = $clones($1,$nick($1,%i))
      if (%clones != $null) { 
        %clonesdone = $addtok(%clonesdone,%clones,32)
        echo $color(info) -abfilrt * Clones for $nick($1,%i) $+ : %clones ( $+ $address($nick($1,%i),2) $+ )
      }
    }
    inc %i
  }
  echo $color(info) -abfilrt * End of scan.
}

 
_________________________
IceCapped

Top
#147448 - 19/04/06 04:42 AM Re: IAL
Bob57 Offline
Babel fish

Registered: 06/12/04
Posts: 66
Loc: Indiana, usa
I think that use of $chan is only for use in a remote event such as On *:Join:..., and you are using it in aliases. You might call the alias with the name of the channel you want or if you are only going to call the alias with the channel the active mirc window you can use /who $active.

The /who needs to finish initializing the IAL before clonescan is called.

Top
#147449 - 19/04/06 05:00 AM Re: IAL
Bob57 Offline
Babel fish

Registered: 06/12/04
Posts: 66
Loc: Indiana, usa
Hmm, Iím too sleepy... I just saw that you are calling the alias clones from a loop in the alias clonescan, and clones always does a /who. You only need to use /who to initialize the IAL when You join a channel. After that mirc will update the IAL as needed as long as you are in the channel.
Code:
on *:join:#: {
  if ($nick == $me) .who $chan
}  

Top
#147450 - 19/04/06 12:26 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
well if i do that i will get choked since i join over 15 channels at once with god knows how many users :P

whould it be good if i make another alias that first calls /who $active and then /clonescan ?

~edit~
i use this

alias scanclones { .who $active | .timerclones 1 5 .clonescan }
and now it does WHO but wont run clonescan :P


Edited by raZOR (19/04/06 12:37 PM)
_________________________
IceCapped

Top
#147451 - 19/04/06 01:49 PM Re: IAL
hixxy Offline
Hoopy frood

Registered: 06/09/05
Posts: 2876
That's because $chan doesn't exist as the alias is called from a timer. Try .timerclones 1 5 clonescan $active

Top
#147452 - 19/04/06 01:57 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
hellou

alias scanclones { .who $active | .timerclones 1 5 clonescan $active }

on some weird way, it wont even run clonescan :tongue:
_________________________
IceCapped

Top
#147453 - 19/04/06 02:27 PM Re: IAL
mIRCManiac Offline
Hoopy frood

Registered: 05/02/05
Posts: 681
Loc: Your dreams ;)
Code:
alias scanclones {
  .ial on
  if ($eval($+(%,clonescan.,$active,.,$cid),2)) return
  set -eu[color:red]10[/color] $+(%,clonescan.,$active,.,$cid) $true
  who $active
}
raw 352:*:if ($eval($+(%,clonescan.,$2,.,$cid),2)) haltdef
raw 315:*: {
  if ((!$eval($+(%,clonescan.,$2,.,$cid),2)) || ($2 !ischan)) return
  haltdef
  unset $+(%,clonescan.,$2,.,$cid)
  clonescan $2
}


You may need to raise this, depending on your network lag.
_________________________
mIRCManiac

Top
#147454 - 19/04/06 03:48 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
wow, this works great !

thanks =)

thanks to hixxy for code and mIRCManiac for help =D
_________________________
IceCapped

Top
#147455 - 19/04/06 06:13 PM Re: IAL
Bob57 Offline
Babel fish

Registered: 06/12/04
Posts: 66
Loc: Indiana, usa
I donít know how you use the clone scan, if you use it more than once without rejoining the channel the IAL is already initialized so you donít need to do /who the channel again.

You can use the ďWindow IdentifiersĒ version of $chan to see if the IAL contains addresses of all users on the channel. You can add a test to mIRCManiacís code like this:

Code:
alias scanclones {

  if ($chan($active).ial) clonescan $active

  else {

    .ial on

    if ($eval($+(%,clonescan.,$active,.,$cid),2)) return

    set -eu10 $+(%,clonescan.,$active,.,$cid) $true

    who $active

  }
}  

I didnít test the alias. My situation is different, Iím an IRCop on a small server, typically 2 channels and a total of 100ish chatters at one time, so I just /who the whole thing when I join.

Top
#147456 - 19/04/06 06:32 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
cool, thats nice coz who kinda floods much =)
thanks for additional code =D

and yes it works !
_________________________
IceCapped

Top
#147457 - 19/04/06 07:02 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
but then again, does this gets updated after someone joins parts ? in which case /who actually always updates ial
_________________________
IceCapped

Top
#147458 - 19/04/06 07:13 PM Re: IAL
Bob57 Offline
Babel fish

Registered: 06/12/04
Posts: 66
Loc: Indiana, usa
From /help IAL
Quote:
A user's address is added to the list either when they join the channel, send a message to a channel, or make a mode change.

A user's address is removed from the list when they are no longer on any of the channels which you are currently on.

So you need the /who to inialize the IAL for people that were in the channel before you and haven't said anything since you got there.

Top
#147459 - 19/04/06 07:26 PM Re: IAL
raZOR Offline
Hoopy frood

Registered: 06/04/05
Posts: 1009
Loc: Green Hill Zone
oh. well i never used this ial stuff so i dont know =)
thanks.
_________________________
IceCapped

Top