mIRC Homepage
Posted By: fast68 multiple on TEXT actions - 07/12/05 02:30 AM
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
Posted By: schaefer31 Re: multiple on TEXT actions - 07/12/05 02:57 AM
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...
Posted By: fast68 Re: multiple on TEXT actions - 07/12/05 03:01 AM
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
Posted By: RusselB Re: multiple on TEXT actions - 07/12/05 03:13 AM
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.
© mIRC Discussion Forums