Just a bit of musing

Adam Wiggins nightfall at inficad.com
Sat Mar 8 04:17:28 CET 1997


> >...The code tends to be littered with for loops that iterate thru
> >lists (room lists, player lists, etc etc). I, among others, feel this is
> >a Bad Thing (tip o' the hat to coder@).
> 
> Yup.  I find it utterly mazing that nobody (else) has done a fully event
> driven server.  No polling loops, no list scanning, no wasted iterations. 
> Just grab the event, process what's needed, and get out.

It probablys sounds quite a bit harder than it actually is.  Implementing
it is simple, and from there things just get easier.  It's extremely
nice to be able to say, "Okay, I'll continue with this in a bit, so
toss an event on the queue..." and just exit whatever function you're
in, rather than trying to save a bunch of stuff in external variables 
somewhere and then hope that the proper function gets called again at the
right time.

> >I posit that, in general, command interpreters for muds are Bad Things.
> >The proposal runs sorta like this:
> >	The command interface to a mud can be viewed as a context free grammar.
> 
> A good MUD grammar is incredibly context sensitive.  A simple example is
> the case where the presence or proximity of an object adds verbs to the
> players.  There is no need for this crap to wander thru the global
> namespace, or even warp the general grammar.

I don't actually agree with this.  This is where you end up with things
like "push" as a social, except for one room on the entire mud where it
pushes a button.  In another room with a similar button but written by
a different person, you have to use "press."  I dislike the effect you
get from the old adventurer games of "guess the verb" - I want to know
what commands I have availible to interact with my character right from
the start.  Thus I know if I see a button in the room, I can alway use
a certain command straight off to try to push it.  If that doesn't work
it means it's not a pushable button and I can start bending my mind to think
of other things to do with it, rather then "well...lemme try 'press'...hmmm,
maybe it doesn't answer to 'button', how about 'green'?"
This is in the same category as restricting the "steal" command to only
those in the thieves' guild.  Huh?  My character can't try to steal something
from someone?  Why not?  Is he just so incredibly sheltered that he's never
heard of or even thought of trying to take something from someone without
their knowning?  Now, he'll probably fail, but this is just fine, and different
from restricting the command altogether.





More information about the mud-dev-archive mailing list