mIRC Home    About    Download    Register    News    Help

Print Thread
How do I make a time delay? #211601 25/04/09 12:39 AM
Joined: Apr 2009
Posts: 4
A
allcaps Offline OP
Self-satisified door
OP Offline
Self-satisified door
A
Joined: Apr 2009
Posts: 4
Here is my current script:
on *:ACTION:*slaps [fku]allcaps around a bit with a large trout:*: {
/describe $chan makes $nick apologize for his uncalled for acts. Shame on you $nick $+
}

Everything is working fine with it but I would like to know how to put a timer delay so when someone spam slaps me it wont go off for another 30 seconds. Can anyone help me please?

Re: How do I make a time delay? [Re: allcaps] #211602 25/04/09 01:10 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Use the /timer command in front of your /describe line

See /help /timer

Re: How do I make a time delay? [Re: RusselB] #211604 25/04/09 02:42 AM
Joined: Apr 2009
Posts: 4
A
allcaps Offline OP
Self-satisified door
OP Offline
Self-satisified door
A
Joined: Apr 2009
Posts: 4
So like this?
on *:ACTION:*slaps [fku]allcaps around a bit with a large trout:*: {
/timer 0 20 /describe $chan makes $nick apologize for his uncalled for acts. Shame on you $nick $+
}
Because I did that and it wouldnt stop. Can someone please script it for me?

Re: How do I make a time delay? [Re: allcaps] #211606 25/04/09 02:52 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
You have the right idea, but using the 0 where you have it tells mIRC to run the timer indefinetely. Change the 0 to a 1 for a single post 20 seconds after the action is matched.

Re: How do I make a time delay? [Re: RusselB] #211608 25/04/09 02:59 AM
Joined: Apr 2009
Posts: 4
A
allcaps Offline OP
Self-satisified door
OP Offline
Self-satisified door
A
Joined: Apr 2009
Posts: 4
Originally Posted By: RusselB
You have the right idea, but using the 0 where you have it tells mIRC to run the timer indefinetely. Change the 0 to a 1 for a single post 20 seconds after the action is matched.

How do I get the script to appear after someone trout slaps me but if they do it a second time the script doesnt appear for 20 or so seconds even if they slap me?

Last edited by allcaps; 25/04/09 03:07 AM.
Re: How do I make a time delay? [Re: allcaps] #211610 25/04/09 04:12 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
the code you have, with the alteration I specified, will wait for 20 seconds after someone slaps you with that specific slap, then post the message. If you want to have no delay the first time, then you're going to have to use a variable to track the number of times a person slaps you.