mIRC Homepage
Posted By: Ledah $Address not always working with Quits/Parts - 13/10/06 01:58 AM
When someone part or quits before i see them join / whois them (ie: they were already in the channel), i see:
Quits: [User] (N/A)
Address is not showing, so i made a $iif to see if its empty to give N/A, but i would like to see it frown

Here are the scripts:

on ^&*:Quit: {
var %a = $iif($nickadd($nick),$v1,N/A), %c = 1
while (%c <= $comchan($nick,0)) {
echo -t $comchan($nick,%c) $hget(Theme,$event) $+(4,$nick) $partext(%a) $iif($1,$partext($1-))
inc %c
}
haltdef
}
on ^&*:Part:*: {
var %a = $iif($nickadd($nick),$v1,N/A)
tevent $chan $event $nick $partext(%a) $iif($1,$partext($1-))
}

alias -l nickadd return $right($address($1,0),-2)
alias -l Tevent {
if ($1 == -t) echo -t $2 $3-
else echo -t $1 $hget(Theme,$2) $3-
haltdef
}
Try adding /updatenl as the first line after the event line in each of those events.

From the help file: /help /updatenl
Quote:
/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.
You can use $mask($fulladdress,0) instead of $address($nick,0) in those events and it will always work.
© mIRC Discussion Forums