Away Script

By xdesoto on Dec 07, 2010

Okay, just an updated version of my previous away...
make sure you set the variable %p password here
and change your nick to what you want
type /a then put your away reason then when you're back type /b

on 1:input:*:{
  IF ($1 == /a ) {
    set %away.reason $$1
    if %away.reason == $null { set %away.reason %default }
    nick PUT AWAY NAME HERE
    amsg Away: %away.reason 
    away %away.reason
    halt
  }
  ELSEIF ($1 == /b ) {
    nick PUT ACTIVE NAME HERE
    pass PUT PASS HERE
    amsg Back: %away.reason /Time: $Duration($awaytime) 
    away
    halt
  }
  else {
    return
  }
}

Comments

Sign in to comment.
xdesoto   -  Dec 10, 2010

oO file taxes I may need that ;/

 Respond  
IllogicTC   -  Dec 10, 2010

True true. Hey at the least, you could say it's nice and short, just do the job and get it done! I'm pretty sure you can find someone with a thousand-line away superscript. Whether it's because it's fluffed with comments or useless crap, or can even file your taxes for you, it's probably there.

 Respond  
xdesoto   -  Dec 08, 2010

Thanks Jethro_ and IllogicTC I'll check it out see if I like it better or not It's the current away script I use it's up to anyone else if they want to use it and change it

 Respond  
IllogicTC   -  Dec 08, 2010

I would like to mention the same thing from a performance standpoint. If your mIRC is looking to see if you said /a EVERY TIME you every type ANYTHING, some people who utilize this snippet MAY notice a slight loss in responsiveness whenever they are doing their thing on mIRC. And you already use a variable set "%away." so if you want to unset them all in one fell swoop, just /unset %away.* to remove all variables involved in the snippet at once, when they return from being away.

 Respond  
Jethro   -  Dec 08, 2010

To me, I don't see the point to enter the command onto the active window and initiate a trigger. An alias can do the same thing. You should add an extra dollar sign to this:$$?="What Reason" so when the variable value isn't filled, you won't just get this: :|:Away:

Again, your else return serves no purpose.

 Respond  
xdesoto   -  Dec 08, 2010

Jethro_: what would be the difference in an alias and input (i know the difference) but Why would an alias be better...
Ryan: thanks I changed that in my script..
Tidum: It's my script, I don't care for too many variables.. and my away nick is always [away]

 Respond  
Jethro   -  Dec 07, 2010

Use an alias for this...I wouldn't bother with an input if I were you. But then again, it's your snippet...:P

Also, kick the bad habit of using "else halt" or "else return."

 Respond  
Tidum   -  Dec 07, 2010

Rather than:

nick PUT ACTIVE NAME HERE

Why not do an "on LOAD" event to set the var for it.
Like:

on *:LOAD:{ set %anick $$?"Enter away nick." }

Then that line could be:

nick %anick

 Respond  
blackvenomm666   -  Dec 07, 2010

just wonderin why bother with the popup window for it? the $$?= you could just use the $2 identifier just a suggestion:D

 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.