[MUD-Dev] Autogenerating maps from muds using cardinal directions for exits?
J C Lawrence
claw at varesearch.com
Tue May 11 16:21:39 CEST 1999
On Sun, 09 May 1999 15:20:43 -0700
Ben Greear <greear at cyberhighway.net> wrote:
> Mik Clarke wrote:
>> Really, a Mud with non-directed exits? In mine (and all others
>> I've seen)exits go from one room to another. Normally there will
>> be another exit coming back in the same direction to give the
>> illusion of a bi-directional exit, but in practice it's two
>> directional ones working together.
> I was talking more about the nature of the graph that might be
> produced. Now that I think about it, I might have completely
> mis-used the phrase anyway :)
In a long prior life I hacked a tool to build maps from telnet game
logs. The algorithm was simple:
1) Pull out all command lines which contain a directional command
(U/D/N/NE/E/SE/S/SW/W/NW) and the next line of output (the room
desciption of the room moved to).
2) Trim out all error/"You can't do that" entries.
3) Assume that all motions are symmetric (ie motion X followed by
motion -X returns to the starting location). ie Assume that all
rooms with the same names reached by reciprocal motions are in fact
the same rooms.
4) Build a graph of nodes representing thr trimmed log (just walk
down the log, adding nodes as new locations are found).
5) In the case that a reverse direction not being symmetric,
branch (I then fixed such by hand later).
5) Print.
Somewhere I have maps I did of Shades this way. An hour or so spent
with any decent scripting language should do it, more if you decide
to get clever about branch recognition and folding (ie traceback on
the current line of motion and attempt to fold the current branch
back into the trunk).
--
J C Lawrence Home: claw at kanga.nu
---------(*) Linux/IA64 - Work: claw at varesearch.com
... Beware of cromagnons wearing chewing gum and palm pilots ...
_______________________________________________
MUD-Dev maillist - MUD-Dev at kanga.nu
http://www.kanga.nu/lists/listinfo/mud-dev
More information about the mud-dev-archive
mailing list