Skip to content

Components

Jan Sandström edited this page Apr 28, 2020 · 3 revisions

Components are stored in maps/components.

All components have a mask which defines it's size and whether or not it can be put in front of a door.

There is no limit to how many components or variants of components there can be, making it a good place to contribute. If you want to design components, please read the component design guidelines guidelines first.

Added components are subject to Component review. Save time by doing this yourself as well.

File names

All file names must be lower-case.

Component file names have these sections:

  • type (obstacle_[item], puzzle, filler etc.)
  • mask
  • direction (n, s, e, w or any combination thereof. Only obstacles have directions)
  • number (n, to make components unique, could be anything really to distinguish it)

Variations may apply, see each component type article for details.

Helper scripts

All component map scripts have a short code snippet which includes a helper script. This script includes enemies and any component type specific features. See the details documentation on any component type for more info.

Placeholders

A placeholder is a dynamic tiled placed to tell the helper script where to put chests, stones, enemies etc., as some entities can not always placed directly in the mas as chest content, enemy type, stone sprite etc. depends on context (tier, tileset etc.).

There are placeholder tiles for all uses in all tilesets. Placeholders must be named properly for the helper scripts to access them, some strictly and some prefixed, see each component type documentation for details.

All components are candidates for enemy placement. See enemy for details.

Component types

Doors

All rooms are connected by doors.

Treasures

Treasures come in chests, large and small.

Treasures can also be put in obstacles.

Obstacles

Obstacle components are designed in a way that only allows progress if a the player has acquired a specific item.

There are some tiered items for which a high level item overcomes a low level item obstacle. Namely:

  • Silver and gold glove (not implemented)
  • Lamp and fire rod (not implemented)

Read more: obstacles

Fillers

Fillers are called last to fill the room with various cosmetic elements. Puzzles can be placed as fillers if called without a treasure

Read more: filler

Puzzles

Puzzle components requires a solution to give a reward. Typically a switch hidden under a pot or a block needs to be pushed to show a chest or open one or more doors.

Read more: obstacle_puzzle

Clone this wiki locally