[MUD-Dev] Room-based vs. coordinate-based
clawrenc at cup.hp.com
clawrenc at cup.hp.com
Wed Jun 4 09:24:48 CEST 1997
In <9706031521.83rl at ami-cg.GraySage.Edmonton.AB.CA>, on 06/03/97
at 08:35 AM, cg at ami-cg.GraySage.Edmonton.AB.CA (Chris Gray) said:
>My surface thinking on this has been that a given set of co-ordinates
>will define a room, and that within that room things are room-based.
>The coords could also define a building of several rooms, etc. This
>is sort of a cop-out on my part, but it seems to be a way to get some
>of the advantages of both systems. If I can get some of the
>advantages of the coord system without having to do all of the
>proximity stuff for all of the commands, I'll take that cheat!
The approach which I'm currently moving towards is somewhat related to
this:
The entire world lies within a single coordinate system (32bit cube).
Domains within that global coordinate system are marked off as being
"units". A domain is defined as a 3D space as deliniated by a matrix
of coordinates. Typically this means a cuboid space (eg a rectangular
building).
Each domain is associated with a unique key value.
There is no requirement for a domain to consist of only one lump. A
domain can be two or more seperate "lumps" widely seperated in the
global coordinate system. Such lumps are linked by having a common
key.
A domain may elect to define a new coordinate system for its contents.
Again this is a 32bit cube, and a defined point within the boundaries
of the domain is defined as the origin of the new coordinate system.
Given a domain which consists of several distinct lumps, the
coordinate system ignores the "space" between the lumps. ie the space
between the lumps as defined by the containing coordinate system is
treated as of zero size.
eg
+------------------------------------------+
| Global coordinate system |
| +-----------+ +-----------+ |
| | Domain #1 | | Domain #1 | |
| | Lump #1 | | Lump #2 | |
| | | | | |
| | Origin | | | |
| |/ X| |Y | |
| +-----------+ +-----------+ |
+------------------------------------------+
\
Origin
The points 'X' and 'Y' in the above diagram when viewed by the Domain
#1 coordinate system are considered to be seperated by no space. This
of course gets more interesting with tessellated shapes. Consider:
+----------------------------+
| Global coordinate system |
| |
| DDDD DDDD |
| DDDD DDDD |
| DDDD DDDD |
| DDDX YDDD |
| DDDA DDDDDDDDDD BDDD |
| DDDD DDDDDDDDDD DDDD |
| DDDD DDDD DDDD |
| DDDDDDDD DDDD |
| DDDDDDDD DDDD |
+----------------------------+
Where the D's mark of a single domain. The points 'X' and 'Y' are
immediately adjacent, but the points 'A' and 'B' are seperated by
significant distance due to the intervening lump.
Just to add detail, domains may be nested meaning that they exist
within the coordinate space of their enclosing domain. I don't allow
the lumps comprising a domain to exist at different nesting levels.
All the lumps of a domain must be defined within the same coordinate
system, tho I do allow multiple domains to overlap the same space in
the enclosing domain.
Note: A specific requirement of this entire system was to be able to
model the Tardis, the Blue Grass Path, and Vance's Big Planet (* see
note below) as well as more mundane geometric systems.
Typically a single building of many rooms or a similar construction
would define a domain. Fancy rooms or room aggregates could define a
domain consisting of multiple lumps.
A room is defined as a space which a "normal" player character can
perceive the entirety of to an adequate level of resolution without
undue action.
Rooms define their internal size and scope via coordinate points
defined in their domain's coordinate system. Thus a room may span
multiple lumps of its domain such that an exit at one end of the room
may pop out at one end of the land, and the exit at the other end of
the room, a mere three steps away from the first, may pop out at the
other end.
(*) I'm not sure if I mean Big Planet here. I'm trying to recall the
SF book in which the native fauna of the planet had mastered the
ability to connect disperate spaces without intervening dimension. eg
a loop, passing thru which results in being somewhere else totally,
but passing around has no unusual effect. The neat thing here was
structures such as animals which would have a sessile portion
containing the brain, stomache and other key organs located in a
"safe" place, and the "eating" portions being mobile with spatial
links back to the stomach piece. Thus the eater half could wander
around in great danger and eat, have sex etc, with all the food
passing back to the hidden stomache miles away. Plants did the same
thing to gather precious resources far from where they wished to live
(eg liquid water not generally avilable in parched deserts).
Conservation of energy laws *were* observed BTW.
--
J C Lawrence Internet: claw at null.net
(Contractor) Internet: coder at ibm.net
---------------(*) Internet: clawrenc at cup.hp.com
...Honorary Member Clan McFUD -- Teamer's Avenging Monolith...
More information about the mud-dev-archive
mailing list