 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 2:57 am
help removing parenthsis |
Mud output:
"I see an ethereal cloak at Path entrance".
"I see an ethereal cloak at Path entrance".
"I see an ethereal cloak at Tap room".
"I see an ethereal cloak at The Hearth".
My trigger looks like this,
Pattern: I see an ethereal cloak at &posenloc
Value: #additem posrooms @posenloc
@posrooms ends up with the following output: Path entrance.|Tap room.|The Hearth".
Which is almost what I need, how can I remove the periods and the parenthsis? |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Mon Oct 08, 2007 2:58 am |
Try
#trig {~"I see an ethereal cloak at (*)~".} {#additem posrooms %1} |
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 3:04 am |
That works as well as the last trigger.
The output still looks like:
Tap room.|The Hearth.|Path entrance.|High chamber.|Altar of Proteus".
for example. |
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 3:12 am |
I think the problem is that the parenthsis is directly next to the word, that is there is no space between them.
Is there anyway to seperate them? |
|
|
 |
charneus Wizard

Joined: 19 Jun 2005 Posts: 1876 Location: California
|
Posted: Mon Oct 08, 2007 3:19 am |
those aren't parentheses. they are pipes and they separate list items. if you want to see the output with each on a separate line, do this. in your output alias, change it to #show %replace(@posenloc, "¡", %cr). since my cell doesn't have a pipe symbol, just change that ¡ to the correct symbol.
Charneus |
|
|
 |
charneus Wizard

Joined: 19 Jun 2005 Posts: 1876 Location: California
|
Posted: Mon Oct 08, 2007 3:24 am |
Oh by the way, change the posenloc to whatever you're wanting for your variable. i was using an example.
|
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 3:36 am |
Na the pipes don't bother me. I want to check my enemies location vs. a veil location. I can map my enemies location into a variable ok, but it doesn't contain the " or a .
However, because of the funky mud output when I check for veils I seem to have problems seperating the " and . from the veil locations.
So I won't be able to match the rooms :( |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Mon Oct 08, 2007 3:41 am |
That trigger should definitely not be matching the ending speech mark or full stop, and in my tests, it doesn't. You must've done something wrong when creating it, or perhaps you didn't delete the old trigger or something?
|
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 3:48 am |
Doh!
ok I deleted mine, done a cut and paste and its working :)
not sure what I was doing, but as long as it works...
thanks! |
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 4:09 am |
No wait. Crap. It only seems to be picking up the first word of the room name.
So for the mud output:
"I see an ethereal cloak at Path entrance".
"I see an ethereal cloak at Path entrance".
"I see an ethereal cloak at Tap room".
"I see an ethereal cloak at The Hearth".
Im getting something like: Path|Tap|The as my list variable for the rooms
On the up side it does seem to be getting rid of the parenthesis. |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Mon Oct 08, 2007 4:35 am |
What trigger pattern and script are you using? It worked fine in my tests - if you're still using &something or %w or something, it'll work differently. And again, make sure there are no older versions of the trigger around.
|
|
|
 |
Vijilante SubAdmin

Joined: 18 Nov 2001 Posts: 5187
|
Posted: Mon Oct 08, 2007 10:54 am |
#trig {~"I see an ethereal cloak at (*)~".} {#additem posrooms {%1}}
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
 |
dazed-n-confused999 Wanderer
Joined: 03 Aug 2004 Posts: 79
|
Posted: Mon Oct 08, 2007 2:17 pm |
Yep. It just need the extra brackets... go figure.
Thanks everyone! |
|
|
 |
|
|