Prompt triggers

Posted by Rangon on Sat 08 Apr 2006 02:11 PM — 10 posts, 39,885 views.

#0
I'm also having a problem getting prompts to hit triggers when they're supposed to. I've got the prompt set to a trigger, and the correct one. However, when the prompt comes up on the screen, I have to hit something or something else has to happen on the screen before that prompt will fire.

I've tried notating the trigger with ^...$ and tried the different options listed on the trigger. Does anyone have any ideas about what I might be able to do to get these prompts to fire quicker? It just seems to me that they don't want to fire on that last line of the screen.

Australia Forum Administrator #1
There have been many, many discussions on this forum about this. Basically the answer is that MUSHclient processes triggers when a newline arrives, in your case it hasn't arrived yet so the trigger doesn't fire (yet).

There are various work-arounds, one is to make the MUD append a newline to prompt lines. For another, see this post:

http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=5020

This adds a newline when it receives a prompt.

I think there was another one again where a plugin had a timer that checked for prompts before the newline. This is on the plugin page:

http://www.gammon.com.au/mushclient/plugins/

Look for the plugin "Status_Bar_Prompt".
#2
Nick,

Thanks for posting the links. I looked over a lot of what you put on there but, unfortunately, while it is putting the extra line it's still waiting for some other type of input on that line before resolving the plug-in. Could I just be missing something?

It does put the extra newline in, and it's putting it in before any of the triggers fire for that prompt, but it's still waiting. There are no options or anything to do on the fly trigger completion as the program receives lines? That sounds like something that would have to be changed at the base programming level though...

Just so you know, I am using 3.7.

I appreciate your help thusfar.
Australia Forum Administrator #3
Can you paste the whole trigger please? See this post for how to copy it to the clipboard:

http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=4776
#4
This is the trigger that I use for script execution on prompt.

<triggers>
<trigger
enabled="y"
match="^H:(.*?) M:(.*?) E:(.*?) W:(.*?) B:(.*?)% \[(?P&lt;Prone&gt;(.*?)) (?P&lt;Equil&gt;(e|\-))(?P&lt;Balan&gt;(b|\-))\]"
name="Prompt"
regexp="y"
script="Prompt"
send_to="12"
sequence="100"
variable="test"
>
</trigger>
</triggers>

I tried this trigger's expression in your plug-in and I also tried just ^H:(.*?)(with and without $) and both of them would hide the prompt at the bottom of the screen until something 'new' happened. Then it would parse all of the prompts together.

For instance, if I hit enter a couple of times and then looked, my screen would look like this:

previous stuff
(empty)
(empty)
(empty)
prompt - prompt - prompt - room information

Every time I would hit enter it would put in another blank space. As soon as I did something that the computer would respond back with, it dumped all the triggers onto me at once. Did I do something wrong?
Australia Forum Administrator #5
If you are seeing:

prompt - prompt - prompt - room information


Then you are not getting a newline at the end of the prompt.
#6
Yeah, I know that it's not working properly. It's an IRE prompt. Does anyone out there have a possible plug in that's known to work? All of the information on the link you sent to me, Nick, is from well back in 2005 on a completely different version of the program. I can't seem to get it to work just as it should.

Has anyone had any true luck getting MushClient to give the newline on IRE games; Aetolia specificly?

Thanks!
Australia Forum Administrator #7
The program has not radically changed in the last year. Mainly scripting improvements and a few bug fixes.

In the Output configuration, have you tried checking: "Convert IAC EOR/GA to new line"?

I'm not sure if it applies to Aetolia, but some MUDs send a special sequence at the end of prompts that MUSHclient can convert to a newline.
#8
The IRE Muds do, in fact, use the IAC EOR/GA.

Well, at least Achaea does, but Im pretty sure it's all of them.
Australia Forum Administrator #9
If you enable that setting, then the prompts should take a line each.