> I apologize, I was in a bit of a hurry when I posted that. So, here's what > I want to do: Put the entire world into a multi-dimensional array (pseudo > or not). This means that I don't really know the maximum x and y values of > the world. So what I want to know is this: other than adding up all the x > or y values of all the zones what's the best way to discover the max width > and height of the MUD world? If this is unclear, just let me know. > It depends I think, on what you're trying to accomplish. If you're trying to: -take all the zones and make them coexist on a single 3-d plane. -take each zone individually and make it exist on it's own 3-d plane. - create a 'wildneress' area which is itself a 3-d plane, but only links to zones (which in themselves could be 3-d or not). One mud which was 3-d without a wildneress solved this problem pretty easily: They simply required their builders to make zones which were logically 3-d to start. Didn't require anything but watching the builders, and a description of what 'falling' did in any given room. Now, if you're linking all the zones together and using that as your 'world' you may want to realize that the connections between zones are usually several miles, compared to several feet that most rooms are. It's impossible to make a realistic scale between two zones like that, unless you standardize the room size. Still, in this case, I think it's better to coerce the building process like the paragraph above describes, than guarentee you have cross-zone accuracy. Now, if you're doing a world with links to zones, it's also pretty easy. The specifics depend on how you're reading your map in. If you're using a real picture (bmp, gif, etc), you can either hardcode the size, or simply use the format of the image itself to tell you what the x vs. y dimensions are. If you're reading numbers from a file, like the mapsnip does, you have the same sort of option - either hard code it (since you know what the map x,y is since you have to make the map) or have it grab the first line and count the number of space delineated number entries to know how many columns, and then count rows in a similar manner. In any case though, you pretty much _know_ what size your map is going to be. PjD +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/10/01 PDT