Yoinx commented on a Page, away system 4.0  -  Nov 12, 2006

personally.. I\'d do it like:

on *:input:#: {
if ($1 == !away) {
tnick $+($me,$chr(124),Away)
describe $chan I am currently away.
}
elseif ($1 == !back) {
tnick $mnick
describe $chan I\'m back.
}
elseif ($1 == !afk) {
tnick $chan $+($me,$chr(124),AFK)
describe I\'m currently AFK at the moment.
}
}

if you wanted to use it this way.

Reasons:

  1. Using tnick instead of nick allows you to reference $mnick to get back to the default nick, whereas nick replaces $mnick. Also, using nick you would still have that nick if you were to disconnect and reconnect etc.
  2. Describe $chan is the proper way to do actions to a channel from a script.
  3. You dont have all the on inputs that you had as, I believe only the first one ever should have worked.
  4. You dont have the bracket mismatches.
 Respond  
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.