All pastes #982060 Raw Edit

Away script

public text v1 · immutable
·published 2008-04-12 07:26 UTC
rendered paste body
alias aaway {  if (%Away. [ $+ [ $Me ] ] != $null) { 
  echo 4 -t You're Already Set As Away. }
  else {
    set %Away. [ $+ [ $Me ] ] $$?="Reason For Being Away"
    set %AwayTime. [ $+ [ $Me ] ] $ctime
    set %AmIAway. [ $+ [ $Me ] ] Yes
    set %LeaveTime $time
    away  %Away. [ $+ [ $Me ] ]
  inc %awaynum 1
  nick squirl|afk
    amsg  I Am Now AWAY - ( %Away. [ $+ [ $Me ] ] ) - Left At: ( %LeaveTime EST ) - I have been AWAY ( %awaynum ) times.
}
}

alias bback { if (%Away. [ $+ [ $Me ] ] == $null) {
  echo 4 -t You're Not Set As Away! You Must Do That First! }
  else {
    away 
nick squirl100
    amsg I Am Now BACK From ( %Away. [ $+ [ $Me ] ] ) - I Was Away For ( $duration($calc($ctime - %AwayTime. [ $+ [ $Me ] ] $ctime )) ) 
    unset %Away. [ $+ [ $Me ] ]
    unset %AwayTime. [ $+ [ $Me ] ]
    unset %LeaveTime
    set %AmIAway.[ $+ [ $Me ] ] No

  }
}