[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Bug reports
. . -> [Subject]  ColourNote bleeding - missed Trigger
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

ColourNote bleeding - missed Trigger

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page


Posted by Aardlyworthit   (3 posts)  [Biography] bio
Date Mon 15 Feb 2016 03:35 AM (UTC)
Message
Hello,

I recently had an issue with a Trigger not firing on output from the MUD if a ColourNote was output right before the trigger text was received. One plugin was sending the ColourNote onbroadcast of char.status. This caused it to send the note quite frequently. Another plugin was starting a procedure based on another broadcast, and was sending commands to the mud to view info and echo a 'completed' message back to my plugin. This ended up showing the ColourNote output, immediately followed by my echoed 'completed' message, and the echoed message was in the same color as the note. Any time this happened, the trigger did not catch the echoed text/line. Here is an example of the mud output.. The first line is the colournote and the second line is the trigger text that was not caught.

You don't have any more mana potions!
{aoe_done}

This trigger had no problems when run without a ColourNote output previous to it. When I changed my code from ColourNote to ColourTell followed by a Simulate('\n') the issue cleared up and the trigger caught the completed message just fine. The trigger is enabled using EnableTriggerGroup before the commands/echo are sent.

function do_check()
	if checking then
		return
	end
	checking = true
	EnableTriggerGroup("spells", true)
	skills = {}
	spells = {}
	aoe = {}
	t = skills
	SendNoEcho("skills combat")
	SendNoEcho("echo {skills_done}")
	SendNoEcho("spells area")
	SendNoEcho("echo {aoe_done}")
	SendNoEcho("spells combat")
end


<trigger
   enabled="n"
   match="^\{aoe_done\}$"
   regexp="y"
   sequence="100"
   group="spells"
   omit_from_output="y"
   script="set_table_spells"
  >
  </trigger>


ColuorNote("yellow", "", "  You don't have any more ", "cyan", "", name, "yellow", "", " potions!")


MUD output example:

 [ Fighting! ]  Health: 1828/2804 65%  Mana: 1774/2645 67%    [ Enemy: 51% ] 
qm
  You don't have any more mana potions!
{aoe_done}
 [ Fighting! ]  Health: 1828/2804 65%  Mana: 1774/2645 67%    [ Enemy: 51% ]
[Go to top] top

Posted by Nick Gammon   Australia  (21,324 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Mon 15 Feb 2016 05:29 AM (UTC)
Message
Template:version Please help us by advising the version of MUSHclient you are using. Use the Help menu -> About MUSHclient.


In particular, version 4.99 fixed a problem similar to yours.

http://www.gammon.com.au/scripts/showrelnote.php?version=4.99&productid=0

Current version is 5.01: http://www.gammon.com.au/forum/?id=13318

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Aardlyworthit   (3 posts)  [Biography] bio
Date Reply #2 on Tue 16 Feb 2016 03:42 AM (UTC)
Message
Nick Gammon said:

(version)

In particular, version 4.99 fixed a problem similar to yours.

http://www.gammon.com.au/scripts/showrelnote.php?version=4.99&productid=0

Current version is 5.01: http://www.gammon.com.au/forum/?id=13318


Apologies, I tried to add version in after posting but was limited by the anti-spam measures. :)

I am using 4.96. I will have to update then.

I did try searching the forums for colournote but didn't notice anything in particular.

Thank you for the quick response!
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


1,717 views.

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]