Minimap Reference
The Minimap is a HUD feature that always displays the surrounding map centered on the PC on the game screen. It works both for 2D maps and 3D Dungeons. This chapter explains what the Minimap is composed of and how to configure it.
Intended audience
- Those who want to introduce the Minimap in a dungeon exploration game
- Those who want to customize the Minimap chip images
- Those who want to display object markers (stairs, treasure chests, etc.)
Overview
Features
- Atlas-based: Multiple chips are cut out from a single image for drawing (fast)
- Surrounding 4-direction detection: Terrain chips are automatically selected based on wall patterns seen from the current cell
- PC center-fixed: The PC marker is always at the center of the window; the surroundings scroll
- Exploration management: Only passed cells show terrain; unexplored cells are filled
- Object markers: Stairs, chests, etc., are displayed via category keys
- 2D / 3D common: The same 2D top-down Minimap works for both 2D maps and 3D Dungeons
Component elements
| Element | Role | File |
|---|---|---|
| Atlas image | Image combining all chips into one | data/sprites/minimapchips/*.png |
| Minimap settings | Atlas path, chip size, exploration detection | data/settings/minimap_settings.json |
| Category mapping | Object category key → chip index | data/settings/minimap_categories.json |
| Settings tab | GUI editing screen for users | Editor: Minimap |
| 4 Event Contents | Display control, exploration operations | Individual Event Contents |
| HUD node | Performs the actual drawing | runtime/minimap_hud.gd |
Chip atlas
Layout rules
- Horizontal single row (Y=0 fixed, vertical direction is 1 chip only)
- Each chip is in principle square (chip_size_x == chip_size_y recommended)
- No gaps between chips (chip at index N is placed from
(N * chip_size_x, 0))
Sample atlas
The minimap_01_1536_32_s3.png bundled with this tool contains 48 chips of 96×96 each (index 0-47). Indices 0-17 are tool-fixed; 18 onwards is the user-defined area.
Fixed chips (index 0-17)
Chips used fixed by the tool. The in-image artwork can be changed, but the meaning cannot.
index 0: PC arrow marker
- Always drawn at the center of the Minimap window
- Auto-rotates according to
pc_facing(up=0° / right=90° / down=180° / left=-90°) - Recommended: Upward arrow, triangle, face icon, etc.
index 1: Unexplored chip
- Used for all of: unexplored cells, out-of-map range, impassable, and terrain drawing skip
- Recommended: Dark solid (DRPG standard) or semi-transparent grid
- Role of filling "invisible cells"
index 2-17: 16 terrain patterns
For passable cells (passable=0), the wall pattern of the surrounding 4 directions seen from the current cell is expressed in 16 patterns. This tool automatically determines the presence of walls and selects the appropriate index.
| index | Meaning | Wall directions |
|---|---|---|
| 2 | Passable in all 4 directions (passage intersection) | — |
| 3 | Wall on left only | ← |
| 4 | Wall on top only | ↑ |
| 5 | Wall on right only | → |
| 6 | Wall on bottom only | ↓ |
| 7 | Left+top (northwest corner) | ←↑ |
| 8 | Left+right (vertical passage) | ←→ |
| 9 | Left+bottom (southwest corner) | ←↓ |
| 10 | Top+right (northeast corner) | ↑→ |
| 11 | Top+bottom (horizontal passage) | ↑↓ |
| 12 | Right+bottom (southeast corner) | →↓ |
| 13 | Left+top+right (southward dead end) | ←↑→ |
| 14 | Left+top+bottom (eastward dead end) | ←↑↓ |
| 15 | Top+right+bottom (westward dead end) | ↑→↓ |
| 16 | Left+right+bottom (northward dead end) | ←→↓ |
| 17 | 4-side wall (isolated cell) | ←↑→↓ |
Drawing the images
Of the 4 sides around each chip, draw a thin white line or thick line on the side with the wall. Making the passable side blank makes the connection with adjacent chips natural.
User-defined chips (index 18+)
18 onwards is a range users can freely add. Used for object markers (stairs, chests, NPCs, etc.).
Typical uses
- Stairs (up / down)
- Doors
- Treasure chests
- NPCs
- Enemies
- Important points
Drawing the images
- Chips at 18+ are free design (stairs / chests / colored symbols, etc.)
- Adding a semi-transparent background color improves visibility over terrain chips
- The sample image contains "!" mark variations in 30+ colors
Object marker mechanism (minimap_category)
To display objects placed on the map (NPCs, chests, stairs, etc.) on the Minimap, use the correspondence of category key → chip index.
1. Set the category key on the object template
In Editor: Object, set any string (e.g., stairs, chest, npc) in the minimap_category property of each object template.
2. Determine the chip index with the category mapping
In Editor: Minimap, define the correspondence between category keys and chip indices:
{
"default": 21,
"upstairs": 20,
"downstairs": 19,
"door": 18,
"chest": 22
}3. Automatic drawing at game startup
Objects placed on the map are drawn on the Minimap with the chip corresponding to minimap_category.
Required entry "default"
Always register the "default" key. If an object's minimap_category is an empty string, the tool falls back to "default".
Keys not in the mapping are not drawn
Even for a template with minimap_category = "stairs", if "stairs" is not in the mapping, it won't show on the Minimap. Don't forget to update the mapping when adding.
6 exploration patterns
When the PC walks the map, you can choose what range of cells to record as "explored". Choose from A-F in "Exploration Range Pattern" of Editor: Minimap.
Pattern list
How to read the diagram
P = PC position, ■ = cells recorded as explored, ・ = cells not recorded. Facing is assumed to be up.
A: Foot only (1 cell) — Default
・・・
・P・
・・・Record only the cell the PC stands on. Maximum sense of exploration; most classic.
B: Foot + 1 step forward (2 cells)
・■・
・P・
・・・PC + 1 cell ahead in facing direction. "Seen" cells are also treated as explored.
C: Foot + cross (5 cells)
・■・
■P■
・■・PC + 4 cells up/down/left/right. Cross range regardless of facing direction.
D: Foot + surrounding 3×3 (9 cells)
■■■
■P■
■■■All 3×3 centered on PC. Most lenient, player-friendly.
E: Foot + 3 cells forward (4 cells)
■■■
・P・
・・・PC + 3×1 band in front in facing direction. Records "the line of sight."
F: Foot + forward fan (6 cells)
PC + wide fan in facing direction. Wider range combining patterns A+B+C+E.
Which pattern to choose
| Use | Recommended |
|---|---|
| Traditional DRPG (Wizardry-style) | A (foot only) |
| Modern DRPG (Etrian Odyssey-style) | B / E (forward priority) |
| Casual, beginner-friendly | D (full 3×3) |
| 2D top-down game | C (cross) or D (3×3) |
Minimap display control (Event Contents)
Detailed explanations are in the individual Event Content pages, but there are 4 types of Event Contents related to the Minimap.
Show Minimap
- Display ON + change position / size / view cell count
- Properties left blank retain current state (partial update)
Hide Minimap
- Display OFF (settings retained)
- Completely dormant while hidden (zero load)
Mark Map All Explored
- Mark all passable cells of the specified map as explored
- Used for implementing "map item effect"
Clear Map Explored
- Delete all exploration info of the specified map
- Used for New Game+ etc.
Screen position and size
The following can be changed via Show Minimap:
| Property | Content | Default |
|---|---|---|
| Position X / Y | Margin from screen bottom-right (px) | 8 / 8 |
| Size X / Y | Window size (px) | 176 / 176 |
| View cell count X / Y | How many cells are shown | 9 / 9 |
The drawing size per cell is auto-calculated as "size ÷ view cell count."
Performance
Zero load in 2D
When the Minimap is hidden (minimap_visible=false), both drawing and _process completely stop (process_mode=DISABLED). The design ensures "no impact on games that don't use the Minimap."
Drawing happens only on redraw trigger
The Minimap is not redrawn every frame; _draw() runs only at the following timings:
- The moment the PC cell or facing changes
- The moment display settings change (size, view, etc.)
- Immediately after save data restoration
Thanks to this, CPU load is kept minimal even while the Minimap is displayed.
Limitations and pitfalls
Atlas image and size specification required
Before using this feature, if the following are not set in Editor: Minimap, it won't draw correctly:
- Atlas image (chip_texture)
- Chip size (chip_size_x / chip_size_y)
- Category mapping (including
"default"of minimap_categories)
If the Minimap goes pitch black, first check these.
The meaning of fixed indices cannot be changed
The meaning of indices 0-17 is tool-fixed. The in-image artwork can be changed, but redefining like "use index 0 for a chest" is not possible.
Do not delete the "default" key
If you delete the "default" key in the category mapping, objects whose minimap_category is an empty string won't be drawn. Do not delete it.
Even during 3D Dungeon, 2D top-down Minimap
Even during 3D Dungeon mode, the Minimap is always shown in 2D top-down view. A "3D-dedicated solid Minimap" is not supported by the tool's specification.
Cannot have different Minimap displays per map
The Minimap's position / size / view settings are common to all maps (but can be dynamically changed via Show Minimap). Switch by calling Show Minimap on each map-switch event.
Image filter is fixed to Nearest
Minimap chips assume pixel-art atlases; texture_filter is forced to Nearest. "Smooth Minimap with anti-aliasing" is not possible.
Exploration info is independent per map
Exploration info (save_data.world.explored) is saved keyed by the tilemap's path. Walking the same cell coordinates on a different map is treated as a different map, so exploration info does not interfere.
Z-index is tool-fixed
The Minimap is drawn at Z-index=300, so it's placed above normal HUD (images, text) and below battle windows. There is no means to change the drawing order.
Saved data
Minimap-related save data:
| Property | Content |
|---|---|
save_data.world.minimap_visible | Display ON/OFF |
save_data.world.minimap_config | Position / size / view cell count |
save_data.world.explored | Exploration info (cell dictionary per tilemap path) |
Restored in the same state after save → load.
Related Event Contents
- Show Minimap
- Hide Minimap
- Mark Map All Explored
- Clear Map Explored
- Change Map — Minimap redraw on map switch
Related pages
- Editor: Minimap — Basic Minimap settings screen
- Editor: Object —
minimap_categoryconfiguration - Editor: Map — Passability detection (criteria for walls / floors)
- 3D Dungeon Mode — Minimap is shown in 2D top-down even in 3D
- Save / Load Reference — Persistence of exploration info
