mIRC Home    About    Download    Register    News    Help

Print Thread
#186699 25/09/07 01:03 AM
Joined: Jun 2003
Posts: 17
S
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2003
Posts: 17
OK, I'm not entirely sure how to put this, but I'm looking for a way to effectively nest a couple fo aliases. Basically I've got a script, which works by opening various different Aliases, with actions including sockopens and restyling the data. The only way I've known how to do it is by having aliases called within each one. The problem is I need to call /msg or /describe from outwith this, but because of the socks it takes time before it works.
I need some way to call an alias, but then not call the next until the first has completed.

Can anyone tell me if theres any way to do this?


Swift as the Wind
Silent as a Forest
Fierce as Fire
Immovable as a Mountain
Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Originally Posted By: Stefan_Leroux
OK, I'm not entirely sure how to put this, but I'm looking for a way to effectively nest a couple fo aliases. Basically I've got a script, which works by opening various different Aliases, with actions including sockopens and restyling the data. The only way I've known how to do it is by having aliases called within each one. The problem is I need to call /msg or /describe from outwith this, but because of the socks it takes time before it works.
I need some way to call an alias, but then not call the next until the first has completed.

Can anyone tell me if theres any way to do this?


The way I would approach this is add a timer to the next event of x amount of seconds like this

alias myscript {
/blah
/blah
./timer 1 2 /newblah
./timer 1 3 /blah
}

etc..

by calling the next timer 1 time for 2 seconds it should allow enough time then the next timer should follow by an extra second.


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
If you need to wait until the socket is done, why not just call the next alias from the sockclose event?


Invision Support
#Invision on irc.irchighway.net
Riamus2 #186704 25/09/07 03:32 AM
Joined: Jun 2003
Posts: 17
S
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2003
Posts: 17
Well, the best way would be for me to use the timer, but when it gets called it keeps saying in active that it has begun, and ended. It would be the ideal solution if I could stop the started/stopped messages appearing.

I cant call the final alias from the sockclose, because the final alias is not a definite one. I want it to vary between /msg /me /ctcp depending on the command sent, and because of the huge amount of lines in the script, I dont really want to duplicate it just for such subtle differences


Swift as the Wind
Silent as a Forest
Fierce as Fire
Immovable as a Mountain
Joined: Jul 2006
Posts: 107
L
Vogon poet
Offline
Vogon poet
L
Joined: Jul 2006
Posts: 107
You can silence those timer messages by using the "." in front of it.

Code:
 .timerquiet 1 1 echo -s I'm a well-behaved timer!


LonDart
LonDart #186706 25/09/07 03:52 AM
Joined: Jun 2003
Posts: 17
S
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2003
Posts: 17
that will do absolutely perfectly then, thanks mate

- Apparently thats the only thing in this script that I havent used a '.' for. I learned it years ago, and never used a '/' since, although never realised it had a special function until recently

Last edited by Stefan_Leroux; 25/09/07 03:55 AM.

Swift as the Wind
Silent as a Forest
Fierce as Fire
Immovable as a Mountain
Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Originally Posted By: Stefan_Leroux
that will do absolutely perfectly then, thanks mate

- Apparently thats the only thing in this script that I havent used a '.' for. I learned it years ago, and never used a '/' since, although never realised it had a special function until recently


Steph, if you notice in my original post I added a . in back of the timer already, you shouldnt of received any messages


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Lpfix5 #186727 25/09/07 03:39 PM
Joined: Jun 2003
Posts: 17
S
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2003
Posts: 17
Sorry Lpfix5, I never actually noticed that, and because I already had it working via a timer, I didnt copy your code down, so it was my issue. Thanks though, I'll pay much more attention next time


Swift as the Wind
Silent as a Forest
Fierce as Fire
Immovable as a Mountain

Link Copied to Clipboard