My mud uses a special trigger string to make creating client based triggers easier.
For example, when there is a change in my vitals, my mud sends:
xxxxx_prompt 150 200 300 300 400 400
Which is in the following format "HP maxHP MP maxMP MV maxMV". There are a fair amount of these xxxxx_.* triggers in the game.
They all follow the same format of xxxxx_ followed by something, so instead of creating a trigger for each i decided it would be more efficient to use a trigger filter as such...
^xxxxx_ (perl regex)
then in that group I have added a trigger
prompt (\d+) (\d+) (\d+) (\d+) (\d+) (\d+).*$ (perl regex)
Code: Select all
echo(string.format("HP: %d/%d", matches[2], matches[3])
deleteLine()
I've tried multi-line and fire length both inside and outside of the filter group, but can't see to remove the extra line if it present.
How do I delete the extra line if it's there?
I've tried multi-line and fire length both inside and outside of the filter group.
Thanx
-RZ