[MUD-Dev] Naming and Directories?

Mark Gritter mark at erdos.Stanford.EDU
Thu Mar 11 23:44:08 New Zealand Daylight Time 1999

In MUDs I'm familiar with, directories seem to be done in a very ad-hoc 
fashion.  Objects may have no name associated with them at all, or a
name can be discovered only by exhaustive search.

Dikus are a partiularly bad example here.  Doing a "tell" may involve 
scanning the entire list of online players.  Objects (I mean driver-level
objects including mobs and items) are named only by their location in memory; 
object prototypes have essentially meaningless integer IDs.

There might be some benefit it doing naming explicitly rather than implicitly.
Has anyone had experience with a more structured approach to using directories
in a MUD?  

One obvious benefit would seem to be in persistence--- having a "database" 
of objects rather than just a collection makes them easier
to manage.  (Now that I think more about it, ColdC seems like a good
example, but IIRC, object names are just opaque identifiers.)

A directory of all objects seems particularly useful for administration and 
debugging.  It would be easier to perform searches on the objects in the
game, or identify "problem" objects while debugging.

It might also be useful for implementing communication between NPCs and
NPC memory by providing a basis for identifying entities.  For example, 
information about both specific objects (the sword 'GeekKiller') and classes 
of objects (a longsword) could be tagged using a name recognized using the 
directory service.  This seems preferable to passing pointers around,
anyway.  :)

A potential drawback I see is increased memory usage (perhaps prohibitely
so.)  Benefits to CPU time by doing "smarter" lookups are probably not likely 
to be a big win.

Mark Gritter
mgritter at cs.stanford.edu

MUD-Dev maillist  -  MUD-Dev at kanga.nu

More information about the MUD-Dev mailing list