This is a very simple away script. Even the coding isn't hard. Mainly for people who wish to learn more about scripting. However, YOU MUST HAVE TAD'S HOME INTEGRATION SCRIPT IN ORDER FOR THIS TO WORK: http://www.hawkee.com/snippet/4936/
To install, type /install away and follow the on-screen prompts.
To start-up, press F6 or type /imaway to start it up.
While you don't have to set an away or return message you can do so by clicking on settings.
Do not use while taking a shower.
dialog away {
title Away Script
option dbu
size -1 -1 101 33
button "Away", 1, 1 1 100 10
button "Return", 2, 1 11 100 10, disable
button "Settings", 3, 1 22 100 10
menu "Help", 4
item "Help", 5, 4
}
dialog away_settings {
title Away Settings
option dbu
size -1 -1 101 55
button "Set Away Message", 1, 1 1 100 10
button "Set Return Message", 2, 1 11 100 10
check "Return on Activity", 3, 1 22 100 10
check "AMSG on event", 4, 1 33 100 10
button "Back", 7, 1 44 100 10
menu "Help", 5
item "Help", 6, 5
}
on *:DIALOG:away:init:0: {
If ($im_away == on ) {
did -b away 1
did -e away 2
}
}
on *:DIALOG:away:sclick:1: {
If ($im_away == on ) {
echo -a You're already away!
did -b away 1
did -e away 2
}
Else {
If ($away_message == $null) {
away I am away from my computer right now.
}
Else {
away $away_message
}
If ($amsg_on_event == on ) {
If ($away_message != $null) {
amsg I am away, Reason: $away_message
}
Else {
amsg I am away, Reason: I am away from my computer right now.
}
}
did -b away 1
did -e away 2
writeini away.ini status away on
echo -a You are now marked as away.
}
}
on *:DIALOG:away:sclick:2: {
If ($im_away == on ) {
away
If ($amsg_on_event == on ) {
If ($return_message == $null) {
amsg I have returned from away.
}
Else {
amsg $return_message
}
}
writeini away.ini status away off
echo -a You are no longer marked as being away.
did -e away 1
did -b away 2
}
Else {
echo -a You're not marked as away!
did -e away 1
did -b away 2
}
}
on *:DIALOG:away:sclick:3: {
close away
start away_settings
}
on *:DIALOG:away:menu:5: {
echo -a For help, please open your Help Connection Center or type /server -m irc.authoritygamer.com -j #helpdesk
}
on *:DIALOG:away_settings:init:0: {
If ($return_on_activity == on) {
did -c away_settings 3
}
If ($amsg_on_event == on ) {
did -c away_settings 4
}
}
on *:DIALOG:away_settings:sclick:1: {
dialog -i away_settings
writeini away.ini settings away_message $?="Please enter your away message."
dialog -e away_settings
echo -a Your away message has been changed to: $away_message $+ .
}
on *:DIALOG:away_settings:sclick:2: {
dialog -i away_settings
writeini away.ini settings return_message $?="Please enter your return message."
dialog -e away_settings
echo -a Your return message has been changed to: $return_message $+ .
}
on *:DIALOG:away_settings:sclick:3: {
If ($return_on_activity == on) {
writeini away.ini settings return_on_activity off
}
Else {
writeini away.ini settings return_on_activity on
}
}
on *:DIALOG:away_settings:sclick:4: {
If ($amsg_on_event == on ) {
writeini away.ini settings amsg_on_event off
}
Else {
writeini away.ini settings amsg_on_event on
}
}
on *:DIALOG:away_settings:menu:6: {
echo -a For help, please open your Help Connection Center or type /server -m irc.authoritygamer.com -j #helpdesk
}
on *:DIALOG:away_settings:sclick:7: {
close away_settings
start away
}
alias im_away {
return $readini(away.ini,status,away)
}
alias away_message {
return $readini(away.ini,settings,away_message)
}
alias return_message {
return $readini(away.ini,settings,return_message)
}
alias return_on_activity {
return $readini(away.ini,settings,return_on_activity)
}
alias amsg_on_event {
return $readini(away.ini,settings,amsg_on_event)
}
on *:LOAD: {
createlicense away
}
alias away_install {
writeini away.ini status away off
writeini away.ini status installed yes
echo -a Away program install successfully, press F6 or type /imaway to start the away Program.
}
alias away_uninstall {
remove away.ini
echo -a Away program uninstall successfully, type /install away to reinstall the Away program.
}
on *:START: {
If ($readini(away.ini,status,installed) == yes ) {
If ($readini(away.ini,settings,auto_start) == yes ) {
check away
}
Else {
echo -a Press F6 or type /imaway to start the Away Program
}
}
Else {
echo -a Type /install away to install the Away Program
}
}
on *:INPUT:*: {
If ($im_away == on) {
If ($return_on_activity == on ) {
away
writeini away.ini status away off
If ($amsg_on_event == on ) {
If ($return_message == $null ) {
amsg I have returned to my computer.
}
Else {
amsg $return_message
}
}
}
}
}
alias f6 {
check away
}
alias imaway {
check away
}
You said
"However, YOU MUST HAVE TAD'S HOME INTEGRATION SCRIPT IN ORDER FOR THIS TO WORK: http://www.hawkee.com/snippet/4936/"
Update that script with this so as not to waste people's time with needing to get two scripts just to make one work.