Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
Amorelia
Beginner


Joined: 09 Oct 2012
Posts: 18

PostPosted: Wed Oct 10, 2012 2:32 pm   

Automapper Parser
 
Hi,

I'm a new user of CMud, and am trying the Automapper. I'm having difficulty getting it to recognise new rooms, but can't work out why - some it recognises, others not. I played around with the config settings, but can't really get it to work consistently. Is there some sort of parser, which can show me how the system is interpreting the text-feed from the MUD? I don't find the online help very easy, it has a lot of gaps (e.g. how the "Paragraph" and "Line" config settings work).

I am trying this with MUD2 (from the MUD list).

Also, how do you handle rooms where the exits don't line up? E.g. I go West from the "Flower Garden" I get to "Cliff", but there's no exit back from "Cliff" - East goes to the room just North of "Flower Garden". I was able to fix this quite simply (made it 1-way from "Flower Garden", and moved the connector at the "Cliff" to an unused compass-point to free up the East node), but I'm just wondering how this would work when I have a 1-way path to a room where all the exits are used. So ... is there a tutorial on how to use the Mapper to get the most from it, or is it just trial'n'error?
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4689
Location: Pensacola, FL, USA

PostPosted: Wed Oct 10, 2012 2:56 pm   
 
First off, making some #TAG triggers (#HELP #TAG) will help the mapper understand your game.
#NODIR and #NOMAP come in handy as well
Remember to reconfigure after making any mapper related triggers.

As to your one way exits... go into the room properties.
There is an option on the exits tab to make an exit one way.
It effectively removes all trace of an exit from the destination room.
But as for the 'connecter' as you put it, the code really doesnt care if 50 rooms all enter another room from the east or not.
It only cares if you have more than one exit going out from the same direction.
_________________
Discord: Shalimarwildcat
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Wed Oct 10, 2012 5:19 pm   
 
I can only share what worked for me and that does not mean that it will work for you because the mapper seems to be dependent on what type of Mud that you connect too.

That being said...call this my newbie guide to the Automapper.


1. Click the Automapper icon, create a new database and name the database, preferable after the land mass in your Mud.

2. Click ZONE/RENAME and title this the zone of which you are about to start mapping.

3. Click CONFIG/NEW CONFIGURATION. Run through this wizard and see how much it actually matches with what you Mud delivers. In my case it was nothing.

4. If like in my case work out your Room Names with Triggers. The Room Name needs to be assigned to a variable like RoomName, then it has to be tagged.
a. #TAG name @RoomName

5. Do the same for the description. I used RoomDesc for my variable. Now in my case the description was on several !word wrap lines, so I devised a trigger to concatenate these into a variable. Then when the exits line showed up I tagged them.
a. #TAG desc @RoomDesc

6. Now the exits. Not sure if what I am about to say runs across the board for everyone, but for me the exits had to follow this string formatting:
"North South East West Up Down"
So if I was in a room that only had exits leading north, west, and up the string would look like "North West Up". After building the string tag it.
a. I had used my prompt and set a condition that the RoomExits variable was not %null, and to execute this line I used #TAG exit @RoomExit
b. This is also were I put my #OK. This is necessary when following the map created.

7. The prompt had to be identified, so also while I was coding the exit Tag, I added the line #TAG prompt

8. For any movement FAILS such as when you attempt to move in the wrong direction, #TRIGGER this and code as #NODIR

9. For everything else use #NOMAP this was done with a #TRIGGER {*} {#NOMAP}

10. Click CONFIG/RECONFIGURE to make sure that everything is matching based on the #TAGs that were created.

11. DOORS: The doors were tricky for me. When ever I came across a door it would be marked [CLOSED], not showing what type of door it was. I figured out that I could LOOK in that direction and it would tell me the information I needed. So if I came to an Exit marked "East - [CLOSED]" I triggered it to "LOOK EAST." The Mud would then say "The Doors are closed." or "The Gate is closed."

Using that information I designed the following code:

#TRIGGER {The (%w) {is|are} closed.} {#DOOR %item(@DoorDir, 1) %1;#DELNITEM DoorDir 1}

Yes, I also needed to record what direction I looked to match up with which door in case I came to a passage with several closed doors around me.

OTHER NOTES:
1. As far as I know there is no method of coding a LOCKED DOOR.
2. If anything doesn't match, say the room name, the description, or the exits, then the Automapper is going to create a new room, even if it is on top of a room that you just got through creating.
3. Try to stay away from using %roomname, %roomexit, and %roomdesc. These will interfere with the Automappers intended design functions.
4. Use "AutoMapper" as the class. Then when you hit the RED X to turn the Automapper off it will disable this class.

Once I had the above worked out, I just added a blank room to the zone, set it as my current position and used the arrow keys to move around and create the map.

One final tip that I can give is to colorize your rooms as you go. This way if the Automapper decides to go haywire (mostly cause I fled from a mob or something else that I had to focus my attention too) and started creating rooms that don't relate to the area, it is easy to pick them out and delete them. This also helps if you have your mapping setting turned on to edit instead of follow and decide to leave the zone...I looked up not paying attention after starting up CMud on time and had about 50 new rooms created in a zone I had already finished making. It was so easy to fix because I had done this that I was back to normal with in a minutes time.

I hope this was helpful as I had to shave my head to cover up the places where I pulled my hair out trying to figure this out.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829

Last edited by meddlesome on Fri Oct 12, 2012 6:31 am; edited 3 times in total
Reply with quote
Amorelia
Beginner


Joined: 09 Oct 2012
Posts: 18

PostPosted: Wed Oct 10, 2012 5:32 pm   
 
