Code:
on *:sockread:name:{
if ($sock($sockname).mark) {
while ($sock($sockname).rq > 0) {
  sockread &download_file
  .bwrite $qt(filename.mrc) -1 -1 &download_file
}
}
else {
 var %a
 sockread %a
 if (!%a) sockmark $sockname 1
 }
}
Try that

Last edited by Wims; 25/12/10 08:30 PM.

#mircscripting @ irc.swiftirc.net == the best mIRC help channel