|
Ethershade Beginner
Joined: 17 Oct 2008 Posts: 11
|
Posted: Sat Aug 01, 2009 2:21 pm
Automapper - Strings occasioanly following exits |
Alright, This should be pretty simple but I'm new to the automapper. It easily detects these types of rooms:
The Main Room of the Red's Retreat [NSW]
Where it adds the directions North, South and West. However, when it comes across these type of rooms:
An Antechamber of the Red's Retreat [NEU Quit]
It bugs out and doesn't add the room.
Is there a simple option I can set up to fix this?
EDIT:
Also, It bugs out when it has a line directly preceeding it. Like going in a direction and seeing:
The human soldier briefly inspects your belongings before allowing you to pass.
Caravan Road [EW]
Second Edit:
I fixed the second bug with the soldier, I just gagged the line. |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Sat Aug 01, 2009 2:45 pm |
For the second problem, you don't have to gag it. Instead, do #NOMAP on it. It will display, but the mapper will ignore it.
The first problem is a bit tricky. I'm trying to solve a similar problem. I think the solution may be to rewrite the line, with #sub, into something like: An Antechamber of the Red's Retreat [NEU] [Quit]. But I haven't actually tried it yet. |
|
|
|
Ethershade Beginner
Joined: 17 Oct 2008 Posts: 11
|
Posted: Sat Aug 01, 2009 2:54 pm |
I thought that might be a solution, but it says the #SUB makes it ignore further parsing of triggers.
|
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Sat Aug 01, 2009 3:57 pm |
I've only partially tested this, but so far it looks good:
Code: |
<trigger priority="1390" regex="true" id="139">
<pattern>( (Leave|Quit|Save)(?: Leave)?(?: Quit)?(?: Save)?)\]</pattern>
<value>#psub {] [%trim(%1)} %x1</value>
</trigger>
|
|
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Sat Aug 01, 2009 5:01 pm |
Are there other lines that are built similarly in your MUD? You might try going with a trigger like so:
#trigger {^([%w%s'])~[([NEWSUD]) *~]$)} {#tag name %1;#tag exit %2}
[] = a range of continuous characters that match the values within. In the first one (%w%s'), this means it matches any sort of multi-word phrase where the words can only contain letters and the apostrophe. The second one specifies only those specific letters, so it'd be any one-word string consisting only of the letters N, E, W, S, U, and D. |
|
_________________ EDIT: I didn't like my old signature |
|
|
|
|
|