Hmm. Maybe the Reconfigure is where I'm going wrong. Does this mean to rerun the Automapper Setup Wizard (which says "go to a safe place where you are able to go South")? I run this just once, because I'm having to fix the settings each time I run it.

I have created a couple of door triggers (e.g. #TRIGGER {The door is shut} {%DOOR %lastdir;%NODIR} ). So am I screwing it up by not rerunning the Wizard? AFAIK my triggers aren't actually changing how the Automapper config settings should be.

Thanks for the input.
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Wed Oct 10, 2012 5:39 pm   
 
First check the CONFIG/NEW CONFIGURATION and see that it matches. Does that look like the Room Name? Is that the actual Description of the room, or does something need to go? Are those Exits colored Red? I think it's red, but if any of this doesn't match then use #TAG in a trigger to force it to match. Then YES, run the CONFIG/RECONFIGURE again to see that it does match and you should be good to go. And yes that is the Wizard that you are talking about.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Wed Oct 10, 2012 5:44 pm   
 
And I would not worry about fine tuning the settings until you get to step 10. It's just a waste of time.

That is CONFIG/CONFIGURATION SETTINGS. If you are using #TAGs most of this would be ignored. You might need to change the Strings a bit, but I wouldn't change anything that addresses the Room Name, Description, or Exits if you have them #TAG'd.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4689
Location: Pensacola, FL, USA

PostPosted: Wed Oct 10, 2012 6:09 pm   
 
you only need to reconfigure if your trigger makes use of #TAG, #OK, or #NOMAP, for the most part.

and its #NODIR, not with a %
_________________
Discord: Shalimarwildcat
Reply with quote
Amorelia
Beginner


Joined: 09 Oct 2012
Posts: 18

PostPosted: Wed Oct 10, 2012 6:45 pm   
 
Thanks for all the input. I will have another go tonight - seems that #TAG is a big deal, and I created none of those.

Yes, I can see me investing in a wig - I already crashed the database a couple of times, had only mapped a dozen rooms.

Basically, the syntax from the MUD I'm on is:

<direction> <-- the MUD echo’s back each command entered
<Room name>. <-- always ending in .
<Description> <--- 1 or more lines of description.
<Description> <--- 1 or more lines of description.
<Description> <--- 1 or more lines of description.
<Object> < --- if any objects are in the room, they are listed here
<exit> : <Room name> < --- (or “It’s dark” for dark rooms); : separator
<exit> : <Room name> < --- (or “It’s dark” for dark rooms); : separator
<exit> : <Room name> < --- (or “It’s dark” for dark rooms); : separator
* <---- prompt
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Wed Oct 10, 2012 7:03 pm   
 
I forgot to mention the #OK. That is needed if you ever want to follow the map successfully. I modified my guide up above to include where I used it.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829

Last edited by meddlesome on Wed Oct 10, 2012 8:14 pm; edited 1 time in total
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4689
Location: Pensacola, FL, USA

PostPosted: Wed Oct 10, 2012 7:16 pm   
 
i like to use #OK on the exit line, or darkness/snow blind/etc. Basically it just says 'i made it'
usually that is enough by itself for most MUDs for the mapper to figure out the rest...
i actually have only had to use #TAG on one of the games i used to play.

#NODIR is the opposite of #OK, and it probably shows up in more of my triggers than any other map command
It is used to keep the #LOCation object current and following along on the map, so you know where you are.
_________________
Discord: Shalimarwildcat
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Wed Oct 10, 2012 8:10 pm   
 
In my case I have it inside the condition, so it only fires if the condition is met. It is preferred to be placed at the exits line. There are however times when on the Mud I play that I can enter a room that displays no exits which gives me no exit line even though I will have all four of the horizontal exits available.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829
Reply with quote
Amorelia
Beginner


Joined: 09 Oct 2012
Posts: 18

PostPosted: Fri Oct 12, 2012 5:56 am   
 
meddlesome wrote:

5. Do the same for the description. I used RoomDesc for my variable. Now in my case the description was on several !word wrap lines, so I devised a trigger to concatenate these into a variable. Then when the exits line showed up I tagged them.
a. #TAG desc @RoomDesc


Ok I think I have it working, except for the room description. I also have several lines of room description (separated by crlf), and basically want it to treat all lines between the Name and Exit tags as Desc.

So for item 5 in the list, how do we handle the concatenation?
Reply with quote
meddlesome
Wanderer


Joined: 24 Aug 2012
Posts: 70

PostPosted: Fri Oct 12, 2012 6:13 am   
 
Here's how I did it, and again, not sure that it will work 100% for you, but may give you an idea on how to go about it.

It was pretty obvious to me that the description is between RoomName and RoomExits...

I created a class call DESCRIPTION and set the RoomName trigger to Enable that class like so:

#T+ DESCRIPTION

In the description class I have a trigger that captures everything.

#TRIGGER {(%*)} {#VARIABLE RoomDesc {@RoomDesc %stripansi(%1)}}

Just so you know, I don't use %concat as I feel it is just about as useless as a spatula with a broken handle.

Then when I get to the exits Trigger I disable the Description class and tag the description

#T- DESCRIPTION;#TAG desc @RoomDesc

The only draw back to this is that if there is a Mob or something else that is not standard to the room such as storm noise or a chat comes through, it gets captured as well.
To avoid this I used ANSI coloring in my trigger. I don't know that your description is an ansi color or not, but you may want to set that as well to avoid some of the garbage.
_________________
Intel Core 2 Quad Q9450 @2.66GHz
MDAC 2.8 SP1 ON WINDOWS XP SP3
Msjet40.dll ver 4.0.9511.0 + Security Bulletin MS08-028
CMUD v237
Order number: **7829
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net