Xpert Away {~Best~} v 2.0 ReVaMpEd

By EliteT0kr on Jul 13, 2004

menu recommended, or u cna use the /imaway and /back.

USE MENU

on *:load: { beep 5 | echo -a 2You are now using Expert Away By EliteT0kr.  5Usage: Pop-Up Menu Recommended, or you can use /imaway <reason>, and /back | set %AwayMode $true 
}
on *:unload: { beep 5 | unset %AwayMode | unset %Status | unset %awnick | unset% awticks | unset %AwayDef | unset %AwayDef2 | unset %AwayNick | unset %AwayNick2 | echo -a 2EliteT0kr's Away Script successfully unloaded. 
}
menu * {
  -
  -ExpertAway-
  .Main
  ..Away:imaway $?"Why are you away?"
  ..Back:back
  .Customize
  ..Away Default
  ...Set Away Default:awaydef $?"What do you want your Away Default to be?" | unset %AwayMode
  ...Turn off Away Default:unset.AwayDef | set %AwayMode $true
  ..Custom Away Nick
  ...Set Away Nick:set.awaynick $?="What Do you Want Your Away Nick To Be?"  
  ...Turn Off Away Nick: unset.AwayNick
  ..Auto Away
  ...Set Auto Away:set.autoaway $?"Enter how much idle time (in minutes) you want it to be until you are set to away."  
  ...Turn Off Auto Away:.disable #AutoAway | echo -a Auto Away disabled!
  .About
  ..Script: echo -a 2Made by EliteT0kr, compiled on June 23, 2004 on 3:03 PM (Est) . Took 10 minutes to compile code.
  ..Learn To Script!:help
  ..Home Page:url -n www.hawkee.com
}
alias set.autoaway { 
  if ($1) {
    set %AutoAway $calc($1 * 60) | .timerautoaway $+ $server off | autoaway | echo -a 5Auto Away Timer set : $1 minute(s)
  } 
  else {
    echo -a 5Please specify a timer!
  }
}
alias set.awaynick {
  if ($1) {
    set %AwayNick $1 | echo -a 5Custom Away Nick added! : %AwayNick | set %AwayNick2 $true
  }
  else {
    echo -a 5Please specify a name!
  }
}
alias unset.Awaydef { 
  unset %AwayDef | unset %AwayDef2 | set %AwayMode $true | echo -a 5Away default removed.
}
alias unset.awaynick {
  unset %AwayNick | unset %AwayNick2 | echo -a 5Custom Away Nick Turned Off.
}
alias awaydef {
  if ($1-) {
    set %AwayDef $1- | set %AwayDef2 $true | echo -a 5Away default added : %AwayDef 
  }
  else {
    echo -a 5Please specify your Away Default!
  }
}
alias imaway {
  if (%AwayMode == $true) && (%AwayNick2 == $true) && ($1-) {
    set %reason $1-
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) is away 2-((1||2))- 5 $+ %Reason 2-((1||2))-  1.:[ $+ $time $+ ]:. 14To see my status type 1!Status. | inc %Chan }
    set %AwayMode3 $true
    .enable #Status
    .enable #Away_Logger
    .enable #Away 
    set %status Away.
    set %awticks $ticks
    set %awnick $me
    nick %AwayNick 
  } 
  elseif (%AwayDef2 == $true) && (%AwayNick2 == $true) {
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) describe $chan is away describe # is away 2-((1||2))- 5 $+ %AwayDef 2-((1||2))-  1.:[ $+ $time $+ ]:. 14To see my status type 1!Status. | inc %Chan }
    .enable #Status
    set %AwayMode3 $true
    .enable #Away_Logger    
    .enable #Away
    set %awnick $me
    set %awticks $ticks
    set %status Away.
    nick %AwayNick
  }
  elseif (%AwayMode == $true) && ($1-) {
    set %reason $1-
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) describe $chan is away 2-((1||2))- 5 $+ %Reason 2-((1||2))-  1.:[ $+ $time $+ ]:. 14To see my status type 1!Status. | inc %Chan }
    .enable #Status
    set %AwayMode3 $true
    .enable #Away_Logger
    .enable #Away 
    set %status Away.
    set %awticks $ticks
    set %awnick $me
    nick $me $+ -Away
  }
  else {
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) is away 2-((1||2))- 5Not Here. 2-((1||2))-  1.:[ $+ $time $+ ]:. 14To see my status type 1!Status. | inc %Chan }
    .enable #Status
    set %AwayMode3 $true
    .enable #Away_Logger
    .enable #Away
    set %status Away.
    set %awticks $ticks
    set %awnick $me
    nick $me $+ -Away
  } 
  elseif (%AwayDef2 == $true) {
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) is away 2-((1||2))- 5 $+ %AwayDef 2-((1||2))-  1.:[ $+ $time $+ ]:. 14To see my status type 1!Status. | inc %Chan }
    .enable #Status
    set %AwayMode3 $true
    .enable #Away_Logger
    .enable #Away 
    set %status Away.
    set %awticks $ticks
    set %awnick $me
    nick $me $+ -Away
  }
  else {
    echo -a Invalid Parameters.
  }
  else {
    echo -a Unknown Error.
  }
}
alias -l AutoAway {
  .timerautoaway $+ $server 1 %AutoAway imaway Idle. [Auto-Away- $+ $calc(%AutoAway / 60) minute(s)] | .enable #AutoAway
}
alias back {
  if (%AwayMode3 == $true) { 
    .disable #Away_Logger
    set %AwayMode3 $false
    set %status Here.
    .disable #away
    nick %awnick
    var %Chan 1 | while (%Chan <= $chan(0)) {
    .timer 1 0 describe $chan(%Chan) is back as of1 .:[ $+ $time $+ ]:. 2I have been gone for1 $duration($calc(($ticks - %awticks) / 1000)) $+ . | inc %Chan }
    unset %awticks
  }
  else {
    echo -a You are not away!
  }
  else {
    echo -a Invalid Parameters.
  }
}
#Away on
on *:input:#: { if ($me != %awnick) { back }
}
#Away end

#Away_Logger on
on 1:open:?:*: { msg $nick [Automated Message]: Your message is recieved. | echo -a $1- }
#Away_Logger end

#Status on
on *:text:*!Status:#: { if (%Status == Away.) { describe # is 2Away $+ , 5I have been gone for1 $duration($calc(($ticks - %awticks) / 1000)) $+ . }
  elseif (%Status == Here.) {
    describe # is Here. 
  }
}
#Status End

#AutoAway on
on *:connect: { autoaway }
on *:input:#: { if (%Status == Away.) { .timerautoaway $+ $server off | back | autoaway }
  else {
    .timerautoaway $+ $server off | autoaway
  }
}
#AutoAway end
}

Comments

Sign in to comment.
`Kazuma   -  Jan 31, 2006

... never worked for me.

 Respond  
vampslim   -  Jan 31, 2006

Useless.

 Respond  
DeathRyder082   -  Jul 08, 2005

Nice Job T0kr!

 Respond  
DarthReven   -  Dec 23, 2004

this script is rather useless /away works just fine

 Respond  
Yoinx   -  Dec 22, 2004

extra bracket.

 Respond  
PoiXon   -  Aug 30, 2004

Nice snippet , works fine for me ! :)

 Respond  
PoiXon   -  Aug 30, 2004

Nice snippet , works fine for me ! :)

 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.