3. World/Map

3.1.1 Overview

The world will be defined as a simplified portal system consisting of groups of linked cells. Each ‘cell’ in the world will be an area where players can move. These cells will be stored in groups that are linked by shared edges called portals. Cells can be any planar polygon and are defined with both a floor a ceiling. The edges of a cell can link to N other cells. When a pair of cells share an edge any difference in Z between the connecting cells will be filled with a vertical wall of the appropriate size. Cells can optionally define flags that will not draw any wall, floor, or ceiling.

This system will allow for a clean mix of indoor/outdoor geometry and provide an efficient culling system with support for occlusion. Cells that do not draw the ceiling and some walls will show a skybox background and appear to be “outside” instead of just a large room.

Each cell or can reference a list of object instances to be placed in them. Object instances that span cell boundaries will be referenced in all cells that they are in, letting the graphics system manage the removal of duplicate drawing. Non graphic instance locations will also be stored in the cells in order to specify special locations such as player/weapon spawns, and event triggers.

The map will be stored as compressed binary data saved from the .net serialization functions. There is no need for the map format to be human readable. Tools will be used to fully edit map files.

3.1.2 Tools

A portal based map editor will be made, it will do stuff ( portal edit in GPLib is a base)