|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 11:11 am
Confused about trigger on prompt and trigger on newline |
Trigger on prompt just doesnt do anything at all ? In zmud it was simple to understand - if i wanted something to trigger in the presence of a prompt instantly and without newlines, i just selected trigger on prompt, if i wanted triggers to fire only after a new line is received and not care about prompt at all then i selected trigger on newline.
Now in CMUD this is not the case for some reason ?
For example i made a basic trigger and selected trigger on prompt.
#TR {(*) arrives} {#show test successful}
#TR {(*) leaves} {#show test successful}
Now here is a line from my mud and you can see that my triggers are not firing at all. Why ?
<770hp 756ma 280mv>Ragnar Stoneforge arrives from the east.
<770hp 756ma 280mv>Ragnar Stoneforge leaves west.
<770hp 756ma 280mv>An armored man arrives from the west. |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 11:24 am |
When tested in Zmud this works line this
<770hp 756ma 280mv>Ragnar Stoneforge arrives from the east. (trigger on prompt fires)
(trigger on newline fires)
<770hp 756ma 280mv>Ragnar Stoneforge leaves west. ( (trigger on prompt fires)
(trigger on newline fires)
<770hp 756ma 280mv>An armored man arrives from the west (trigger on prompt fires)
(trigger on newline fires) |
|
|
|
Moo Apprentice
Joined: 10 Apr 2009 Posts: 145
|
Posted: Sat Dec 04, 2010 2:34 pm |
Maybe it isn't detecting anything there as a prompt. Look in Options - Session - Prompt.
|
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 2:47 pm |
Its empty, is that the reason ?
|
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 3:22 pm |
Nope, still doesnt work..
|
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Sat Dec 04, 2010 5:16 pm |
It works exactly the same as in ZMud. Which means you need to look at typical reasons why a setting won't fire: corruption, proper options selection, in a disabled class, etc.
|
|
_________________ EDIT: I didn't like my old signature |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 5:31 pm |
Ow, i tried and tested this multiple times, it just fails to work..
|
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 6:01 pm |
Anrok,
Turn on the debugger and post the output. I'll put money that there isn't a consistency from the mud. Also post the XML output of your trigger. |
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 6:13 pm |
Trigger is the above example, i'll get debugger logs and get back to you.
|
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 6:15 pm |
Anrok wrote: |
Trigger is the above example, i'll get debugger logs and get back to you. |
Yes that is the trigger, but it isn't the xml output. We might see something in the xml output that you aren't showing here. |
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 6:44 pm |
Do you want an xml of all my triggers or just those 2 triggers?
|
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 7:08 pm |
Post any that you think will help
|
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 7:09 pm |
Debugger just doesnt show any trigger output for that mud message.. it just shows the text and thats it. If i change that trigger setting to trigger on newline it starts working..
|
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 7:11 pm |
Goto to the messages menu in the debug window and check them all. This will give you everything,
|
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 7:29 pm |
checked everything, there's no trigger action happening on debugger related to that command when trigger on prompt option is selected, once i select trigger on newline it debugs fine...
|
|
Last edited by Anrok on Sat Dec 04, 2010 7:32 pm; edited 1 time in total |
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 7:31 pm |
okay. that means the trigger isn't matching the line.. So there is something wrong with the trgger. Post the trigger in XML and the text EXACTLY how it appears from the mud that you want to match. Make sure you put in into the code bbcode.
|
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 7:32 pm |
Yeah but why does it match fine when i select trigger on newline ?
|
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 7:35 pm |
How do i put an xml file or should i open with notepad and copy/paste it here ?
|
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 7:39 pm |
Post the xml output into the code bbcode tag and the mud output.
To get the xml output.. Select the trigger from the editor window. Select the xml tab shown below the code. This will show you the xml code. Now copy it into your clipboard.
Now come back here and post it into the code bbcode tags. Which looks like this minus the spaces: [ code ] put text here [ /code ].
Make sure you do the same for the mud output that you are trying to match. Post what the debugger shows for that line of text.. The mud be sending that line, but not consistantly each time. I would look at the debugger window and see if it sends it the same way each time.. If it is different post BOTH outputs. |
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
oldguy2 Wizard
Joined: 17 Jun 2006 Posts: 1201
|
Posted: Sat Dec 04, 2010 9:04 pm |
Just right click on the trigger, then click COPY, then paste it into code tags in your post. You don't have to export to XML.
|
|
|
|
oldguy2 Wizard
Joined: 17 Jun 2006 Posts: 1201
|
Posted: Sat Dec 04, 2010 9:14 pm |
Quote: |
Yeah but why does it match fine when i select trigger on newline ? |
That is why they asked you to post the raw I/O from the MUD for that line that shows up in the #DEBUG Window. They want to see the if it has <CR><LF> or <IAC><EOR> after it most likely. |
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sat Dec 04, 2010 9:18 pm |
oldguy2 wrote: |
Quote: |
Yeah but why does it match fine when i select trigger on newline ? |
That is why they asked you to post the raw I/O from the MUD for that line that shows up in the #DEBUG Window. They want to see the if it has <CR><LF> or <IAC><EOR> after it most likely. |
Exactly |
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
Anrok Apprentice
Joined: 19 Nov 2010 Posts: 119
|
Posted: Sat Dec 04, 2010 9:22 pm |
Not sure if thats what you wanted, but..made a slightly different trigger as i could capture it more easily and not wait for timed events..
<trigger priority="10" newline="false" prompt="true" id="1">
<pattern>You are already standing.</pattern>
<value>#show prompt test success!</value>
</trigger>
<770hp 701ma 280mv>wake
sta
You are already awake...
<770hp 701ma 280mv>You are already standing.
<770hp 701ma 280mv>wake
sta
You are already awake...
<770hp 701ma 280mv>You are already standing.
0.3855 | ---
0.0018 | c testmud | [2423] testmud Comline : start :
0.0020 | a testmud |<770hp 701ma 280mv>wake
0.0017 | h testmud |<770hp 701ma 280mv><ESC>[2Swake<ESC>[0m
0.0039 | i testmud >wake<CR><LF>
0.0042 | a testmud |sta
0.0021 | h testmud |<ESC>[2Ssta<ESC>[0m
0.0040 | i testmud >sta<CR><LF>
0.0041 | d testmud | [2423] testmud Comline : stopped
0.5691 | i testmud *You are already awake...<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0025 | a testmud |You are already awake...
0.0024 | a testmud |
0.0018 | a testmud ]<770hp 701ma 280mv>
0.3854 | i testmud *You are already standing.<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0026 | a testmud |<770hp 701ma 280mv>You are already standing.
0.0015 | h testmud |<770hp 701ma 280mv>You are already standing.
0.0025 | a testmud |
0.0017 | a testmud ]<770hp 701ma 280mv>
============================================
Now as trigger on newline..
<trigger priority="10" id="1">
<pattern>You are already standing.</pattern>
<value>#show prompt test success!</value>
</trigger>
<770hp 700ma 280mv>wake
sta
You are already awake...
<770hp 701ma 280mv>You are already standing.
prompt test success!
<770hp 701ma 280mv>wake
sta
You are already awake...
<770hp 701ma 280mv>You are already standing.
prompt test success!
0.0018 | c testmud | [2423] testmud Comline : start :
0.0019 | a testmud |<770hp 701ma 280mv>wake
0.0017 | h testmud |<770hp 701ma 280mv><ESC>[2Swake<ESC>[0m
0.0036 | i testmud >wake<CR><LF>
0.0019 | a testmud |sta
0.0016 | h testmud |<ESC>[2Ssta<ESC>[0m
0.0035 | i testmud >sta<CR><LF>
0.0018 | d testmud | [2423] testmud Comline : stopped
0.4923 | i testmud *You are already awake...<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0025 | a testmud |You are already awake...
0.0023 | a testmud |
0.0016 | a testmud ]<770hp 701ma 280mv>
0.9931 | i testmud *You are already standing.<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0026 | a testmud |<770hp 701ma 280mv>You are already standing.
0.0014 | h testmud |<770hp 701ma 280mv>You are already standing.
0.0025 | f testmud | Pattern: You are already standing.
0.0020 | c testmud | exec : Pattern "You are already standing." : #show prompt test s...
0.0017 | n testmud | Exec Trigger "You are already standing."
0.0019 | a testmud |prompt test success!
0.0022 | a testmud |
0.0029 | a testmud ]<770hp 701ma 280mv>
15.000 | ---
0.0017 | c testmud | [2423] testmud Comline : start :
0.0019 | a testmud |<770hp 701ma 280mv>wake
0.0016 | h testmud |<770hp 701ma 280mv><ESC>[2Swake<ESC>[0m
0.0040 | i testmud >wake<CR><LF>
0.0020 | a testmud |sta
0.0016 | h testmud |<ESC>[2Ssta<ESC>[0m
0.0036 | i testmud >sta<CR><LF>
0.0017 | d testmud | [2423] testmud Comline : stopped
0.3161 | i testmud *You are already awake...<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0025 | a testmud |You are already awake...
0.0023 | a testmud |
0.0017 | a testmud ]<770hp 701ma 280mv>
0.3945 | i testmud *You are already standing.<ESC>[0m<LF><CR><LF><CR>
0.0000 | <770hp 701ma 280mv>
0.0025 | a testmud |<770hp 701ma 280mv>You are already standing.
0.0014 | h testmud |<770hp 701ma 280mv>You are already standing.
0.0024 | f testmud | Pattern: You are already standing.
0.0021 | c testmud | exec : Pattern "You are already standing." : #show prompt test s...
0.0018 | n testmud | Exec Trigger "You are already standing."
0.0016 | a testmud |prompt test success!
0.0024 | a testmud |
0.0035 | a testmud ]<770hp 701ma 280mv> |
|
|
|
oldguy2 Wizard
Joined: 17 Jun 2006 Posts: 1201
|
Posted: Sat Dec 04, 2010 10:49 pm |
Looks to me like a problem with your MUD.
Use Trigger on New Line option and uncheck Trigger on Prompt. |
|
|
|
darmir Sorcerer
Joined: 10 Oct 2000 Posts: 706 Location: USA
|
Posted: Sun Dec 05, 2010 12:15 am |
Yep, You mud isn't consistent how they send the data. Try what oldguy2 said.
|
|
_________________ Run as hard as a wild beast if you will, but you won't get any reward greater than that destined for you.
Source: (Egyptian) |
|
|
|
|
|