 |
Acheron Newbie
Joined: 27 Aug 2009 Posts: 4
|
Posted: Thu Aug 27, 2009 6:37 pm
Help configuring automapper |
I'm trying to map a mud with the following form of room descriptions. I want to just capture the room name(in yellow, the brown areaname can be dropped) and the exits in the exit line. The problem is that every entrance into a new room is proceeded by a line like "You head south down the street" which the automapper is capturing as the room name while I'm trying to get it to do so by color. I've looked at the documentation for #TAG and standard expression mapping, but I just can't seem to come out with a way to do this. Anyone willing to help?
Fourth Ave - 400 block (freedom city) 8:29am (public)
A small plaque is set into the curb. A metal sign is bolted to the wall to the west. Rust streaks down the wall from the bolts. An FCPD cam peers down from a utility pole. A burned-out compact car sits by the roadside. Some blue graffiti reading 'THRXW ITEM TO X' is sprayed on the wall of a building.
You see a quarter lying on the sidewalk.
[ Exits: north east south west ^ up(wall) ] |
|
|
 |
Zugg MASTER

Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Thu Aug 27, 2009 6:41 pm |
First, you can use the #NOMAP command in a trigger to prevent the mapper from seeing certain text. For example:
#TRIGGER {^You head *} {#NOMAP}
would cause the "You head south..." line to be ignored by the mapper.
For the room name tag, try something like:
#TRIGGER {^(*) ~(*~) * ~(*~)$} {#TAG name %1}
assuming that each room name has the same format as what you showed above (with two items within parenthesis).
Remember that after creating #TAG and #NOMAP triggers you still need to run the mapper Config/Reconfig menu command to reconfigure the mapper. |
|
|
 |
Tech GURU

Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Thu Aug 27, 2009 6:49 pm |
You'll need to combine your use of #TAG with ANSI Triggers. Then you would use trigger to match the color code you want store that text using #TAG.
The easiest way to get the ANSI color codes is to set you trigger to be an ANSI trigger, save it, then copy the specific colored text into the pattern bar of the trigger. It will already have the appropriate ANSI codes included. |
|
_________________ Asati di tempari! |
|
|
 |
Acheron Newbie
Joined: 27 Aug 2009 Posts: 4
|
Posted: Thu Aug 27, 2009 11:39 pm |
When I cut and paste the room name line into an ANSI trigger, I get something like this:
%e[1;33mHigh St - 400 block%e[0S (%e[33mfreedom city%e[0S) %e[1;37m12:%e[1;37m19%e[0;37mam%e[0S (public)%e[0m$
The only part I need for the room name is the bit before (freedom city). So something like #TRIGGER {%e[1;33m*%e[0S ~(} to capture the yellow room text delimited by the open parenthesis? I've tried that and it doesn't work. |
|
|
 |
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Fri Aug 28, 2009 2:19 pm |
How about: #TRIGGER {%e[1;33m(*)%e[0S ~(} {%TAG name %1} roomname color
edit: It has to be marked as an ANSI trigger or it won't correctly detect the ansi codes. That's what the 'color' option above does. |
|
|
 |
Tech GURU

Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Fri Aug 28, 2009 2:37 pm |
Try this...
Code: |
<?xml version="1.0" encoding="ISO-8859-1" ?>
<cmud>
<trigger priority="40" ansi="true" copy="yes">
<pattern>%e[1;33m(*)%e[0*%e[33</pattern>
<value>#echo City Name is %stripansi(%1)</value>
</trigger>
</cmud>
|
|
|
_________________ Asati di tempari! |
|
|
 |
Acheron Newbie
Joined: 27 Aug 2009 Posts: 4
|
Posted: Wed Sep 02, 2009 10:07 pm |
Ok, after a bit of fiddling I've gotten it recognizing rooms correctly, but I've still got a few problems.
One is that slow walking is crashing, but only when moving from one zone into another. And it doesn't trigger if I begin the slowwalk in a room adjacent to the other zone. Speed walk and safe walk are working perfectly. Any ideas on how to fix it, or a work around?
Secondly, is there a way for an transition from one zone to another to be represented as a room rather than a label? I've got, for example, a large building that's a separate zone than the town it's in, but is there a way for me to show on the town map a room for that building, so that double-clicking on it to walk there will put me in the building zone? Maybe a room specific script that catches attempted paths to it and redirects to a different room number? |
|
|
 |
Tech GURU

Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Thu Sep 03, 2009 3:11 pm |
I'm not about the slow walking crash. We may be able to give more insight if you post the crash dumps. As for you second question, there currently isn't any to do what you're asking (although you can set up a zone hierarchy from the Zones tab when editing the mapper).
It should be noted that the mapper is being completely redesigned and developed in the 3.x BETA line to specifically address the types of concerns you have identified. If you are will to be on the bleeding edge, and help identify and resolve bugs, it might be worth looking into. |
|
_________________ Asati di tempari! |
|
|
 |
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Fri Sep 04, 2009 2:03 pm |
There is actually a way to simulate this, but it only partially works for speed walking. This procedure definitely works in version 3.xx, and I think it works in 2.37 as well.
Say you have room A (zone A) connected to room B (zone B). You place copies of room A and room B in both zone A and zone B. In the copy of room B in zone A, you put a room script to #teleport you to the corresponding room in zone B. Similarly, in the room A in zone B you put a room scrip to #teleport to the corresponding room in zone B. This will allow you to double-click on room B in zone A, or room A in zone B. However, it will not work if you try to speedwalk from zone A to some other room in zone B, because it won't know about the #teleport script and can't find the path.
On the other hand, you could simply put a fake room B in the right place on zone A, while having the actual portal go to the correct room in zone B. This would allow speed walking to work between zone A and zone B, but double clicking on the fake room B in zone A would not do anything. It would just look nice.
There is (currently) no way to have it both ways. |
|
|
 |
|
|