Id: 8037; Nick: Albie; Timestamp: 2008-03-29 08:19:34; Pasted as: mIRC
Description: n/a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
alias clearchanlev {
  var %errmsg = echo -gcat info *** Clear-Chanlev:
  if ($1- == -END) { unset %ClearChanLev.* | .remove ClearChanLev.txt | %errmsg Chanlev cleared. }
  elseif (!$0) %errmsg Usage, /clearchanlev #channel
  elseif ($me !ison $1) %errmsg $1 is an invalid channel or you're not currently on $1
  elseif (Q !ison $1) %errmsg Q isn't on $1 $+ , If you're currently in the middle of a netsplit wait untill Q returns and try again.
  elseif (%ClearChanLev.channel == $1) %errmsg The clearing of channel $1 is already underway.
  elseif (%ClearChanLev.channel) %errmsg The clearing of channel $v1 is already underway. Please wait untill all users are removed before starting a new job.
  else { 
    .msg Q chanlev $1 
    unset %ClearChanLev.*
    set %ClearChanLev.channel $1
    write -c ClearChanLev.txt
  }
}
 
on ^$*:notice:/^\s(?=[^+]{16}\+.{45}$)(\S+)\s+\+(\S+)|/:?: { 
  if ((!%ClearChanLev.channel) || ($nick !== Q) || ($network !== QuakeNet)) return 
  haltdef
 
  var %user = $regml(1)
  if ($regex($regml(2),/^([^nmbdq]+)$/)) {
    inc %ClearChanLev.total
    set %ClearChanLev.users $addtok(%ClearChanLev.users,$chr(35) $+ %user,32)
    if ($numtok(%ClearChanLev.users,32) == 18) {
      write ClearChanLev.txt REMOVEUSER %ClearChanLev.channel %ClearChanLev.users
      unset %ClearChanLev.users
    }
  }
 
  if ($1- == End of list.) {
    if ($numtok(%ClearChanLev.users,32)) {
      write ClearChanLev.txt REMOVEUSER %ClearChanLev.channel %ClearChanLev.users
      unset %ClearChanLev.users
    }
    var %time = $calc(2*$ceil($calc(%ClearChanLev.total / 18)))
    .timer 1 $calc(20+%time) ClearChanLev -END
    echo -cat info *** Clear-Chanlev: Removing %ClearChanLev.total users. Estimated time for clearup: %time seconds.
    .play Q clearchanlev.txt 2000
  }
}
 
Options: New, Download,
, mIRC Parser;
Copyright © 2006 by Zyberdog - Some rights reserved. (Browse/Disclaimer/Stats/About)