Map Extension

From LSWiki

Revision as of 16:59, 10 June 2008; Matts (Talk | contribs)
(diff) ←Older revision | Current revision | Newer revision→ (diff)
Jump to: navigation, search

Contents

Introduction

What is the map extension?

The map extension taken in the context of itself is an extension that, like any other, modifies another object to provide additional functionality beyond its normal scope. In the case of the map extension this allows a daemon (typically a control/broker daemon) to dynamically create, maintain, and facilitate the creation of an area. Where, before, this would have been done entirely by hand - coding sometimes dozens of similiar rooms and linking them all manually - the map extension allows the content developer to quickly and consistently define what their area should look like and leaves the creation of the bulk of these rooms up to the daemon.

What parts are there to the map extension?

There are numerous things that the map extension will require to function properly, other than simply attaching the extension itself to your project's control daemon. The specifics of which I will detail below, but the following items are needed to create a basic and functioning map. Keep in mind that the file names I give below are simply the 'defacto standard' that we all tend to use. These names can vary, though for consistency sake it's recommended that they do not:

  • /dat/map.conf
    • This file is where you create the ASCII-character grid representing your map, define the dimensions of your map, and define where your overlays are placed.
  • /def/map_area_*
    • The map_area definitions are used to specify the bulk of your area's content. Each definition you create will define a specific element for your map, such as 'grass', and what any room defined as 'grass' should look like and/or contain.
  • /def/map_overlay_*
    • Like map_area above map_overlay lets you define the same things, but lets you define them in the style of an overlay. What this allows you to do is to create overlapping parts on your map, such as trails, small creeks, roads, signs, or whatever you may think of.
  • /dmn/control.c
    • The control daemon is where you will actually attach the map extension and initialize it with the information it needs to find these other vital parts. The control daemon will also act as a broker daemon to collect and grant access to your definitions above.
  • /rms/Map_Area_Base.c
    • This file will be used by the map extension to generate every room it creates, so many things that are common or shared among every room in your project may be defined here.

Why should I use the map extension for creating my area?

Versitility, consistency, maintainability, flexibility, ease of use in creating massive areas on-the-fly, etc.

When should I not use the map extension for creating my area?

Never.

Personal tools