Yeah $dns(0) doesn't work well, what I use in my script is:
Code:
if ($dns(0) == 0) {
if ($dns(0).nick && !$iaddress && !$dns(0).addr) {
.echo $color(info) -ts * /dns: no such user $dns(0).nick
halt
}
echo $color(other) -ts * Unable to resolve $iif($iaddress,$iaddress,$dns(0).addr)
}