mIRC Home    About    Download    Register    News    Help

Print Thread
#213843 10/07/09 02:28 AM
Joined: Apr 2009
Posts: 8
A
athlom Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Apr 2009
Posts: 8
I need the variable to show how long i've been idle on IRC.
The message would look like this:

on *:OPEN:?:*: {
msg $nick 8,1[ 4 Hello, $nick ]
msg $nick 8,1[ 4 I currently have 8 1 4$query(0) querie(s) on my reply list. 8 ]
msg $nick 8,1[ 4 Please be patient, I may be busy at the moment. 8 ]
msg $nick 8,1[ 4 If I have been idle for 8MORE4 than a half hour please leave a detailed message. 8 ]
msg $nick 8,1[ 4 Idle Time: (8 1hr 20mins 39secs 4) 8 ]
msg $nick 8,1[ 4 If it's 8IMPORTANT4, you can either 8Xfire4 me (8athlom4), or 8Steam4 me (8athl0m4). ]
}

Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
try replacing
Code:
(8 1hr 20mins 39secs 4) 8 ]
with
Code:
(8 $idle 4) 8 ]

Joined: Apr 2009
Posts: 8
A
athlom Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Apr 2009
Posts: 8
I've tried that, all i get is a line like this;

Code:
8,1[ 4Idle Time8: (4 3721 8) ]


Also, if at all possible I would like to have a script that not only when someone queries me about something i auto reply but it send them a list of key words, exp. tryout, ring, ecl and since they've already opened up the chat, that when they enter in those key words, i reply with a different set of messages. Sort of like this:

Code:
  msg $nick 8,1[ 4Hello8,4 $nick 8]
  msg $nick 8,1[ 4I currently have8 $query(0) 4querie8(4s8) 4on my reply list8. ]
  msg $nick 8,1[ 4Please be patient8, 4I may be busy at the moment8. ]
  msg $nick 8,1[ 4If you're messaging me about some specific please enter one of the following keywords8. ]
  msg $nick 8,1[ 4Keywords8: tryout4, 8ring4, 8ecl. ]
  msg $nick 8,1[ 4If I have been idle for 8MORE4 than a half hour please leave a detailed message8. ]
  msg $nick 8,1[ 4Idle Time8: (4 $idle 8) ]
  msg $nick 8,1[ 4If it8'4s 8IMPORTANT, 4you can either 8Xfire4 me 8(athlom), 4or 8Steam4 me 8(athl0m). ]

& The convorsation would look something like this:

Quote:
[03:19] <[47HL0M`]> hey
[03:19] <ecL`[GM]athlom> [ Hello, [47HL0M`] ]
[03:19] <ecL`[GM]athlom> [ I currently have 2 querie(s) on my reply list. ]
[03:19] <ecL`[GM]athlom> [ Please be patient, I may be busy at the moment. ]
[03:19] <ecL`[GM]athlom> [ If you're messaging me about some specific please enter one of the following keywords. ]
[03:19] <ecL`[GM]athlom> [ Keywords: tryout, ring, ecl. ]
[03:19] <ecL`[GM]athlom> [ If I have been idle for MORE than a half hour please leave a detailed message. ]
[03:19] <ecL`[GM]athlom> [ Idle Time: ( 82 ) ]
[03:19] <ecL`[GM]athlom> [ If it's IMPORTANT, you can either Xfire me (athlom), or Steam me (athl0m). ]
[03:20] <[47HL0M`]> tryout
[03:20] <ecL`[GM]athlom> [ I am currently looking to join a top CEVO/XPL/TGL CoD4 team. ]
[03:20] <ecL`[GM]athlom> [ Age: 17. ]
[03:20] <ecL`[GM]athlom> [ Weapon: SMG/MG. ]
[03:20] <ecL`[GM]athlom> [ EXP: TGL, CAL-M, CEVO-A. ]
[03:20] <ecL`[GM]athlom> [ Gamertag(s): athlom, 47HL0M`, piNkeRtoN`. ]
[03:20] <ecL`[GM]athlom> [ Past Teams: Team Inexorable (iNeX), pHaZed, RAGE/rGaming, OG (Original Gamers). ]
[03:20] <ecL`[GM]athlom> [ CEVO Paid: Not at the moment, but I can pay for my own CEVO on the spot if I need to. ]
[03:20] <ecL`[GM]athlom> [ Xfire: athlom / Please Xfire me if you need anything else, or more information regarding my eligibility. ]


I'm not very good with codes so if someone could help me out, I'd really appreciate it.

Last edited by athlom; 10/07/09 07:41 AM.
Joined: Jun 2007
Posts: 933
5
Hoopy frood
Offline
Hoopy frood
5
Joined: Jun 2007
Posts: 933
The idle time is a value in seconds. Use $duration($idle) for a format in minutes, hours, etc.

As for your other script, you can simply use:
Code:
on *:TEXT:tryout:?:{
  your message commands
}

And add new on TEXT events for the other trigger words.

Joined: Apr 2009
Posts: 8
A
athlom Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Apr 2009
Posts: 8
Thanks, one thing I did run into though, is that if somebody opens a query with me with any of the keywords I get kicked for flooding and reconnect because it tries to send the auto reply as well as the tryout one at the same time.. Is there any way to make it that on open if the word tryout is detected, it ignores the initial auto reply and sends the tryout one?

Last edited by athlom; 10/07/09 06:20 PM.
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Just replace the * at the end of the ON OPEN event with the word or phrase that you want to match.


Link Copied to Clipboard