Timed Ban
Platform: mIRC
Published Sep 06, 2011
Updated Sep 06, 2011
Well, this was just a little timed ban alias I made. I tried using else's, that didn't work out so well. So I feel amazed I got this alias using only if's. Oh, and just to point this out, I wouldn't add if ($me isop $chan), because, well, you wouldn't be using the alias if you weren't an op, would you? :P
I had to snoop around here a bit to figure out how /ban worked, Since *previously* I had just done /.timers to undo it. Now here is my many times improved, timed ban alias. (It's also always good to have a few channels to test it in. :P I had failed on the $duration, always good to have a channel to test and fix it, lol.)
; Usage: /tb <nick> <minutes> <reason> (Not required)
alias tb {
if ($1) && ($1 ison $chan) && ($2 isnum) { ban $+(-ku,$calc($2 * 60)) $1 2 Banned for $+($duration($calc($2 * 60)),:) $iif($3-,$3-,No $&
reason specified.) }
if ($1 ison $chan) && ($2) && ($2 !isnum) { echo -a You have to specify a number, /tb <nick> <minutes> <reason> (Not required) }
if ($1) && ($1 ison $chan) && (!$2) { echo -a Specify a number, and if you want to, a reason, /tb <nick> <minutes> <reason> $&
(Not required) }
if ($1) && ($1 !ison $chan) { echo -a $1 isn't on $chan $+ , therefore, you can't ban them. }
if (!$1) { echo -a Forgetting a nickname? /tb <nick> <minutes> <reason> (Not required) }
}