mIRC Home    About    Download    Register    News    Help

Print Thread
multiple on TEXT actions #137035 07/12/05 02:30 AM
Joined: Sep 2003
Posts: 19
F
fast68 Offline OP
Pikka bird
OP Offline
Pikka bird
F
Joined: Sep 2003
Posts: 19
how to you combine multiple on text actions in one line

i forgot how to do it,

but i know that each one is separated by a | and { }'s around them




thanks

Last edited by fast68; 07/12/05 02:57 AM.


Re: multiple on TEXT actions #137036 07/12/05 02:57 AM
Joined: Aug 2005
Posts: 525
S
schaefer31 Offline
Fjord artisan
Offline
Fjord artisan
S
Joined: Aug 2005
Posts: 525
Code:
on 1:TEXT:!trigger1:#Channel:{
  [color:red];Do some commands when !trigger1[/color]
}

on 1:TEXT:!trigger2:#Channel:{
    [color:red];Do some commands when !trigger2[/color]
}

on 1:TEXT:!trigger3:#Channel:{
    [color:red];Do some commands when !trigger3[/color]
}


And so on...

Re: multiple on TEXT actions #137037 07/12/05 03:01 AM
Joined: Sep 2003
Posts: 19
F
fast68 Offline OP
Pikka bird
OP Offline
Pikka bird
F
Joined: Sep 2003
Posts: 19
how do i use the numbers ?

i thought you couldnt have more than one line of the same type?

that lays out the same as just having separate lines



hum

thanks

Last edited by fast68; 07/12/05 03:07 AM.


Re: multiple on TEXT actions #137038 07/12/05 03:13 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
If the match text information is different, then it qualifies as a different event...but be careful with the order that you place them in, especially if you're using wildcards in the match text.

Another way of differentiating between similar events is with event prefixes, also known as User Levels.

For example, the following would respond no matter who used it in the channel
Code:
 ON *:TEXT:!hello:#:{  .msg $chan Hi $nick } 

This next line would only respond if the person running the script was opped
Code:
 ON @*:TEXT:!hello:#:{  .msg $chan Hi $nick } 


Read up in the help file about the different ON events (ie: ON TEXT, ON NOTICE, ON ACTION, etc....and there's a lot more of them)

If you still need help, be more specific with what you're wanting to do, and I, or someone else, will be happy to assist you.