 |
eyeshade Newbie
Joined: 14 Jul 2003 Posts: 5
|
Posted: Mon Jul 10, 2006 3:09 pm
Room exits to variable |
I would like to capture existing room exits to a variable, the mud I am on uses the follow format:
Obvious exits: -N -S -E -W
I have tried #tr {Obvious exits: (*)} {#var exits %1} this will only capture -N. I would like exits to be -N -S -E -W.
How do I create at pattern to grab everything in that line? |
|
|
|
 |
Kjata GURU

Joined: 10 Oct 2000 Posts: 4379 Location: USA
|
Posted: Mon Jul 10, 2006 3:29 pm |
zMUD replaces the %1 with the exact text that was matched before running this script. In this case, this means that your #VAR command would end up something like this:
#VAR exits -N -S -E -W
This is incorrect syntax for the #VAR command and confuses zMUD. What you need to do is to surround the %1 with curly braces, like {%1}, to let zMUD know that all of that goes together. |
|
_________________ Kjata |
|
|
 |
eyeshade Newbie
Joined: 14 Jul 2003 Posts: 5
|
Posted: Mon Jul 10, 2006 3:36 pm |
worked like a charm, I never knew that about the #var command Ill keep it in mind in the future. Thanks!
|
|
|
|
 |
|
|
|