Ok, I bought a system for Zmud, then decided I hated Zmud, now I need to convert the system to Mushclient, if anyone can help I'd be very grateful. This is all confusing, so if there is help, I will need it step by step, sorry.
Zmud Writhebalance in MSScript / VBSript
#CLASS {Writhebalance}
#TRIGGER {Sticky strands of webbing spray out from %1 to cover you.} {
web=1
#if {@writhe=0} {writhe}
}
#TRIGGER {blade back and plunges it deep into your helpless body} {
impale=1
#if (@writhe=0) {writhe}
}
#TRIGGER {reaches out and draws you close} {
feed=1
#if {@writhe=0} {writhe}
}
#TRIGGER {Strangely, you forget whatever it was you were doing and feel inwardly } {
transfix=1
#if {@writhe=0} {writhe}
}
#TRIGGER {You spring a trap!! A loop of rope entwines around you} {
rope=1
#if {@writhe=0} {writhe}
}
#TRIGGER {You begin to writhe furiously to escape the blade that has impaled you.} {writhe=1}
#TRIGGER {You begin to trying to wrest your mind free of that which has transfixed it.} {writhe=1}
#TRIGGER {You exert your will and attempt to writhe free of the vampire's embrace.} {writhe=1}
#TRIGGER {You have writhed free of your state of transfixation.} {
transfix=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
ebay
}
#TRIGGER {Summoning your will, you writhe free of * agonizingly pleasurable} {
feed=0
wrbal
as
}
#TRIGGER {You have writhed free of your entanglement by tied ropes.} {
rope=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free of your entanglement by ropes.} {
rope=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free of your entanglement by webs.} {
web=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free} {writhe=0}
#TRIGGER {With an heroic effort you manage to writhe yourself free from the weapon} {
impale=0
wrbal
}
#TRIGGER {blade back and plunges it deep into your helpless body} {
impale=1
#if (@writhe=0) {writhe}
}
#TRIGGER {reaches out and draws you close} {
feed=1
#if {@writhe=0} {writhe}
}
#TRIGGER {Sticky strands of webbing spray out from %1 to cover you.} {
web=1
#if {@writhe=0} {writhe}
}
#TRIGGER {Strangely, you forget whatever it was you were doing and feel inwardly } {
transfix=1
#if {@writhe=0} {writhe}
}
#TRIGGER {Summoning your will, you writhe free of * agonizingly pleasurable} {
feed=0
wrbal
as
}
#TRIGGER {With an heroic effort you manage to writhe yourself free from the weapon} {
impale=0
wrbal
}
#TRIGGER {You begin to trying to wrest your mind free of that which has transfixed it.} {writhe=1}
#TRIGGER {You begin to writhe furiously to escape the blade that has impaled you.} {writhe=1}
#TRIGGER {You exert your will and attempt to writhe free of the vampire's embrace.} {writhe=1}
#TRIGGER {You have writhed free of your entanglement by ropes.} {
rope=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free of your entanglement by tied ropes.} {
rope=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free of your entanglement by webs.} {
web=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
}
#TRIGGER {You have writhed free of your state of transfixation.} {
transfix=0
wrbal
#ECHO YOU'RE FREE!!!
#cw 12
ebay
}
#TRIGGER {You have writhed free} {writhe=0}
#TRIGGER {You spring a trap!! A loop of rope entwines around you} {
rope=1
#if {@writhe=0} {writhe}
}
#CLASS 0
Wow, I didn't know it was that long, if you can do like the first 2 triggers (which ever 2 those are, I'm completly lost) I should be able to figure it out, I had another question, what are the random values for triggers, such as for zmud, a simple trigger looks like this
%w forms a spear hand and stabs out at you.$* connects to the * arm!
I'm not sure what I'm doing....I can e-mail anyone that wants a copy of the Zmud trigger/alias system so you can see it personally, but I'm not sure what I would copy so you can see what I'm having problems with.....hmmmm, the impale thing is a good point....
lol, thats the problem, I bought the system because it takes months to build your own. It's a system based around curing afflictions and healing when you fight. All I have to go on is what Zmud has in it's files, which is what I copied above. the Writhebalance confuses the hell outta me, and I don't even know what to look for. Here is all I can do, sorry again for my ignorance.
Zmud version:
Pattern:%w dodges nimbly to the side and trips you to the floor.
Command: #echo ****STAND!!! STAND!!!****;#cw 6786;#temp {You have recovered} {stand}
----------------------------------
the %w is the random target or name I guess of the character doing the attack on you, what does mushclient use in place of that? Second, I'm not even sure what all that crap thats in the command section is, I would assume that all I would want to have sent is STAND....I don't know what the hell the #echo crap means
Well it is a mess and I have no clue if it will actually work, but:
<triggers>
<trigger
enabled="y"
group="Writhebalance"
match="^Sticky strands of webbing spray out from %1 to cover you\."
regexp="y"
send_to="12"
>
<send>web = 1
if writhe = 0 then send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="blade back and plunges it deep into your helpless body"
send_to="12"
>
<send>impale = 1
if writhe = 0 then send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="reaches out and draws you close"
send_to="12"
>
<send>feed = 1
if writhe = 0 then send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="Strangely, you forget whatever it was you were doing and feel inwardly "
send_to="12"
>
<send>transfix = 1
if writhe = 0 then send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You spring a trap!! A loop of rope entwines around you"
send_to="12"
>
<send>rope = 1
if writhe = 0 then send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You begin to writhe furiously to escape the blade that has impaled you."
send_to="12"
>
<send>writhe = 1
send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You begin to trying to wrest your mind free of that which has transfixed it."
send_to="12"
>
<send>writhe = 1
send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You exert your will and attempt to writhe free of the vampire's embrace."
send_to="12"
>
<send>writhe = 1
send "writhe"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You have writhed free of your state of transfixation."
send_to="12"
>
<send>transfix = 0
send "wrbal"
colournote "red","black","YOU'RE FREE!!"
send "ebay"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="Summoning your will, you writhe free of * agonizingly pleasurable"
send_to="12"
>
<send>feed = 0
send "wrbal"
send "as"</send>
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="^(You have writhed free of your entanglement by tied ropes\.|You have writhed free of your entanglement by ropes\.)"
regexp="y"
send_to="12"
>
<send>rope = 0
send "wrbal"
colournote "red","black","YOU'RE FREE!!"
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You have writhed free of your entanglement by webs."
send_to="12"
>
<send>web = 0
send "wrbal"
colournote "red","black","YOU'RE FREE!!"
</trigger>
<trigger
enabled="y"
group="Writhebalance"
match="You have writhed free"
send_to="12"
>
<send>writhe = 0</send>
<trigger
enabled="y"
group="Writhebalance"
match="With an heroic effort you manage to writhe yourself free from the weapon"
send_to="12"
>
<send>impale = 0
send "wrbal"</send>
</triggers>
I get the feeling that some of the repeated stuff in the original was just flat out confusion on the part of the designer. Some of it did things that could be done in a single trigger and others where just plain redundant.
Hmm.. Actually, the first trigger in there needs to be:
match="^Sticky strands of webbing spray out from .* to cover you\."
I forgot the %1 was in there. :(
However, to answer your question:
'^' is a special character used with 'regexp' types. It means "only match if this is at the start of a line".
'*' is a wildcard, however in the line above you will notice I use '.*' instead, this is because * has a different meaning in regular expressions (regexp="y" types). In regexp it means "more than one of the prior item" and "." is the wildcard. Specifically - '.*' means "match any character + more than one of this character". This is identical to '*' when used in normal triggers. There is no real reason that first trigger should use it, but I later use this:
^(You have writhed free of your entanglement by tied ropes\.|You have writhed free of your entanglement by ropes\.)
In this case the '()' are a sub-collection and '|' means 'or', so it will match either one of those strings, which saves having to have more than one trigger.
As for things like %1, %2, %3, etc. These are the 'values' of a wildcard. These cannot be used in the 'match' field. Used in the send field they directly substitute the word(s) captured. For instance a trigger like:
match="* says: Hi!"
<send>say Hi %1.</send>
Would do this:
Line recieved - Fred says: Hi!
%1 becomes "Fred" and the trigger would send "say Hi Fred."
You will also notice that I use send_to="12" in several places. This means "treat all the stuff in <send></send> as code. In that case you would need to place "" around the %1 or direct substitution would result in the script thinking that the word(s) are variables, not a value. Using the above example:
Normal trigger - say Hi %1.
Using send_to="12" - send "say Hi %1."
The " is the XML version of ". If you are creating a trigger directly in Mushclient you would use the normal character, not the XML version.
As for how to use it all, you just fix the minor mistake I made, copy it all into the clipboard and use the "Paste" button in the trigger editing menu. Assuming I didn't screw up the actual XML code, it should copy the whole mess right into the trigger list. ;)
hmmm, I must be doing something wrong.... it didn't work, I pasted the text into the trigger part right? by pushing the little button to the left of the field that has the ... in it? I pasted all that in there......
Here's one I've been playing around with trying to figure it out and I cant get it to work...
In a sensuously fluid motion, Kismit reaches out and draws you close, baring
pale fangs before sinking them into the tender flesh of your neck. Horrified,
you go limp as the pain intermingles with indescribable pleasure.
what do I set the trigger for and how? I need it to allow me to writhe
Hilight all of the triggers, then use Ctrl-C to copy them. If mushclient recognizes what is now in the clipboard as being a set of triggers, then a button that says "Paste" will be available in the trigger menu. That is all there is too it.
<triggers>
<trigger
enabled="y"
group="Writhebalance"
match="^you go limp as the pain intermingles with indescribable pleasure\."
regexp="y"
send_to="12"
>
<send>if writhe = 0 then send "writhe"</send>
</trigger>
</triggers>
I have no idea what variable you may want to set, though as near as I can tell, the set of triggers you gave ignores those things anyway.
ok, I tried just that trigger above....it doesn't work, but I did get this to work...
Trigger Field: In a sensuously fluid motion, * reaches out and draws you close, baring
Send Field: Writhe
thats seems to work....but is it as good as the one you wrote with all that extra stuff? I'm not sure if there's a difference....
The difference is only the 'if' statement in there, which is apparently supposed to begin the process of attempting to writhe out of something only if the message arrives and you are not already doing so. I am not sure that it matter at all, since the effect is probably the same.
As for all that extra stuff... It is the XML code for the trigger. I suspect you are doing:
Add...
Then trying to copy all the stuff into the Match: field. If so then "WRONG!". If you look at the trigger setup screen there are a mess of buttons, Add.., Edit, Remove, etc. On the far right are two buttons like:
Copy
-Paste- <-- this one dimmed.
If you 'copy' a trigger like I posted, as though you where copying it from one window to another, then the 'Paste' button should suddenly become active, since the clipboard (where windows puts things it is copying from one place to another) now contains a trigger. By clicking on that button, the thing you copied will be entered directly into the list of triggers, without you needing to use 'Add..' at all. Got it? ;) This lets you drop triggers directly in, along with all the complex settings, instead of entering every setting manually.
If you are doing what I think, then you are expecting mushclient to act like zmud and automatically convert everything you put into one box in the 'Add..' page into a complete trigger. Instead, mushclient will assume that all that stuff is the text you are looking for and will create a trigger that has no setting, sends nothing and will never match.
I got everything working finally, so far it's been going good, thanks for all the help Shadowfyr. to write out additional triggers my self should I just use the same model, except replce the match section and send seciton with the correct text?
For your own it is easier to enter all the setting in using "Add..". It is a lot easier to see and change all the settings in there.
To copy one, to show on here for example, you can then select it in the list and use the 'Copy' button. That will convert the trigger to XML and place it into the clipboard, so you can paste it into other programs.
Glad you figured out what was hanging up the triggers I gave you. I threw them together off the top of my head while waiting for some monsters to repopulate, so was only paying half attention to what I was doing. lol I also had no way to test them, so.. Hope they are work ok. ;)
Usually all that sort of stuff is done in a master script, however I have been using send_to="12". In the Add.. dialog there is a selection that says 'Send to:', you would choose "Send to Script" from the list of options under that. Then convert the 'if' and stuff to VBScript and place it in the 'Send' box:
if herbalance=0 AND stun=0 then
outb ash
eat ash
end if
herbalance=1
ash=1
More complex stuff is better handled in the master script, which you probably don't yet have. Examples of how such a master script works are included with Mushclient.
Well, if stunned you can't do those commands, so it prevents that. It also prevents it if you are already making the attempt. Out of context of the entire script and the actual mud events that it handles, I can't say for certain.