[MUD-Dev] Room-based vs. coordinate-based

clawrenc at cup.hp.com clawrenc at cup.hp.com
Mon Jun 30 15:59:47 CEST 1997


In <33b33947.521449955 at neptune>, on 06/23/97 
   at 08:52 AM, alexo at bigfoot.com (Alex Oren) said:


>Which brings me back to the topic.

>How would I implement the equivalent of room-spoofs in a
>coordinate-based setting?

If you recall the blurb I gave a while ago on coordinate systems and
domains within domains, my intention is to have each sub-domain be
faked out within the DB as a "room", and to then have the room be
spoofed as per normal.

For those that weren't here for the domain posting:

--<cut>--
From: clawrenc at hpuxps.cup.hp.com
To: mud-dev at null.net
Subject: [MUD-Dev] Room-based vs. coordinate-based

--<...deletia...>--

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.

--<...Notes on Big Planet deleted...>--

--<cut>--

--
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