on *:JOIN:#:{
if ( $nick == $me ) {
set %ial $+ # 1
who #
}
}
raw 352:*:{
if ( $eval(% $+ ial $+ $2,2) == 1 ) {
haltdef
}
}
raw 315:*:{
if ( $eval(% $+ ial $+ $2,2) == 1 ) {
unset %ial $+ $2
haltdef
}
}
That will get the addresses of everyone in the channel when you join. Not sure why you have the /who $nick in (the IAL is updated with someone's address when they join anyway).