|
Myrddraal Beginner
Joined: 25 Jan 2003 Posts: 14 Location: Australia
|
Posted: Wed Sep 03, 2003 3:53 am
Trigger Spacing |
Hi,
Just wondering whether there was a command which will ingore multiple spaces in a trigger, or treat a long space as a single space etc.
The trigger pattern working with is:
Pattern:
A downy skullcap (skullcap) 16 left.
Value:
harvest skullcap 1
and i want to use the number 16, but for some reason it wont pick it up, mainly because i think of the spacing. I've tried using %s, but this doesn't work.
So i've also tried
A downy skullcap (skullcap)%s16 left.
as the pattern and that didn't work either |
|
|
|
Myrddraal Beginner
Joined: 25 Jan 2003 Posts: 14 Location: Australia
|
Posted: Wed Sep 03, 2003 3:55 am |
oops, sorry, in the trigger text above there is about 10 spaces between the
A downy skullcap (skullcap)<insert 10 spaces here>16 left.
when i submitted it, it looks to have cleared the spacing. |
|
|
|
TonDiening GURU
Joined: 26 Jul 2001 Posts: 1958 Location: Canada
|
Posted: Wed Sep 03, 2003 4:48 am |
Code: |
A downy skullcap (skullcap) 16 left.
|
#TRIGGER {^(*) ~((%w)~)%s(%d) left.} {#SH 1~:%1;#SH 2~:%2;#SH 3~:%3}
Edit: changed SH to #SH and %3) to %3}
Test:
1:A downy skullcap
2:skullcap
3:16 |
|
|
|
Myrddraal Beginner
Joined: 25 Jan 2003 Posts: 14 Location: Australia
|
Posted: Wed Sep 03, 2003 5:13 am |
Thanks for that, i tried it just using the {^(*) ~((%w)~)%s(%d) left.} to try and trigger a trigger and it didn't work, i also tried {^(*) ~((skullcap)~)%s(16) left.} and that didn't work either
|
|
|
|
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Wed Sep 03, 2003 9:30 am |
Pattern:
^A downy skullcap ~(skullcap~)%s16 left.
Value:
harvest skullcap 1
If you also want to allow numbers larger than 16,
Pattern:
^A downy skullcap ~(skullcap~)%s(%d) left.
Value:
#IF (%1 > 15) {harvest skullcap 1}
When converting from command-line syntax (#TRIGGER) to the settings editor, drop the outside set of brackets {} from each section (Pattern and Value). I made the pattern specific to skullcap because your command is specific to skullcap. |
|
|
|
|
|