[MUD-Dev] Re: MUD Design doc (long)
J C Lawrence
claw at under.engr.sgi.com
Mon Dec 21 15:18:33 CET 1998
On Fri, 18 Dec 1998 11:18:55 -0600
Sunny Gulati<sunnywiz at radiks.net> wrote:
> Chris Gray wrote:
>> [Mik Clarke:]
>> This is what I do in my system, and it works fairly well. It is
>> also possible to write generic code that will do this with lots
>> of verbs, so the skeleton can be re-used via a function call.
Aaarrgh. Yet again the grammar threads live!
In constructing a user language for a MUD, three things need to be
resolved:
1) How does a particular object or objects are selected from the
set of possible objects in applying a user command?
2) How does an object know what verbs apply to it, and how does
that map to object inheritance?
3) Given multiple possible matching verb definitions for a given
command, which is picked and why, and how can the user specify the
definition to use?
Grammatically this resolves to:
a) How to resolve object/subject ambiguity?
b) How to resolve and construct vocabulary?
c) How to resolve definitional ambiguity?
No, I don't have what I think is an elegant solution. I don't
however think that a register/de-register model is going to hack it.
> - Every player object has a list of "verbs" that are understood,
> with a pointer to a function to call if that verb is "found".
And what happens when a single verb has multiple conflicting or
distinct definitions?
> roll stone
> roll toke
> roll eyes
How about when different definitions of the same verb apply to
different objects?
> Light fire
> Light match
How about when multiple definitions of the same verb apply to a
single object with correct selection only by context?
> ...the mind faileth me in my hour of need...
> - As the driver moves objects into other objects and stuff like
> that, it calls the init() function appropriately to add/modify the
> verblist of various interactive-capable objects.
What happens when one of these boundary ctors/dtors fails to make
the obligatory call? Is there anything to verify/enforce
correctness of the verb list, or is this a leak waiting to happen?
Note: I've had a huge problem with spoofs being leaked (ie being
created and never destroyed despite the fact that they no longer
apply) due to sloppiness/errors in my state change detections. I
don't have a resolution for the problem. Yet.
> - Note that if there were two swords, one in the environment, one
> in buffy's inventory, somehow the one in buffy's inventory ends up
> having a preference. I think its not just a list, but a list with
> built in priorities (ie, inventory is always higher than
> environment, etc etc).
I start with the character and anything deifined directly on him,
and then proceed outward to surrounding objects in order of
distance. A seperate problem of course is that characters exist in
multiple universes simultaneously (physical and spirtual) and that
locations in the physical universe are members of grouping container
objects (eg areas, realms etc) which also define verbs but without a
defined location other than "everywhere".
There are also problems in elegantly defining that a command should
apply to a distant object when there is a closer one which satisfies
the command.
--
J C Lawrence Internet: claw at kanga.nu
(Contractor) Internet: coder at kanga.nu
---------(*) Internet: claw at under.engr.sgi.com
...Honorary Member of Clan McFud -- Teamer's Avenging Monolith...
More information about the mud-dev-archive
mailing list