rendered paste bodyif ($alevel(#ayb.priv,$nick) >= 350){
if ($1 == timer) {
if ($2 == add) {
join $4
timer $+ $3 0 $5 msg $4 $6-
notice $nick Timer $+ $3 added.
}
if ($2 == del) {
timer $+ $3 off
notice $nick Timer $+ $3 removed.
}
if ($2 == list) {
if ($timer(0) > 0) {
var %x = 1
while (%x <= $timer(0)) {
notice $nick Timer %x $+ : Name: $timer(%x) $+ . Delay in seconds: $timer(%x).DELAY $+ . Command: $timer(%x).COM
inc %x
}
}
else {
notice $nick No current timers are active.
}
}
}
}
alias alevel {
hadd -mu3 acheck chan $1
hadd -mu3 acheck nick $2
;Increase the pause number slightly if mirc isnt catching the access level in time.
cs a $1 $2 | pause ms 700
var %access $hget($+(aresult.,$2),access) | .hfree -sw $+(aresult.,$2) | return %access
}
alias pause {
;Credit for /pause goes to FiberOPtics
if ($version < 5.91) halt
elseif (!$regex(pause,$1-,/^m?s \d+$/Si)) halt
elseif ($1 == ms) && ($istok(95 98 ME,$os,32)) halt
elseif ($2 !isnum 1-) halt
var %wsh = wsh $+ $ticks, %cmd
if ($1 == s) %cmd = ping.exe -n $int($calc($2 + 1)) 127.0.0.1
else %cmd = pathping.exe -n -w 1 -q 1 -h 1 -p $iif($2 > 40,$calc($2 - 40),$2) 127.0.0.1
.comopen %wsh wscript.shell | .comclose %wsh $com(%wsh,run,1,bstr*,% $+ comspec% /c %cmd >nul,uint,0,bool,true)
}
on *^:notice:*:?:{
if ($nick != ChanServ) halt
var %acheck-chan $hget(acheck,chan), %acheck-nick $hget(acheck,nick)
if %acheck-nick {
if $regex($1-,^.* has access (.*) in .*$) && $nick == ChanServ {
.hfree -sw acheck
if (!%acheck-nick) halt
hadd -mu3 $+(aresult.,%acheck-nick) access $strip($regml(1))
hadd -mu1 acheck-halt notice 1 | .timeracheck-unhalt 1 1 .hfree -sw acheck-halt
halt
}
elseif $regex($1-,^.* lacks access to .*$) { .hfree -sw acheck | halt }
elseif $regex($1-,^Account .* has not been registered.$) { .hfree -sw acheck | halt }
elseif User with nick * does not exist. iswm $1- { .hfree -sw acheck | halt }
}
elseif ($regex($1-,^[.*] .*)) && ($hget(acheck-halt,notice)) halt
}