diff --git a/docs/_sources/manual/project-files.rst.txt b/docs/_sources/manual/project-files.rst.txt index bc629a1f..20849ba3 100644 --- a/docs/_sources/manual/project-files.rst.txt +++ b/docs/_sources/manual/project-files.rst.txt @@ -86,10 +86,11 @@ In addition to these files, there are some specific symbol and macro names that ``symbol_obj_event_gfx_pointers``, ``gObjectEventGraphicsInfoPointers``, to map Object Event graphics IDs to graphics data ``symbol_pokemon_icon_table``, ``gMonIconTable``, to map species constants to icon images ``symbol_wild_encounters``, ``gWildMonHeaders``, output as the ``label`` property for the top-level wild ecounters JSON object - ``symbol_heal_locations``, ``sHealLocations``, only if ``Respawn Map/NPC`` is disabled - ``symbol_spawn_points``, ``sSpawnPoints``, only if ``Respawn Map/NPC`` is enabled - ``symbol_spawn_maps``, ``sWhiteoutRespawnHealCenterMapIdxs``, values for Heal Locations ``Respawn Map`` field - ``symbol_spawn_npcs``, ``sWhiteoutRespawnHealerNpcIds``, values for Heal Locations ``Respawn NPC`` field + ``symbol_heal_locations_type``, ``struct HealLocation``, the type for the Heal Locations table + ``symbol_heal_locations``, ``sHealLocations``, the default Heal Locations table name when ``Respawn Map/NPC`` is disabled + ``symbol_spawn_points``, ``sSpawnPoints``, the default Heal Locations table name when ``Respawn Map/NPC`` is enabled + ``symbol_spawn_maps``, ``u16 sWhiteoutRespawnHealCenterMapIdxs``, the type and table name for Heal Location ``Respawn Map`` values + ``symbol_spawn_npcs``, ``u8 sWhiteoutRespawnHealerNpcIds``, the type and table name for Heal Location ``Respawn NPC`` values ``symbol_attribute_table``, ``sMetatileAttrMasks``, optionally read to get settings on ``Tilesets`` tab ``symbol_tilesets_prefix``, ``gTileset_``, for new tileset names and to extract base tileset names ``define_obj_event_count``, ``OBJECT_EVENT_TEMPLATES_COUNT``, to limit total Object Events diff --git a/docs/_sources/manual/scripting-capabilities.rst.txt b/docs/_sources/manual/scripting-capabilities.rst.txt index 62044464..fe47f67f 100644 --- a/docs/_sources/manual/scripting-capabilities.rst.txt +++ b/docs/_sources/manual/scripting-capabilities.rst.txt @@ -1069,6 +1069,26 @@ All tileset functions are callable via the global ``map`` object. :param behavior: the behavior :type behavior: number +.. js:function:: map.getMetatileBehaviorName(metatileId) + + Gets the behavior name for the specified metatile. Returns an empty string if the metatile's behavior value has no name. + + :param metatileId: id of target metatile + :type metatileId: number + :returns: the behavior name + :rtype: string + +.. js:function:: map.setMetatileBehaviorName(metatileId, behavior) + + Sets the behavior name for the specified metatile. Does nothing if there is no metatile behavior define with the specified name. + + **Warning:** This function writes directly to the tileset. There is no undo for this. + + :param metatileId: id of target metatile + :type metatileId: number + :param behavior: the behavior name + :type behavior: string + .. js:function:: map.getMetatileAttributes(metatileId) Gets the raw attributes value for the specified metatile. @@ -2082,6 +2102,14 @@ All constants are accessible via the global ``constants`` object. The maximum number of metatiles in a secondary tileset. +.. js:attribute:: constants.num_primary_palettes + + The number of palettes in a primary tileset. + +.. js:attribute:: constants.num_secondary_palettes + + The number of palettes in a secondary tileset. + .. js:attribute:: constants.layers_per_metatile The number of tile layers used in each metatile. This will either be ``2`` or ``3``, depending on the config setting ``enable_triple_layer_metatiles``. @@ -2090,6 +2118,10 @@ All constants are accessible via the global ``constants`` object. The number of tiles in each metatile. This will either be ``8`` or ``12``, depending on the config setting ``enable_triple_layer_metatiles``. +.. js:attribute:: constants.metatile_behaviors + + An object mapping metatile behavior names to their values. For example, ``constants.metatile_behaviors["MB_TALL_GRASS"]`` would normally be ``2``. + .. js:attribute:: constants.base_game_version The string value of the config setting ``base_game_version``. This will either be ``pokeruby``, ``pokefirered``, or ``pokeemerald``. diff --git a/docs/_sources/reference/CHANGELOG.md.txt b/docs/_sources/reference/CHANGELOG.md.txt index cb19c2fa..c254bfe2 100644 --- a/docs/_sources/reference/CHANGELOG.md.txt +++ b/docs/_sources/reference/CHANGELOG.md.txt @@ -7,6 +7,34 @@ and this project somewhat adheres to [Semantic Versioning](https://semver.org/sp The **"Breaking Changes"** listed below are changes that have been made in the decompilation projects (e.g. pokeemerald), which porymap requires in order to work properly. It also includes changes to the scripting API that may change the behavior of existing porymap scripts. If porymap is used with a project or API script that is not up-to-date with the breaking changes, then porymap will likely break or behave improperly. ## [Unreleased] +Nothing, yet. + +## [5.3.0] - 2024-01-15 +### Added +- Add zoom sliders to the Tileset Editor. +- Add `getMetatileBehaviorName` and `setMetatileBehaviorName` to the API. +- Add `metatile_behaviors`, `num_primary_palettes`, and `num_secondary_palettes` to `constants` in the API. + +### Changed +- Metatile ID strings are now padded to their current max, not the overall max. +- Non-existent directories are now removed from the Open Recent Project menu. +- Hovering on the layer view in the Tileset Editor now displays the tile ID. +- Labels in the Script dropdown are now sorted alphabetically. +- The name of the Heal Locations table is no longer enforced. +- The API functions `addImage` and `createImage` now support project-relative paths. + +### Fixed +- Fix the metatile selector rectangle jumping when selecting up or left of the origin. +- Fix the event group tabs sometimes showing an event from the wrong group. +- Fix the clear buttons in the Shortcuts Editor not actually removing shortcuts. +- Fix slow speed for the script label autcomplete. +- Fix deleted script labels still appearing in the autocomplete after project reload. +- Fix the map search bar stealing focus on startup. +- Fix border metatiles view not resizing properly. +- Fix Open Recent Project not clearing the API overlay +- Fix API error reporting. + +## [5.2.0] - 2024-01-02 ### Added - Add an editor window under `Options -> Project Settings...` to customize the project-specific settings in `porymap.project.cfg` and `porymap.user.cfg`. - Add an editor window under `Options -> Custom Scripts...` for Porymap's API scripts. @@ -436,7 +464,9 @@ The **"Breaking Changes"** listed below are changes that have been made in the d ## [1.0.0] - 2018-10-26 This was the initial release. -[Unreleased]: https://github.com/huderlem/porymap/compare/5.1.1...HEAD +[Unreleased]: https://github.com/huderlem/porymap/compare/5.3.0...HEAD +[5.3.0]: https://github.com/huderlem/porymap/compare/5.2.0...5.3.0 +[5.2.0]: https://github.com/huderlem/porymap/compare/5.1.1...5.2.0 [5.1.1]: https://github.com/huderlem/porymap/compare/5.1.0...5.1.1 [5.1.0]: https://github.com/huderlem/porymap/compare/5.0.0...5.1.0 [5.0.0]: https://github.com/huderlem/porymap/compare/4.5.0...5.0.0 diff --git a/docs/genindex.html b/docs/genindex.html index a52819ff..b76e73be 100644 --- a/docs/genindex.html +++ b/docs/genindex.html @@ -218,118 +218,125 @@
gWildMonHeaders
label
property for the top-level wild ecounters JSON objectsymbol_heal_locations
symbol_heal_locations_type
struct HealLocation
symbol_heal_locations
sHealLocations
Respawn Map/NPC
is disabledRespawn Map/NPC
is disabledsymbol_spawn_points
symbol_spawn_points
sSpawnPoints
Respawn Map/NPC
is enabledRespawn Map/NPC
is enabledsymbol_spawn_maps
sWhiteoutRespawnHealCenterMapIdxs
Respawn Map
fieldsymbol_spawn_maps
u16 sWhiteoutRespawnHealCenterMapIdxs
Respawn Map
valuessymbol_spawn_npcs
sWhiteoutRespawnHealerNpcIds
Respawn NPC
fieldsymbol_spawn_npcs
u8 sWhiteoutRespawnHealerNpcIds
Respawn NPC
valuessymbol_attribute_table
symbol_attribute_table
sMetatileAttrMasks
Tilesets
tabsymbol_tilesets_prefix
symbol_tilesets_prefix
gTileset_
define_obj_event_count
define_obj_event_count
OBJECT_EVENT_TEMPLATES_COUNT
define_min_level
define_min_level
MIN_LEVEL
define_max_level
define_max_level
MAX_LEVEL
define_tiles_primary
define_tiles_primary
NUM_TILES_IN_PRIMARY
define_tiles_total
define_tiles_total
NUM_TILES_TOTAL
define_metatiles_primary
define_metatiles_primary
NUM_METATILES_IN_PRIMARY
define_pals_primary
define_pals_primary
NUM_PALS_IN_PRIMARY
define_pals_total
define_pals_total
NUM_PALS_TOTAL
define_map_size
define_map_size
MAX_MAP_DATA_SIZE
define_mask_metatile
define_mask_metatile
MAPGRID_METATILE_ID_MASK
Maps
tabdefine_mask_collision
define_mask_collision
MAPGRID_COLLISION_MASK
Maps
tabdefine_mask_elevation
define_mask_elevation
MAPGRID_ELEVATION_MASK
Maps
tabdefine_mask_behavior
define_mask_behavior
METATILE_ATTR_BEHAVIOR_MASK
Tilesets
tabdefine_mask_layer
define_mask_layer
METATILE_ATTR_LAYER_MASK
Tilesets
tabdefine_attribute_behavior
define_attribute_behavior
METATILE_ATTRIBUTE_BEHAVIOR
symbol_attribute_table
define_attribute_layer
define_attribute_layer
METATILE_ATTRIBUTE_LAYER_TYPE
symbol_attribute_table
define_attribute_terrain
define_attribute_terrain
METATILE_ATTRIBUTE_TERRAIN
symbol_attribute_table
define_attribute_encounter
define_attribute_encounter
METATILE_ATTRIBUTE_ENCOUNTER_TYPE
symbol_attribute_table
define_metatile_label_prefix
define_metatile_label_prefix
METATILE_
define_heal_locations_prefix
define_heal_locations_prefix
HEAL_LOCATION_
Respawn Map/NPC
is disableddefine_spawn_prefix
define_spawn_prefix
SPAWN_
Respawn Map/NPC
is enableddefine_map_prefix
define_map_prefix
MAP_
define_map_dynamic
define_map_dynamic
DYNAMIC
define_map_empty
define_map_empty
UNDEFINED
define_map_section_prefix
define_map_section_prefix
MAPSEC_
define_map_section_empty
define_map_section_empty
NONE
define_map_section_count
define_map_section_count
COUNT
regex_behaviors
regex_behaviors
\bMB_
regex_obj_event_gfx
regex_obj_event_gfx
\bOBJ_EVENT_GFX_
regex_items
regex_items
\bITEM_(?!(B_)?USE_)
regex_flags
regex_flags
\bFLAG_
regex_vars
regex_vars
\bVAR_
regex_movement_types
regex_movement_types
\bMOVEMENT_TYPE_
regex_map_types
regex_map_types
\bMAP_TYPE_
regex_battle_scenes
regex_battle_scenes
\bMAP_BATTLE_SCENE_
regex_weather
regex_weather
\bWEATHER_
regex_coord_event_weather
regex_coord_event_weather
\bCOORD_EVENT_WEATHER_
regex_secret_bases
regex_secret_bases
\bSECRET_BASE_[A-Za-z0-9_]*_[0-9]+
regex_sign_facing_directions
regex_sign_facing_directions
\bBG_EVENT_PLAYER_FACING_
regex_trainer_types
regex_trainer_types
\bTRAINER_TYPE_
regex_music
regex_music
\b(SE|MUS)_
regex_species
regex_species
\bSPECIES_
map.
getMetatileBehaviorName
(metatileId)¶Gets the behavior name for the specified metatile. Returns an empty string if the metatile’s behavior value has no name.
+Arguments: |
|
+
---|---|
Returns: | the behavior name + |
+
Return type: | string + |
+
map.
setMetatileBehaviorName
(metatileId, behavior)¶Sets the behavior name for the specified metatile. Does nothing if there is no metatile behavior define with the specified name.
+Warning: This function writes directly to the tileset. There is no undo for this.
+Arguments: |
|
+
---|
map.
getMetatileAttributes
(metatileId)¶The maximum number of metatiles in a secondary tileset.
constants.
num_primary_palettes
¶The number of palettes in a primary tileset.
+constants.
num_secondary_palettes
¶The number of palettes in a secondary tileset.
+constants.
layers_per_metatile
¶The number of tiles in each metatile. This will either be 8
or 12
, depending on the config setting enable_triple_layer_metatiles
.
constants.
metatile_behaviors
¶An object mapping metatile behavior names to their values. For example, constants.metatile_behaviors["MB_TALL_GRASS"]
would normally be 2
.
constants.
base_game_version
¶