Hi,
your were misusing the braces {}
Now, while I know of better ways to create an away script, i tried to edit your script the least as possible, so that you can experiment yourself in making it better:
alias PMon {
%awy.stat = on
echo -a Away Skript 0n | say Away Script On
if ($1) { set %awy $1 }
set %reason $$?="Reason?"
}
[color:red] [/color]
alias PMoff { %awy.stat = off | echo -a Away Skript Off | say Away Script Off }
[color:red] [/color]
on ^*:open:?:{
if !$notify($nick) { halt }
if (%awy.stat == on) { .msg $nick Sorry I'm Currently Away Right Now %reason $+ , Please Leave A Message and I'll Get Back To You As Soon As I Can }
}
I'm curious though why you are doing set %awy $1, since you're not using that variable %awy anywhere else.
Btw I changed the order of
if !$notify($nick) { halt } and where it says that you are away. Because people who are not on your notify list, cannot leave a message, so then you might as well simply already halt the script there, before telling them that you are away.
Greetz