Project Files
Porymap relies on the user maintaining a certain level of integrity with their project files. This is a list of files that porymap reads from and writes to. Generally, if porymap writes to a file, it probably is not a good idea to edit yourself unless otherwise noted.
The filepath that Porymap expects for each file can be overridden on the Files
tab of Options > Project Settings
. A new path can be specified by entering it in the text box or choosing it with the button. Paths are expected to be relative to the root project folder. If no path is specified, or if the file/folder specified does not exist, then the default path will be used instead. The name of each setting in this section is listed in the table below under
Setting
.

File Name |
Read |
Write |
Setting |
Notes |
---|---|---|---|---|
data/maps/ |
yes |
yes |
|
expected folder to find/create map data |
|
yes |
yes |
|
|
|
yes |
no |
|
for finding script labels |
data/scripts/*.[inc|pory] |
yes |
no |
|
for finding script labels |
data/event_scripts.s |
no |
yes |
|
only appends new script files to end of file |
data/maps/map_groups.json |
yes |
yes |
|
for populating the map list |
data/layouts/layouts.json |
yes |
yes |
|
for populating the layout list and to know where layout data is. Files specified with |
data/layouts/ |
yes |
yes |
|
the root folder for creating new layout folders with |
src/data/tilesets/headers.h |
yes |
yes |
|
to populate the tileset list, to know where tileset data is, and to add new tileset data. |
src/data/tilesets/graphics.h |
yes |
yes |
|
to locate tileset tiles and palettes, and to add new tileset data. The source files specified here (normally, |
src/data/tilesets/metatiles.h |
yes |
yes |
|
to locate tileset metatile data, and to add new tileset data. The source files specified here (normally, |
data/tilesets/headers.inc |
yes |
yes |
|
old assembly format to use if |
data/tilesets/graphics.inc |
yes |
yes |
|
old assembly format to use if |
data/tilesets/metatiles.inc |
yes |
yes |
|
old assembly format to use if |
data/tilesets/primary/ |
yes |
yes |
|
expected folder to find/create data for primary tilesets |
data/tilesets/secondary/ |
yes |
yes |
|
expected folder to find/create data for secondary tilesets |
src/data/wild_encounters.json |
yes |
yes |
|
optional (only required to use Wild Pokémon tab) |
src/data/heal_locations.json |
yes |
yes |
|
|
src/data/object_events/object_event_graphics_info_pointers.h |
yes |
no |
|
to read |
src/data/object_events/object_event_graphics_info.h |
yes |
no |
|
to read data about how to display object event sprites |
src/data/object_events/object_event_pic_tables.h |
yes |
no |
|
to locate object event sprites using data from |
src/data/object_events/object_event_graphics.h |
yes |
no |
|
to locate object event sprites using data from |
src/data/graphics/pokemon.h |
yes |
no |
|
if |
src/data/region_map/region_map_sections.json |
yes |
yes |
|
for populating the locations list and for region map data |
src/data/region_map/porymap_config.json |
yes |
yes |
|
Porymap’s config file for the region map editor |
include/constants/global.h |
yes |
no |
|
to evaluate |
include/constants/items.h |
yes |
no |
|
to find |
include/constants/flags.h |
yes |
no |
|
to find |
include/constants/vars.h |
yes |
no |
|
to find |
include/constants/weather.h |
yes |
no |
|
to find |
include/constants/songs.h |
yes |
no |
|
to find |
include/constants/pokemon.h |
yes |
no |
|
to evaluate |
include/constants/map_types.h |
yes |
no |
|
to find |
include/constants/trainer_types.h |
yes |
no |
|
to find |
include/constants/secret_bases.h |
yes |
no |
|
to find |
include/constants/event_object_movement.h |
yes |
no |
|
to find |
include/constants/event_objects.h |
yes |
no |
|
to evaluate |
include/constants/event_bg.h |
yes |
no |
|
to find |
include/constants/metatile_labels.h |
yes |
yes |
|
to read/write metatile labels using |
include/constants/metatile_behaviors.h |
yes |
no |
|
to evaluate |
include/constants/species.h |
yes |
no |
|
to find names using |
include/global.fieldmap.h |
yes |
no |
|
to evaluate map and tileset data masks, and to read |
include/fieldmap.h |
yes |
no |
|
to evaluate a variety of tileset and map constants |
src/fieldmap.c |
yes |
no |
|
to read |
src/event_object_movement.c |
yes |
no |
|
to read |
src/wild_encounter.c |
yes |
no |
|
to evaluate |
src/pokemon_icon.c |
yes |
no |
|
to read |
graphics/pokemon/ |
yes |
no |
|
to search for Pokémon |
Identifiers
In addition to these files, there are some specific symbol and macro names that Porymap expects to find in your project. These can be overridden on the Identifiers
tab of Options > Project Settings
. The name of each setting in this section is listed in the table below under Setting
. Settings with regex
in the name support the regular expression syntax used by Qt.

Setting |
Default |
Notes |
---|---|---|
|
|
to set sprite frame for Object events based on its |
|
|
the array mapping |
|
|
to map species constants to icon images |
|
|
optionally read to get settings on |
|
|
for new tileset names and to extract base tileset names |
|
|
reserved map name to display for |
|
|
to limit total Object events |
|
|
minimum wild encounters level |
|
|
maximum wild encounters level |
|
|
this value / 16 will be the maximum encounter rate on the |
|
|
|
|
|
|
|
|
total metatiles are calculated using metatile ID mask |
|
|
|
|
|
|
|
|
to determine if triple-layer metatiles are in use. Values other than 8 or 12 are ignored |
|
|
to limit map dimensions |
|
|
to limit map dimensions |
|
|
to limit map dimensions |
|
|
optionally read to get settings on |
|
|
optionally read to get settings on |
|
|
optionally read to get settings on |
|
|
optionally read to get settings on |
|
|
optionally read to get settings on |
|
|
name used to extract setting from |
|
|
name used to extract setting from |
|
|
name used to extract setting from |
|
|
name used to extract setting from |
|
|
expected prefix for metatile label macro names |
|
|
default prefix for heal location macro names |
|
|
default prefix for layout ID names |
|
|
default prefix for map ID names |
|
|
ID name for Dynamic maps |
|
|
ID name for empty maps |
|
|
expected prefix for location macro names |
|
|
macro name after prefix for empty region map sections |
|
|
expected prefix for species macro names |
|
|
macro name after prefix for the default species |
|
|
regex to find metatile behavior constants to evaluate |
|
|
regex to find Object event graphics ID macro names |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to find weather trigger macro names |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
regex to populate |
|
|
regex to populate the |
|
|
regex to populate the |
|
|
the file extension to output for a new tileset’s palette data files |
|
|
the file extension to output for a new tileset’s tiles image data file |
Global Constants
In some cases you may want to tell Porymap about a #define
or enum
it wouldn’t otherwise know about, or override one that it already reads. For this you can add a global constant, or a global constant file, and Porymap will read and evaluate these before anything else. Let’s look at an example of how each might be useful.
Porymap evaluates MAX_LEVEL
in the constants_pokemon
file, but let’s say you have defined MAX_LEVEL
to be #define MAX_LEVEL (MY_CONSTANT + 1)
, and MY_CONSTANT
is defined in some other file foo.h
. Porymap doesn’t read foo.h
, so it doesn’t know what MY_CONSTANT
is and it fails to evaluate MAX_LEVEL
. To fix this, click the button on the
Files
tab and choose your foo.h
file. Now Porymap will read any #define
or enum
in foo.h
, and it will know what MY_CONSTANT
is.
Now let’s say that you have #define MIN_LEVEL 1
. Porymap will read this 1
, and use it as the lower limit for a Pokémon’s level on the Wild Pokémon
tab. But what if you want to use level 0
on the Wild Pokémon
tab to mean something special like “match the player’s level”? You could redefine MIN_LEVEL
to be 0
, but that might have consequences in your code. You could instead override MIN_LEVEL
in Porymap by redefining it. Click the button on the
Identifiers
tab, enter the name MIN_LEVEL
and its value 0
, and now Porymap will ignore #define MIN_LEVEL 1
because you already told it the value.