Gammon Forum
Entire forum
MUSHclient
Bug reports
ColourNote bleeding - missed Trigger
ColourNote bleeding - missed Trigger
|
It is now over 60 days since the last post. This thread is closed.
  Refresh page
Posted by
| Aardlyworthit
(3 posts) 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% ]
| top |
|
Posted by
| Nick Gammon
Australia (22,973 posts) bio
Forum Administrator |
Date
| Reply #1 on Mon 15 Feb 2016 05:29 AM (UTC) |
Message
| |
Posted by
| Aardlyworthit
(3 posts) bio
|
Date
| Reply #2 on Tue 16 Feb 2016 03:42 AM (UTC) |
Message
|
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! | 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.
11,293 views.
It is now over 60 days since the last post. This thread is closed.
  Refresh page
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.