Idle Checker.

By Protheus on Mar 21, 2017

Intended for a bot. When a nick is typed in the channel, the bot will /whois the nick, getting it's idle time. It will then output the message "NICK has been away for DURATION, try messaging them instead."

Screenshot:

Image 1
on 1:TEXT:*:#: {
  if ($remove($1,$chr(58)) ison $chan) { set -u3 %whois.chan $chan | whoischeck $nick $remove($1,$chr(58)) }
  if ($remove($1,$chr(58)) !ison $chan) { halt }
}
alias whoischeck {
  if ([ % $+ [ $1 $+ [ .whois.ignore ] ] ] == on) { halt }
  set -u3 % $+ $remove($2,$chr(58)) $+ .whois on
  .whois $2 $2
  set -u15 % $+ $nick $+ .whois.ignore on
}
raw 317:*: {
  if ([ % $+ [ $2 $+ [ .whois ] ] ] == on) {
    if ($3 > 1799) { msg %whois.chan 3 $2 14has been away for 3{14- $duration($3) 14-3} $+ 14, try messaging them instead. }
  }
}

Comments

Sign in to comment.
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.