<!-- MHonArc v2.4.4 --> <!--X-Subject: Re: [MUD-Dev] Rooms, 3D arrays, etc. --> <!--X-From-R13: ptNnzv-pt.UenlEntr.Sqzbagba.OP.QO (Quevf Uenl) --> <!--X-Date: from scipio.globecomm.net [207.51.48.12] by in10.ibm.net id 864799127.39156-1 Wed May 28 05:58:47 1997 CUT --> <!--X-Message-Id: 9705280654.82jw@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] Rooms, 3D arrays, etc.</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="msg00880.html">Previous</a> | <a href="msg00882.html">Next</a> ] Thread: [ <a href="msg00906.html">Previous</a> | <a href="msg00975.html">Next</a> ] Index: [ <A HREF="author.html#00881">Author</A> | <A HREF="#00881">Date</A> | <A HREF="thread.html#00881">Thread</A> ] <!--X-TopPNI-End--> <!--X-MsgBody--> <!--X-Subject-Header-Begin--> <H1>Re: [MUD-Dev] Rooms, 3D arrays, etc.</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] Rooms, 3D arrays, etc.</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>: Tue, 27 May 97 23:54:02 MST</LI> </UL> <!--X-Head-of-Message-End--> <!--X-Head-Body-Sep-Begin--> <HR> <!--X-Head-Body-Sep-End--> <!--X-Body-of-Message--> <PRE> [Raz:] [Discussion of spaces and zones] :Continuation eagerly, and hopefully, awaited =3D) OK, I'll try to dump what I can remember of my tentative plans in this realm. I want a really big world, my thinking is 2^32 x 2^32 (why not!). It would basically be a layered fractal terrain. That gives me the third dimension - calculated by the fractal generation algorithm. The way one common fractal landscape generator works is by starting with one point, wrapped as four corners of a square. At each step, you bisect each edge of your current square, average and perturb the endpoint heights, and mark the height of the middle of the edge. The middle of the square gets height from all four corners. [I've got code for this if some of you haven't seen this algorithm.] What I haven't quite figured out is how to be able to repeatably generate the height for any given co-ordinates within the world. I want to represent the world *very* sparsely, of course. So, I would divide the top level of the world (the whole 2^32 x 2^32 square) into some number of subsquares, say 16 x 16. If nothing at all had happened within one of those subsquares, then it would not exist in the DB, but would be generated as needed. The representation of a subsquare could contain a new random seed for generating that square. It could also contain an override for the height of the square, and perhaps others. We continue dividing up like this until we are down to individual locations. At the level of individual locations, we can generate a text description by scanning back up the hierarchy of squares, looking for indications of major scenery items. This would be based a lot on just the height, but can also be augmented by indications of tradewinds, distance to major bodies of water (if not easily calculatable from upper parts of the hierarchy), terrain overrides, etc. At each level, anything important, such as the height, can be overridden from what the fractal algorithm generates, and that override passes down to finer detail levels. So, store a couple overrides and you can build a higher mountain range, or a deep valley. At the single location level, you can use the normal "room" representation if you want. So, you can force the system to generate that location specifically, and it will generate all squares in the hierarchy down to that position. It will then generate the single location, and put in whatever you wanted. So, if you want location 308754,2987643 to have a funny hollow log, you just say so, and the magic happens. Similarly, if you want to build a deep, twisty canyon in the shape of your initials, then a dozen or two height overrides will probably manage it. You are going to need some fairly powerful code to examine the hierarchy around a given location in order to generate a nice description of that location (or a polygon image if you go graphics). As mentioned before, the final co-ordinates can be used to repeatably generate details such as trees, bushes, etc., which can also be overridden if wanted. If you are going full graphics, you can use fractals to generate the actual shape of nearby terrain (usual seeding, and using the height of this and neighbouring locations to start the fractals), and you will of course use the heights of nearby small terrain features and further large terrain features (accessible via the hierarchy) to make the background for the scene. That gets terrain. How about towns? Well, you have to start with some kind of street generation routine (seeded by co-ords of town of course!). Within that you have another algorithm which creates the buildings, based on location within town, a few random choices about the nature of the town, its age, etc. You will then need algorithms to generate the details of the buildings themselves (floorplan, materials, colours, contents); and then of the interior furniture, and then of the stuff in the drawers, etc. etc. Of course everything is generated as "real", and if players change something you have to keep track of the change, and perhaps at some point you just decide to permanently instantiate stuff. Whew! That would keep us all busy for a year or two! Nobody said it would be easy, but it would finally stop people like me that just want to explore everything! Uh-oh, its already past my bedtime... :-) -- 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="00890" HREF="msg00890.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong> <ul compact><li><em>From:</em> silovic#srce,hr (Miroslav Silovic)</li></ul> <li><strong><A NAME="00975" HREF="msg00975.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong> <ul compact><li><em>From:</em> clawrenc#cup,hp.com</li></ul> </UL></LI></UL> <!--X-Follow-Ups-End--> <!--X-References--> <!--X-References-End--> <!--X-BotPNI--> <UL> <LI>Prev by Date: <STRONG><A HREF="msg00880.html">Re: [MUD-Dev] Life</A></STRONG> </LI> <LI>Next by Date: <STRONG><A HREF="msg00882.html">Re: [MUD-Dev] Spoken Languages & Food [was RP thesis...]</A></STRONG> </LI> <LI>Prev by thread: <STRONG><A HREF="msg00906.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></STRONG> </LI> <LI>Next by thread: <STRONG><A HREF="msg00975.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></STRONG> </LI> <LI>Index(es): <UL> <LI><A HREF="index.html#00881"><STRONG>Date</STRONG></A></LI> <LI><A HREF="thread.html#00881"><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><A NAME="00830" HREF="msg00830.html">Re: [MUD-Dev] Internal Mud Languages</A></strong>, Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Tue 27 May 1997, 12:56 GMT <LI><strong><A NAME="00809" HREF="msg00809.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Mon 26 May 1997, 21:47 GMT <UL> <LI><strong><A NAME="00854" HREF="msg00854.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, clawrenc <a href="mailto:clawrenc#cup,hp.com">clawrenc#cup,hp.com</a>, Wed 28 May 1997, 00:56 GMT <UL> <LI><strong><A NAME="00906" HREF="msg00906.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, Caliban Tiresias Darklock <a href="mailto:caliban#darklock,com">caliban#darklock,com</a>, Thu 29 May 1997, 02:33 GMT </LI> </UL> </LI> </UL> <UL> <li><Possible follow-up(s)><br> <LI><strong><A NAME="00881" HREF="msg00881.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, Chris Gray <a href="mailto:cg#ami-cg,GraySage.Edmonton.AB.CA">cg#ami-cg,GraySage.Edmonton.AB.CA</a>, Wed 28 May 1997, 12:58 GMT <UL> <LI><strong><A NAME="00975" HREF="msg00975.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, clawrenc <a href="mailto:clawrenc#cup,hp.com">clawrenc#cup,hp.com</a>, Thu 01 Jan 1970, 10:07 GMT </LI> <LI><strong><A NAME="00890" HREF="msg00890.html">Re: [MUD-Dev] Rooms, 3D arrays, etc.</A></strong>, Miroslav Silovic <a href="mailto:silovic#srce,hr">silovic#srce,hr</a>, Wed 28 May 1997, 17:59 GMT </LI> </UL> </LI> </UL> </LI> <LI><strong><A NAME="00806" HREF="msg00806.html">Re: [MUD-Dev] Internal Mud Languages</A></strong>, Jeff Kesselman <a href="mailto:jeffk#tenetwork,com">jeffk#tenetwork,com</a>, Mon 26 May 1997, 15:00 GMT <UL> <li><Possible follow-up(s)><br> <LI><strong><A NAME="00812" HREF="msg00812.html">Re: [MUD-Dev] Internal Mud Languages</A></strong>, Jon A. Lambert <a href="mailto:jlsysinc#ix,netcom.com">jlsysinc#ix,netcom.com</a>, Mon 26 May 1997, 23:46 GMT </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>