Unknown2009-01-21 14:20:28
I have this trigger to inform me when I win an influence battle
enabled="y"
group="Influence"
match="(.*?) puffs up his|her chest and a crazy gleam enters his|her eyes as he|she vigorously agrees with you that his|her intelligence and strength far surpass anyone else's."
regexp="y"
send_to="12"
sequence="100"
>
EnableTrigger("Auto_Inf", 0)
Sound("ding.wav")
However, even when someone else wins, it still triggers, despite having 'you' in the trigger match line. What's wrong?
group="Influence"
match="(.*?) puffs up his|her chest and a crazy gleam enters his|her eyes as he|she vigorously agrees with you that his|her intelligence and strength far surpass anyone else's."
regexp="y"
send_to="12"
sequence="100"
>
Sound("ding.wav")
However, even when someone else wins, it still triggers, despite having 'you' in the trigger match line. What's wrong?
Unknown2009-01-21 14:48:05
You've made a list, but you forgot to enclose it in parentheses. Try (?:blah|bleh|bleah) type syntax instead.
Also, you are triggering on the general messages for a denizen being influenced, so it's going to fire no matter who does it. You'll need some sort of check or flag or enable/disable mechanism to prevent that. For example, you could enable this trigger when you influence something and disable it on the next prompt.
Also, you are triggering on the general messages for a denizen being influenced, so it's going to fire no matter who does it. You'll need some sort of check or flag or enable/disable mechanism to prevent that. For example, you could enable this trigger when you influence something and disable it on the next prompt.
Unknown2009-01-21 15:05:07
Ah, yes, I should do the enable/disable triggers thing.
Oli2009-01-23 09:19:32
Is there any way to pause or un-enable a trigger without doing it to all of em?
Esano2009-01-23 10:40:56
Either open up the trigger and change the flag, or use it's name with the script command EnableTrigger.
The syntax is EnableTrigger("triggername",true) to turn it on or EnableTrigger("triggername",false) to turn it off.
The syntax is EnableTrigger("triggername",true) to turn it on or EnableTrigger("triggername",false) to turn it off.
Oli2009-01-23 11:00:22
How do I apply a name to a trigger? I tried what you said with both the label and the matched text but neither seem to work.
Both give me
Run-time error
World: Treant
Immediate execution
:1: attempt to call global 'Enabletrigger' (a nil value)
stack traceback:
:1: in main chunk
Both give me
Run-time error
World: Treant
Immediate execution
:1: attempt to call global 'Enabletrigger' (a nil value)
stack traceback:
:1: in main chunk
Esano2009-01-23 11:04:42
Capitalization is important! It's EnableTrigger, in CamelCase (although not everything is).
It's the label, not the matched text, too.
It's the label, not the matched text, too.
Penna2009-01-23 11:07:13
QUOTE (Esano @ Jan 23 2009, 05:04 AM) <{POST_SNAPBACK}>
It's the label, not the matched text, too.
Thanks, I was wondering about this, too!
Unknown2009-01-23 14:24:31
Is there any way to make a ; not make a new line? I want to be able to blink again
Esano2009-01-23 14:36:18
The settings are in ALT+0, under 'Command stacking'.
Alternatively, you can add a ; to the start of the line, and it won't make ; into newlines for that line, e.g.
;say Hello
Alternatively, you can add a ; to the start of the line, and it won't make ; into newlines for that line, e.g.
;say Hello
Unknown2009-01-24 21:16:24
Just a quick question. How do I make it display the time of the output lines so I can see exactly how much time something takes, like I've seen in several logs (though that might not have been Mush)? Is there a plugin or is it simply a setting I'm missing?
Unknown2009-01-25 01:43:59
QUOTE (Brahms @ Jan 24 2009, 04:16 PM) <{POST_SNAPBACK}>
Just a quick question. How do I make it display the time of the output lines so I can see exactly how much time something takes, like I've seen in several logs (though that might not have been Mush)? Is there a plugin or is it simply a setting I'm missing?
Read this thread until you get to something useful and workable. It eventually references back to a thread on these forums with a plugin by Simimi, but I thought you might to see the whole process.
Kante2009-01-25 20:16:57
How would I go about making a targeting alias and other attacking aliases to use with the targeting?
I have been using Cmud, and all I had to do to set things up was set up a targeting alias by doing:
Alias name: t
script: tar=%1
To make a double-jab alias, I simply did:
alias name:ja
script: jab @tar
jab @tar
Due to my free trial of Cmud running out, how would I set up something similar in MUSHclient? I'm inept when it comes to coding, so a bit of explanation might be necessary.
I have been using Cmud, and all I had to do to set things up was set up a targeting alias by doing:
Alias name: t
script: tar=%1
To make a double-jab alias, I simply did:
alias name:ja
script: jab @tar
jab @tar
Due to my free trial of Cmud running out, how would I set up something similar in MUSHclient? I'm inept when it comes to coding, so a bit of explanation might be necessary.
Isuka2009-01-25 21:03:52
QUOTE (Kante @ Jan 25 2009, 12:16 PM) <{POST_SNAPBACK}>
How would I go about making a targeting alias and other attacking aliases to use with the targeting?
I have been using Cmud, and all I had to do to set things up was set up a targeting alias by doing:
Alias name: t
script: tar=%1
To make a double-jab alias, I simply did:
alias name:ja
script: jab @tar
jab @tar
Due to my free trial of Cmud running out, how would I set up something similar in MUSHclient? I'm inept when it comes to coding, so a bit of explanation might be necessary.
I have been using Cmud, and all I had to do to set things up was set up a targeting alias by doing:
Alias name: t
script: tar=%1
To make a double-jab alias, I simply did:
alias name:ja
script: jab @tar
jab @tar
Due to my free trial of Cmud running out, how would I set up something similar in MUSHclient? I'm inept when it comes to coding, so a bit of explanation might be necessary.
I solve that by doing it in the lua sandbox.
1: create an alias that sets your target. Configure to send to Script (rather than world) and create a variable in the lua sandbox that holds your target.
CODE
target="%1"
2: create your alias for the double jab. Configure to send to Script again, and then utilize Send().
CODE
Send("jab " .. target);Send("jab " .. target)
As an alternate method, you could use the GetVariable and SetVariable functions, and keep your target variable within the MUSH settings. I'm not sure which is actually better, but the way I outlined seems to be more efficient.
It does create persistence problem, though. I'm still trying to figure out the best way to save state over multiple sessions without having to use GetVariable a bunch of times.
Isuka2009-01-25 21:11:54
I'm looking for suggestions on how to handle target and enemy highlighting in mush.
With cmud the general approach is to create a stringlist of your enemies and a variable for your target, and then create triggers that match against those variables. ie "(@enemylist)" or "@target" with a simple #CW statement.
It doesn't seem to be that simple for mush.
So I suppose the question is twofold: is it possible to match against a lua sandboxed variable, and is it possible to color a single word within a line, or do I have to reprint the entire line somehow?
With cmud the general approach is to create a stringlist of your enemies and a variable for your target, and then create triggers that match against those variables. ie "(@enemylist)" or "@target" with a simple #CW statement.
It doesn't seem to be that simple for mush.
So I suppose the question is twofold: is it possible to match against a lua sandboxed variable, and is it possible to color a single word within a line, or do I have to reprint the entire line somehow?
Unknown2009-01-26 00:53:41
QUOTE (Isuka @ Jan 25 2009, 04:11 PM) <{POST_SNAPBACK}>
I'm looking for suggestions on how to handle target and enemy highlighting in mush.
With cmud the general approach is to create a stringlist of your enemies and a variable for your target, and then create triggers that match against those variables. ie "(@enemylist)" or "@target" with a simple #CW statement.
It doesn't seem to be that simple for mush.
So I suppose the question is twofold: is it possible to match against a lua sandboxed variable, and is it possible to color a single word within a line, or do I have to reprint the entire line somehow?
With cmud the general approach is to create a stringlist of your enemies and a variable for your target, and then create triggers that match against those variables. ie "(@enemylist)" or "@target" with a simple #CW statement.
It doesn't seem to be that simple for mush.
So I suppose the question is twofold: is it possible to match against a lua sandboxed variable, and is it possible to color a single word within a line, or do I have to reprint the entire line somehow?
You can use that same @var syntax in a trigger pattern in MUSHclient. You cannot match on script sandbox variables, however. You need to use MUSHclient world variables.
The simplest sort of trigger would be just to use the custom color option, but that highlights the entire trigger match (unless you get into some fancy negative lookahead regular expression matching). Alternatively, you can gag the text matched and re-echo it with script in whatever colors you want using ColourTell/ColourNote.
I highly recommend you look it up in the MUSHclient FAQ over on Nick's site. He answers questions like this a lot, so he pulled them all together for you.
Isuka2009-01-26 02:31:51
QUOTE (Zarquan @ Jan 25 2009, 04:53 PM) <{POST_SNAPBACK}>
You can use that same @var syntax in a trigger pattern in MUSHclient. You cannot match on script sandbox variables, however. You need to use MUSHclient world variables.
The simplest sort of trigger would be just to use the custom color option, but that highlights the entire trigger match (unless you get into some fancy negative lookahead regular expression matching). Alternatively, you can gag the text matched and re-echo it with script in whatever colors you want using ColourTell/ColourNote.
I highly recommend you look it up in the MUSHclient FAQ over on Nick's site. He answers questions like this a lot, so he pulled them all together for you.
The simplest sort of trigger would be just to use the custom color option, but that highlights the entire trigger match (unless you get into some fancy negative lookahead regular expression matching). Alternatively, you can gag the text matched and re-echo it with script in whatever colors you want using ColourTell/ColourNote.
I highly recommend you look it up in the MUSHclient FAQ over on Nick's site. He answers questions like this a lot, so he pulled them all together for you.
Cool. Thanks.
Kante2009-01-29 03:08:16
Unknown2009-01-29 03:17:09
QUOTE (Kante @ Jan 28 2009, 10:08 PM) <{POST_SNAPBACK}>
Umm...What?
Just admit it: you didn't even try to follow those directions because you assumed they made little or no sense.
Kante2009-01-29 03:23:49
QUOTE (Zarquan @ Jan 28 2009, 10:17 PM) <{POST_SNAPBACK}>
Just admit it: you didn't even try to follow those directions because you assumed they made little or no sense.
Nope, believe it or not, I actually did try. But as I said in my original post, I don't know when it comes to coding.
Edit:
QUOTE
tar rat
Interesting...
4383h, 2784m, 3405e, 10p, 19375en, 12130w ex-
Send("jab " .. target);Send("jab " .. target)
Might I suggest trying again?
4383h, 2784m, 3405e, 10p, 19375en, 12130w ex-
Interesting...
4383h, 2784m, 3405e, 10p, 19375en, 12130w ex-
Send("jab " .. target);Send("jab " .. target)
Might I suggest trying again?
4383h, 2784m, 3405e, 10p, 19375en, 12130w ex-