mIRC Home    About    Download    Register    News    Help

Print Thread
#15159 13/03/03 09:47 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
I have a popup that utilizes the /away command so that It changes my normal nickname to my away nickname like this:


Away
.On:/away stepped away from keyboard! | /nick The_Game[afk] | /timer1 0 1800 /ame is away from the keyboard! If you must speak with me leave me a Notice and I will get back to you!
.Off:/away | /nick The_Game | /timer1 off | /ame has returned!


Keep in mind that this is a popup, now what I would like to be able to do is when i'm away, if i want to receive a notice, I want It to show up in a custom window displaying the message and the person who posted it. I want a notice because I have disabled my private messages. Can anyone help me in this area?

Now when I return using the provided popup, My nick will change back and Nickserv will ask me to identify because my nick is registered and I think I have a pretty good idea by adding after the part when I return by adding this...can I assume I am doing this correctly?

| /msg NickServ Identify <pass> | /msg NickServ set kill on | /msg ChanServ Identify <channel> <pass>


Can anyone help me with this? Any help is greatly appreciated...Thanks in advance.


#15160 13/03/03 01:01 PM
Joined: Dec 2002
Posts: 143
A
Vogon poet
Offline
Vogon poet
A
Joined: Dec 2002
Posts: 143
I've altered the popup a bit, now you only have one option:

If you are away, you can set yourself back
If you are not away, you can set yourself away

I used groups so when you are set away and get a notice, it writes it to the window @AwayNotices

Hope it's along the lines of what you are looking for smile

(btw, it all goes in remotes, preferably in a file of it's own)

Code:
menu * {
  -
  Away System
  .$iif($away == $true,Off,On):{
    if ($away == $true) {
      .away | .nick The_Game | .timerAway off | .ame has returned! | .disable #AwayNotices
      if ($line(@AwayNotices,0) == 2) { echo $color(notify) -at You have no messages waiting }
      if ($line(@AwayNotices,0) &gt;= 2) { echo $color(notify) -at You have $calc($line(@AwayNotices,0) - 2) message(s) waiting }
    }
    if ($away == $false) {
      .away stepped away from keyboard! | .nick The_Game[afk]
      .timerAway 0 1800 ame is away from the keyboard! If you must speak with me leave me a Notice and I will get back to you!
      .window -k0n AwayNotices | .enable #AwayNotices
    }
  }
}

#AwayNotices off
on *:NOTICE:*:*:{
  if ($window(@AwayNotices) == $null) { .window -k0n AwayNotices }
  .aline -p @AwayNotices $timestamp &lt;&lt; $nick &gt;&gt; $1-
  .notice $nick Thanks for your message, I will respond on my return
}
on *:TEXT:*:?:{
  .msg $nick I am AFK. Please use /notice $me &lt;message&gt; if it is urgent and I will respond on my return
  if ($line($nick,0) == 1) { /close -m $nick }
}
#AwayNotices End


Aubs.
cool

#15161 14/03/03 12:10 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
Thanks but when I loaded it i got this error:

* /window: invalid parameters
* The_Game is now known as The_Game[afk]


and when i had someone message me and a notice it just returned that Im away and nothing more...no window popped up with the message that user sent.

any ideas?

Last edited by The_Game; 14/03/03 12:11 AM.
#15162 14/03/03 01:16 AM
Joined: Dec 2002
Posts: 332
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Dec 2002
Posts: 332
Code:
 
on ^1:notice:*:?: {
  if serv isin $nick goto end
  else /echo @pager Notice &lt; $+  $+ $time(mmm-dd-hh:nntt) $+ &gt; &lt; $+  $+ $nick $+ &gt; $1- 
  :end { 
}
}
 


i use a alias for the window like so
Code:
  
/f8 /window -an @Pager


then just add a /f8 to your away popup

#15163 14/03/03 01:25 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
So I replace your on notice event with the one aubs gave then? im a bit confuzzled...

#15164 14/03/03 01:28 AM
Joined: Dec 2002
Posts: 332
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Dec 2002
Posts: 332
thats the script i use for recieving notices while away ? i dont know if aubs works or not i didnt try it but you can load up mine and give it a shot and see if it works for you .
the reason for the

if serv isin $nick goto end is because i didnt want to catch nickserv/chanserv notices so i skip over them smile hope it helps

#15165 14/03/03 02:01 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
Well It works nice but i want is the message to pop up in a Custom window rather than a the status window...

#15166 14/03/03 02:17 AM
Joined: Dec 2002
Posts: 332
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Dec 2002
Posts: 332
ok if you go to your alias file and add to it
Code:
 
/f8 /window -an @Pager
 


you can change the name of the window to whatever you wish then add to your allready existing away popup the command /f8 that will open the window up

to stop the notice from appearing in more than one place you will need to add a /haltdef to the notice section
Code:
  
 on ^1:notice:*:?: { 
 if serv isin $nick goto end  
 else /echo @pager Notice &lt; $+  $+ $time(mmm-dd-hh:nntt) $+ &gt; &lt; $+  $+ $nick $+ &gt; $1- | haltdef  
 :end { 
}
} 

#15167 14/03/03 02:24 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
ahh i got it now... Thanks works great smile

#15168 14/03/03 02:28 AM
Joined: Dec 2002
Posts: 332
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Dec 2002
Posts: 332
i just realized tho it isnt away sensitive you can correct that with this
Code:
 
on ^1:notice:*:?: {
  if serv isin $nick goto end
  else {
    if ($away) /echo @pager Notice &lt; $+  $+ $time(mmm-dd-hh:nntt) $+ &gt; &lt; $+  $+ $nick $+ &gt; $1-  
  }
  :end { 
}
}
 


this way it will only catch the notices if you are away

#15169 14/03/03 02:32 AM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
Got it thanks again...works fine

#15170 15/03/03 01:03 AM
Joined: Dec 2002
Posts: 699
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
Quote:
* /window: invalid parameters

Just FYI the error is caused by not using @ in the /window commands.
Code:
      .window -kn [color:red]@[/color]AwayNotices | .enable #AwayNotices
and
  if ($window(@AwayNotices) == $null) { .window -kn [color:red]@[/color]AwayNotices }

#15171 15/03/03 09:04 PM
Joined: Dec 2002
Posts: 1,237
T
Hoopy frood
OP Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 1,237
Come to think about it when I look at that...Its kinda obvious...although I sometimes overlook the smaller details. I put that in and it works fine now. Thanks everyone for the help..


Link Copied to Clipboard