|
Shogi Newbie
Joined: 05 Mar 2008 Posts: 3
|
Posted: Thu Mar 27, 2008 10:08 am
Expanding Variables in Pattern Matching portion of a Trigger |
Is it possible to expand a variable in the Trigger Pattern Match?
Such as
Code: |
#VAR partner Bob
#TRIGGER {@partner hits dog.} {assist @partner} |
Would trigger on the line: Bob hits dog.
So I can setup one group of triggers and just change the variable when I change partners?
I tried this and it didn't seem to be expanding the variable. I poked around in the settings and couldn't figure out what would prevent it.
Thanks for any help. |
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Thu Mar 27, 2008 10:30 am |
Yes, it works fine. I did this to test:
#VAR partner Bob
#TRIGGER {@partner hits dog.} {assist @partner}
#say Bob hits dog.
Something must be interfering with the trigger seeing the variable - do you have any other @partner variables, or is it in a class that's disabled or something? |
|
|
|
|
|