Greetings, On Mon, Nov 13, 2000 at 09:26:51AM -0600, Lewis, Jason wrote: > I am working on a introduction code snip for Circle and need some opinions. > > First, Would a linked list be the best way to do this? > > struct have_met { > > int known; > struct have_met *next; > struct have_met *prev; > } > > kinda thing or is there a more memory efficient way? I'd personally go for a tree-structure for faster lookups, simply because if you e.g. consider gossip and you have 50 players online, the name needs to be looked up in 50 individual dbs, where each may have like 1000-2000 entries. Also consider, that if a player deletes, the db needs to be updated, otherwise you have endless growing dbs, making a list-like structure even worse. Another point to consider is the size of the playerfile which will increase with each name added to the database. Because of this complexity alone and because such a system hinders social bonds in a MUD, I personally dislike these systems at all. > > Second I will be adding these commands > > greet <race/sex> > > introduce <char> <vict> (will add names to both victim and char's database > "for lac of a better term")(The person doing the introduction must have both > characters in their database) > > describe <char> <vict> (will add char's name to vict's database without char > being in the room) > > can anyone think of any other commands that would help make this easier to > understand for the players? > forget <name>, to manually delete names from the db. > Also one I finish this code I will post it to Ceramic Mouse with credit > given to any who help me and no liscense. > - Chris -- Christian Loth Coder of 'Project Gidayu' Computer Science Student, University of Dortmund chris@gidayu.mud.de - http://gidayu.mud.de +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/11/01 PDT