Re: Some input needed

From: Brian Gray (mandy@NETCOM.COM)
Date: 08/22/97


On Fri, 22 Aug 1997, Franco wrote:

>   So far, the conversion of Circle to C++ is going very well, but I have
> come to the point where I would need some pro/con input from all
> of you.
>   I'm toying with the idea (very strongly toying) of putting the command
> interpreter in the creature class, and have every class that is inherited
> from this base class, mob type or player, will be able to use this virtual
> command interpreter and add commands of it's own.
>   Therefore, the commands useable for each class would differ, and
> also keep the interpreter very readable. Any ideas?

I would argue that the interpreter is specifically a player thing.  A mob
or object or anything else needs no interpreter.  It is inside the code
and can call whatever it wants with no mistakes.  Personally, I would put
it either in your player class or better yet, in your descriptor class.
After all, it is in a way a kind of input processing.
  Unless you are concerned with mobs and objects being switched into and
performing actions as if they were players.  Still, I would do the
interpreting in the descriptor and call out to members of your Thing
class which is base to objects, mobs, and players.  That way it doesn't
matter what kind of object the descriptor is connected to.  Isn't that
what late binding is all about?

 -- Brian


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST