MAHK 7/27/98

# Mission-Specific Data Resources

Here's stuff you need to know as an artist or designer to get various mission-specific data mojo going in dark.

## Setting Up Your Level

The Mission Parameters dialog will have an entry called Dark Mission Description. Before you can have any mission-specific data you need to set these parameters correctly:

- Mission Number should be your integer mission number.
- Mission Pathname should be an 8-character pathname. It is the directory where your mission specific art and text will live. It is generally a subdir under `art\finals\intrface`, but it could be other places as well.

## Mission Goals

A mission can have any number of goals. They are numbered, starting with 0. Goals will appear on the various goal displays in numerical order.

### Quest Variables

For each goal in your mission, the following mission quest variables must be defined:

- `GOAL_STATE_`N
  - 0 = Incomplete
  - 1 = Complete
  - 2 = Inactive
  - 3 = Failed
- `GOAL_VISIBLE_`N: Whether this goal is displayed on the objectives screen and other places.

To create a mission quest variable, use the command `quest_create_mis` variable`,`value. Goal quest variables must be numbered consecutively starting at zero. If you skip a number, then later numbers will be ignored.

### Text Strings

The file `art\finals\`pathname`\goals.str` contains the text for all the goals. Each goal has two descriptions, a short game description that is seen during the game, and a longer fiction description that is seen in the briefing summary. Here's a sample string file:

    // Goal #0
    fiction_0: "You hate the guy.  You must kill him"  // fiction description
    text_0: "Kill the Guy"  // short description

    // goal #1
    fiction_1: "You must complete the ritual of self-sacrifice, which can only be performed by drowning in the pool."
    text_1: "Drown to Death"

## Maps

### Setting up your page range.

Two mission quest variables control the range of automap page numbers. They are `MAP_MIN_PAGE` and `MAP_MAX_PAGE`. The page range is inclusive. You can change these variables on the fly to hide or reveal map pages.

### Art Needs

Each page has a piece of "background art" and a number of "decals." Each room the the room database specifies which decal it uses, and on which page, according to its "automap" property. When the automap is drawn, the decal that represents the player's current room is pasted onto the automap.

#### Backgrounds

- The background art must fit inside the "automap frame" found in `art\finals\intrface\map.pcx`
- Put the background art for each page in `art\finals\intrface\`pathname`\pageNNN.pcx`, where `NNN` is the page number, padded with zeroes (e.g. `001`, `002`, etc.).

#### Decals

Artists should take the "background art" and mark it up with all the decals you want to exist.

- It's ok to put them in the same file, or in multiple files.
- Pink-box the decals and put them in `art\src\`pathname.
- You may discover you need multiple files per map page in order to keep your pink-boxes from overlapping.
- Name the decal files `pNNNrX.pcx` where `NNN` is the page number and `X` is a letter of the alphabet, starting with "A" (e.g. p001ra.pcx, p001rb.pcx, etc. ).
- For each page, run:
  `makerect pNNNra.pcx pNNNrb.pcx` ... `pNNNrc.pcx`
  This will create the file "pNNNra.bin". Copy it to `art\finals\`pathname.
- For each page, run:
  `cutout pNNNra.pcx pNNNrb.pcx` ... `pNNNrc.pcx`
  This will create several "pNNNrXXX.pcx" files. Copy them to `art\finals\`pathname.

#### Properties

In the mission, set the automap property for the rooms that want decals. The location should specify the decal number. Decals are ordered primarily by which decal file they come from. Within a file, decals are ordered according to the top-left corner of their bounding boxes.