<!-- MHonArc v2.4.4 --> <!--X-Subject: Re: [MUD-Dev] Introduction --> <!--X-From-R13: ptNnzv-pt.UenlEntr.Sqzbagba.OP.QO (Quevf Uenl) --> <!--X-Date: from scipio.globecomm.net [207.51.48.12] by mx3.ibm.net id 863503162.84508-1 Tue May 13 05:59:22 1997 --> <!--X-Message-Id: 9705130210.7zua@ami-cg.GraySage.Edmonton.AB.CA --> <!--X-Content-Type: text/plain --> <!--X-Head-End--> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> <html> <head> <title>MUD-Dev message, Re: [MUD-Dev] Introduction</title> <!-- meta name="robots" content="noindex,nofollow" --> <link rev="made" href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA"> </head> <body background="/backgrounds/paperback.gif" bgcolor="#ffffff" text="#000000" link="#0000FF" alink="#FF0000" vlink="#006000"> <font size="+4" color="#804040"> <strong><em>MUD-Dev<br>mailing list archive</em></strong> </font> <br> [ <a href="../">Other Periods</a> | <a href="../../">Other mailing lists</a> | <a href="/search.php3">Search</a> ] <br clear=all><hr> <!--X-Body-Begin--> <!--X-User-Header--> <!--X-User-Header-End--> <!--X-TopPNI--> Date: [ <a href="msg00423.html">Previous</a> | <a href="msg00424.html">Next</a> ] Thread: [ <a href="msg00402.html">Previous</a> | <a href="msg00467.html">Next</a> ] Index: [ <A HREF="author.html#00425">Author</A> | <A HREF="#00425">Date</A> | <A HREF="thread.html#00425">Thread</A> ] <!--X-TopPNI-End--> <!--X-MsgBody--> <!--X-Subject-Header-Begin--> <H1>Re: [MUD-Dev] Introduction</H1> <HR> <!--X-Subject-Header-End--> <!--X-Head-of-Message--> <UL> <LI><em>To</em>: <A HREF="mailto:mud-dev#null,net">mud-dev#null,net</A></LI> <LI><em>Subject</em>: Re: [MUD-Dev] Introduction</LI> <LI><em>From</em>: <A HREF="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</A> (Chris Gray)</LI> <LI><em>Date</em>: Mon, 12 May 97 19:10:50 MST</LI> </UL> <!--X-Head-of-Message-End--> <!--X-Head-Body-Sep-Begin--> <HR> <!--X-Head-Body-Sep-End--> <!--X-Body-of-Message--> <PRE> [Miro:] :This is an expensive tradeoff, and one you want to think CAREFULLY about. :You can go for strongly-typed (i.e. all /variables/ are declared in advance, :and dynamically-typed (i.e. data keeps type-tags, and types are checked :in runtime). If you do strongly-typed language, you'll be able to compile :it to C without too much pain, and gain a lot of speed. Unfortunately, the :payoff is in the ease of programming. MUD tend to use mixed datastructures :a lot, and when you're able to just say 'this is a list' without worrying :about the types of the elements inside it (as dynamically-typed languages :allow), you can spew working code at blinding speed, and you'll also make :your hired coders much happier. Actually, I've gone somewhat futher than that. The DB is strongly typed, too. Any reference to a property on a DB entity is done in such a way that the type of the property is known, so the type of the retrieved value is known. I support lists of stuff (all the same type, as you say), and have never noticed any difficulties. Can you give me an example of where you would want to have a list of different types of things, and how you want to go about processing the list? Personally, I'd much rather work with code that wasn't "spewed at blinding speed" - it is much more likely to work properly, and to handle the inevitable exceptional cases. I think what it comes down to is the experience of the individual. Until you've tried a system that is strongly typed, but nevertheless has the flexibility of a MUD system, I doubt a proper comparison can be made. I've worked with several weakly typed systems, and am forever frustrated by their inability to detect even the most obvious of my blunders. Now, I'm on the exact opposite side of the boat in the area of objects and properties. I don't have any fixed object formats - they are all just a collection of properties, either inherited (*without* copying), or specified explicitly. (Well, there is a small base structure for an object, which I call "things" since they are used for rooms, etc. as well.) Doing this *does* cost me performance - every property reference is a scan of a small array (plus possibly following inheritance pointers), but the flexibility is tremendous. I can add a property to the system at run-time, and attach it to whatever objects I chose. It will be ignored by old code, but it works just fine with the new code it was created for, is inherited like anything else, has an appropriate default based on it type, etc. This also saves me huge amounts of DB space compared to some systems I've seen or heard about. A property needs to be present on a thing only if it is different from the default, and different from what is inherited. :> force people to pre-declare variables, so that you can access them via :> something other than their name at run-time (e.g. an offset from a :> current scope pointer, allocated on entry to the scope). : :Uhhh, why do you need that? It looks like terribly unsafe programming to me. :Remember, you'll have a lot of people coding on your MUD (at least if you :want fast development). It seems like a good idea to prevent their code :for having side-effects that are impossible to track. Huh? I don't understand what you are referring to. What is terribly unsafe programming? Perhaps you didn't follow what I was getting at. On entry to a function, an array of "values" (union of all possible types) is allocated (ignoring some optimizations), and a pointer to that array is stored in the traceback record for the call. The slots are initialized to parameter values or default values for the type of the local. During execution, a local variable is referenced by using its fixed offset into that array. Hmm. I *think* I might know what you were getting at. No, I don't mean other ways to reference locals behind the scenes - there are no pointers or "reference" types. What I was trying to say was that you don't need the name of a local to reference it at run time - the interpreted code just needs the pointer to the current traceback record, and the offset of the variable. -- Chris Gray cg#ami-cg,GraySage.Edmonton.AB.CA </PRE> <!--X-Body-of-Message-End--> <!--X-MsgBody-End--> <!--X-Follow-Ups--> <HR> <ul compact><li><strong>Follow-Ups</strong>: <ul> <li><strong><A NAME="00467" HREF="msg00467.html">Re: [MUD-Dev] Introduction</A></strong> <ul compact><li><em>From:</em> silovic#srce,hr (Miroslav Silovic)</li></ul> </UL></LI></UL> <!--X-Follow-Ups-End--> <!--X-References--> <!--X-References-End--> <!--X-BotPNI--> <UL> <LI>Prev by Date: <STRONG><A HREF="msg00423.html">Re: [MUD-Dev] Introduction</A></STRONG> </LI> <LI>Next by Date: <STRONG><A HREF="msg00424.html">Re: [MUD-Dev] Introduction</A></STRONG> </LI> <LI>Prev by thread: <STRONG><A HREF="msg00402.html">Re: [MUD-Dev] Introduction</A></STRONG> </LI> <LI>Next by thread: <STRONG><A HREF="msg00467.html">Re: [MUD-Dev] Introduction</A></STRONG> </LI> <LI>Index(es): <UL> <LI><A HREF="index.html#00425"><STRONG>Date</STRONG></A></LI> <LI><A HREF="thread.html#00425"><STRONG>Thread</STRONG></A></LI> </UL> </LI> </UL> <!--X-BotPNI-End--> <!--X-User-Footer--> <!--X-User-Footer-End--> <ul><li>Thread context: <BLOCKQUOTE><UL> <LI><STRONG>Re: [MUD-Dev] Introduction</STRONG>, <EM>(continued)</EM> <ul compact> <ul compact> <ul compact> <LI><strong><A NAME="00458" HREF="msg00458.html">Re: [MUD-Dev] Introduction</A></strong>, Ling <a href="mailto:K.L.Lo-94#student,lut.ac.uk">K.L.Lo-94#student,lut.ac.uk</a>, Wed 14 May 1997, 15:00 GMT <UL> <LI><strong><A NAME="00468" HREF="msg00468.html">Re: [MUD-Dev] Introduction</A></strong>, Dan Root <a href="mailto:dar#thekeep,org">dar#thekeep,org</a>, Wed 14 May 1997, 22:53 GMT </LI> <LI><strong><A NAME="00493" HREF="msg00493.html">Re: [MUD-Dev] Introduction</A></strong>, clawrenc <a href="mailto:clawrenc#cup,hp.com">clawrenc#cup,hp.com</a>, Fri 16 May 1997, 07:59 GMT </LI> </UL> </LI> </ul> </ul> <LI><strong><A NAME="00402" HREF="msg00402.html">Re: [MUD-Dev] Introduction</A></strong>, Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Mon 12 May 1997, 21:50 GMT </LI> <LI><strong><A NAME="00425" HREF="msg00425.html">Re: [MUD-Dev] Introduction</A></strong>, Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Tue 13 May 1997, 12:59 GMT <UL> <LI><strong><A NAME="00467" HREF="msg00467.html">Re: [MUD-Dev] Introduction</A></strong>, Miroslav Silovic <a href="mailto:silovic#srce,hr">silovic#srce,hr</a>, Wed 14 May 1997, 22:44 GMT <UL> <LI><strong><A NAME="00507" HREF="msg00507.html">Re: [MUD-Dev] Introduction</A></strong>, clawrenc <a href="mailto:clawrenc#cup,hp.com">clawrenc#cup,hp.com</a>, Sat 17 May 1997, 00:38 GMT <UL> <LI><strong><A NAME="00517" HREF="msg00517.html">Re: [MUD-Dev] Introduction</A></strong>, Miroslav Silovic <a href="mailto:silovic#srce,hr">silovic#srce,hr</a>, Sat 17 May 1997, 10:06 GMT <UL> <LI><strong><A NAME="00552" HREF="msg00552.html">Re: [MUD-Dev] Introduction</A></strong>, coder <a href="mailto:coder#ibm,net">coder#ibm,net</a>, Sun 18 May 1997, 07:43 GMT </LI> </UL> </LI> </UL> </LI> </UL> </LI> </UL> </LI> </ul> </LI> </UL></BLOCKQUOTE> </ul> <hr> <center> [ <a href="../">Other Periods</a> | <a href="../../">Other mailing lists</a> | <a href="/search.php3">Search</a> ] </center> <hr> </body> </html>