away.system {
if (!$1-) echo.grey You need to set an away reason
else {
set %away.system on
set %_away 1
set %_away.reason $1-
set %_away.oldnick $me
set %_away.time $ctime
$iif(%away.multi == on,scon -at1) away %_away.reason
if (%away.nick.change == on) $iif(%away.multi == on,scon -atl) away.system.nick
if (%away.public == on) $iif(%away.multi == on,scon -atl) ame $+(is away: %_away.reason)
if %away.public == on { echo.grey You have been marked as being away, press F3 to get back! }
else {
echo.grey You have been marked as being away: %_away.reason $+ , press F3 to get back!
if %away.nick == $null { echo.grey Note: Awaynick is not set, using $me $+ \aw as norm }
}
titlebar - The Reactor Script - Away: %_away.reason
}
}
away.system.nick {
if %away.nick == $null { tnick $me $+ \aw }
else { tnick %away.nick }
}
away.system.away {
if %away.system == on { echo.grey You are already away: %_away.reason $+ , press F3 to get back! }
else { away.system $$?="Away System:" }
}
away.system.update.away {
if %away.system == off { echo.grey You are not away! }
else {
set %_away.reason $$?="Update Away Message:"
scon -at1 away $!
titlebar - The Reactor Script - Away: %_away.reason
echo.grey Udated away to: %_away.reason $+ , press F3 to get back!
}
}
away.system.back {
if (!%_away) echo.grey You are not away!
else {
if (%away.nick.change == on) $iif(%away.multi == on,scon -at1) nick %_away.oldnick
if (%away.public == on) $iif(%away.multi == on,scon -at1) ame $+(is back from: %_away.reason (awaytime: $duration($calc($ctime - %_away.time),2),)) $+ )
$iif(%away.multi == on,scon -at1) away
if %away.public == on { echo.grey Away turned off }
else { echo.grey Away turned off, back from: %_away.reason (awaytime: $duration($calc($ctime - %_away.time),2) $+ ) }
titlebar - The Reactor Script
set %away.system off
unset %_away*
}
}