Trigger Chain over 1 or 2 lines

Post Reply
mgmudder
Posts: 1
Joined: Mon Jun 10, 2024 3:14 pm

Trigger Chain over 1 or 2 lines

Post by mgmudder »

Hello

I try to make a trigger over 1 or 2 rows.

what you write:
point at <name of monster>

what the mud writes:
you point at the ant and your magic ring glows blue.

you point at the ice giant and your magic ring glows
green.

you point at the huge green orc and your magic ring
glows yellow.

I need the reaction on the pointing, eg. the gring glowing blue.

what i tried:


trigger group
perl regex: 'point at (.*) and'
fire length (extra lines) 1
[ ] AND / Multi-line delta
[ ] only pass matches
[ ] match all


trigger
substring: ring
substring: glows
substring: green
fire length (extra lines) 0
[X] AND / Multi-line delta | value: 1
[ ] only pass matches
[ ] match all

trigger
substring: ring
substring: glows
substring: red
fire length (extra lines) 0
[X] AND / Multi-line delta | value: 1
[ ] only pass matches
[ ] match all

trigger
substring: ring
substring: glows
substring: blue
fire length (extra lines) 0
[X] AND / Multi-line delta | value: 1
[ ] only pass matches
[ ] match all

Sometimes it works, but next day it possibly doesn't works.
What is the right way to do that?

Thanks in advance

Jor'Mox
Posts: 1149
Joined: Wed Apr 03, 2013 2:19 am

Re: Trigger Chain over 1 or 2 lines

Post by Jor'Mox »

Try this, all as one big trigger:
perl regex: you point at (.+) and
substring: ring
substring: glows
perl regex: (\w+)\.
[X] AND / Multi-line delta | value: 1

It should capture the name of the target in multimatches[1][2] and the color the ring glowed in multimatches[4][2].

Post Reply