Represents the full Overworld data, light and dark world. More...
#include <overworld.h>

Public Member Functions | |
| Overworld (Rom *rom) | |
| absl::Status | Load (Rom *rom) |
| absl::Status | LoadOverworldMaps () |
| void | LoadTileTypes () |
| absl::Status | LoadSprites () |
| absl::Status | LoadSpritesFromMap (int sprite_start, int sprite_count, int sprite_index) |
| absl::Status | EnsureMapBuilt (int map_index) |
| Build a map on-demand if it hasn't been built yet. | |
| absl::Status | Save (Rom *rom) |
| absl::Status | SaveOverworldMaps () |
| absl::Status | SaveLargeMaps () |
| absl::Status | SaveLargeMapsExpanded () |
| absl::Status | SaveSmallAreaTransitions (int i, int parent_x_pos, int parent_y_pos, int transition_target_north, int transition_target_west, int transition_pos_x, int transition_pos_y, int screen_change_1, int screen_change_2, int screen_change_3, int screen_change_4) |
| absl::Status | SaveLargeAreaTransitions (int i, int parent_x_pos, int parent_y_pos, int transition_target_north, int transition_target_west, int transition_pos_x, int transition_pos_y, int screen_change_1, int screen_change_2, int screen_change_3, int screen_change_4) |
| absl::Status | SaveWideAreaTransitions (int i, int parent_x_pos, int parent_y_pos, int transition_target_north, int transition_target_west, int transition_pos_x, int transition_pos_y, int screen_change_1, int screen_change_2, int screen_change_3, int screen_change_4) |
| absl::Status | SaveTallAreaTransitions (int i, int parent_x_pos, int parent_y_pos, int transition_target_north, int transition_target_west, int transition_pos_x, int transition_pos_y, int screen_change_1, int screen_change_2, int screen_change_3, int screen_change_4) |
| absl::Status | SaveEntrances () |
| absl::Status | SaveExits () |
| absl::Status | SaveItems () |
| absl::Status | SaveMapOverlays () |
| absl::Status | SaveOverworldTilesType () |
| absl::Status | SaveCustomOverworldASM (bool enable_bg_color, bool enable_main_palette, bool enable_mosaic, bool enable_gfx_groups, bool enable_subscreen_overlay, bool enable_animated) |
| absl::Status | SaveAreaSpecificBGColors () |
| absl::Status | CreateTile32Tilemap () |
| absl::Status | SaveMap16Expanded () |
| absl::Status | SaveMap16Tiles () |
| absl::Status | SaveMap32Expanded () |
| absl::Status | SaveMap32Tiles () |
| absl::Status | SaveMapProperties () |
| absl::Status | SaveMusic () |
| absl::Status | SaveAreaSizes () |
| void | AssignMapSizes (std::vector< OverworldMap > &maps) |
| Loads all maps from ROM to see what size they are. | |
| absl::Status | ConfigureMultiAreaMap (int parent_index, AreaSizeEnum size) |
| Configure a multi-area map structure (Large/Wide/Tall) | |
| auto | rom () const |
| auto | mutable_rom () |
| void | Destroy () |
| int | GetTileFromPosition (ImVec2 position) const |
| OverworldBlockset & | GetMapTiles (int world_type) |
| auto | overworld_maps () const |
| auto | overworld_map (int i) const |
| auto | mutable_overworld_map (int i) |
| auto | exits () const |
| auto | mutable_exits () |
| std::vector< gfx::Tile16 > | tiles16 () const |
| auto | tiles32_unique () const |
| auto | mutable_tiles16 () |
| auto | sprites (int state) const |
| auto | mutable_sprites (int state) |
| auto | current_graphics () const |
| const std::vector< OverworldEntrance > & | entrances () const |
| auto & | entrances () |
| auto | mutable_entrances () |
| const std::vector< OverworldEntrance > & | holes () const |
| auto & | holes () |
| auto | mutable_holes () |
| auto | deleted_entrances () const |
| auto | mutable_deleted_entrances () |
| auto | current_area_palette () const |
| auto | current_map_bitmap_data () const |
| auto | tile16_blockset_data () const |
| auto | is_loaded () const |
| auto | expanded_tile16 () const |
| auto | expanded_tile32 () const |
| auto | expanded_entrances () const |
| void | set_current_map (int i) |
| void | set_current_world (int world) |
| uint16_t | GetTile (int x, int y) const |
| void | SetTile (int x, int y, uint16_t tile_id) |
| auto | map_tiles () const |
| auto | mutable_map_tiles () |
| auto | all_items () const |
| auto | mutable_all_items () |
| auto | all_tiles_types () const |
| auto | mutable_all_tiles_types () |
| auto | all_sprites () const |
Private Types | |
| enum | Dimension { map32TilesTL = 0 , map32TilesTR = 1 , map32TilesBL = 2 , map32TilesBR = 3 } |
Private Member Functions | |
| void | FetchLargeMaps () |
| absl::StatusOr< uint16_t > | GetTile16ForTile32 (int index, int quadrant, int dimension, const uint32_t *map32address) |
| absl::Status | AssembleMap32Tiles () |
| absl::Status | AssembleMap16Tiles () |
| void | AssignWorldTiles (int x, int y, int sx, int sy, int tpos, OverworldBlockset &world) |
| void | OrganizeMapTiles (std::vector< uint8_t > &bytes, std::vector< uint8_t > &bytes2, int i, int sx, int sy, int &ttpos) |
| void | DecompressAllMapTiles () |
| absl::Status | DecompressAllMapTilesParallel () |
Represents the full Overworld data, light and dark world.
This class is responsible for loading and saving the overworld data, as well as creating the tilesets and tilemaps for the overworld.
Definition at line 128 of file overworld.h.
|
private |
| Enumerator | |
|---|---|
| map32TilesTL | |
| map32TilesTR | |
| map32TilesBL | |
| map32TilesBR | |
Definition at line 309 of file overworld.h.
|
inline |
Definition at line 130 of file overworld.h.
| absl::Status yaze::zelda3::Overworld::Load | ( | Rom * | rom | ) |
Definition at line 31 of file overworld.cc.
References all_entrances_, all_exits_, all_holes_, all_items_, AssembleMap16Tiles(), AssembleMap32Tiles(), ASSIGN_OR_RETURN, AssignMapSizes(), DecompressAllMapTilesParallel(), FetchLargeMaps(), is_loaded_, yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LoadEntrances(), yaze::zelda3::LoadExits(), yaze::zelda3::LoadHoles(), yaze::zelda3::LoadItems(), LoadOverworldMaps(), LoadSprites(), LoadTileTypes(), map_parent_, overworld_maps_, yaze::zelda3::OverworldCustomASMHasBeenApplied, RETURN_IF_ERROR, rom(), and rom_.
Referenced by yaze::cli::Tile16ProposalGenerator::ApplyProposal(), yaze::editor::OverworldEditor::ApplyZSCustomOverworldASM(), OverworldGoldenDataExtractor::ExtractAllData(), yaze::cli::Tile16ProposalGenerator::GenerateDiff(), yaze::cli::HandleOverworldDescribeMapLegacy(), yaze::cli::HandleOverworldFindTileLegacy(), yaze::cli::HandleOverworldGetTileLegacy(), yaze::cli::HandleOverworldListWarpsLegacy(), yaze::cli::HandleOverworldSetTileLegacy(), yaze::editor::OverworldEditor::LoadGraphics(), yaze::cli::Tile16ProposalGenerator::ParseReplaceTileCommand(), yaze::cli::Tile16ProposalGenerator::ParseSetAreaCommand(), yaze::cli::Tile16ProposalGenerator::ParseSetTileCommand(), yaze::test::RomDependentTestSuite::RunComprehensiveSaveTest(), yaze::test::RomDependentTestSuite::RunRomOverworldLoadingTest(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), and yaze::test::TEST_F().
| absl::Status yaze::zelda3::Overworld::LoadOverworldMaps | ( | ) |
Definition at line 604 of file overworld.cc.
References game_state_, GetMapTiles(), yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kSpecialWorldMapIdStart, yaze::util::logf(), overworld_maps_, RETURN_IF_ERROR, and tiles16_.
Referenced by Load().

| void yaze::zelda3::Overworld::LoadTileTypes | ( | ) |
Definition at line 683 of file overworld.cc.
References all_tiles_types_, yaze::zelda3::kNumTileTypes, and rom().
Referenced by Load().

| absl::Status yaze::zelda3::Overworld::LoadSprites | ( | ) |
Definition at line 690 of file overworld.cc.
References yaze::zelda3::kOverworldSpritesAgahnim, yaze::zelda3::kOverworldSpritesBeginning, yaze::zelda3::kOverworldSpritesZelda, LoadSpritesFromMap(), yaze::zelda3::OverworldCustomASMHasBeenApplied, yaze::zelda3::overworldSpritesAgahnimExpanded, yaze::zelda3::overworldSpritesBeginingExpanded, yaze::zelda3::overworldSpritesZeldaExpanded, and RETURN_IF_ERROR.
Referenced by Load().

| absl::Status yaze::zelda3::Overworld::LoadSpritesFromMap | ( | int | sprite_start, |
| int | sprite_count, | ||
| int | sprite_index | ||
| ) |
Definition at line 727 of file overworld.cc.
References all_sprites_, ASSIGN_OR_RETURN, map_parent_, overworld_maps_, rom(), and yaze::SnesToPc().
Referenced by LoadSprites().

| absl::Status yaze::zelda3::Overworld::EnsureMapBuilt | ( | int | map_index | ) |
Build a map on-demand if it hasn't been built yet.
This method checks if the specified map needs to be built and builds it if necessary. Used for lazy loading optimization.
Definition at line 660 of file overworld.cc.
References game_state_, GetMapTiles(), yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kSpecialWorldMapIdStart, overworld_maps_, and tiles16_.
Referenced by yaze::cli::overworld::BuildMapSummary(), yaze::editor::OverworldEditor::CheckForCurrentMap(), and yaze::editor::OverworldEditor::EnsureMapTexture().

| absl::Status yaze::zelda3::Overworld::Save | ( | Rom * | rom | ) |
Definition at line 768 of file overworld.cc.
References expanded_tile16_, expanded_tile32_, RETURN_IF_ERROR, rom(), rom_, SaveAreaSizes(), SaveAreaSpecificBGColors(), SaveEntrances(), SaveExits(), SaveItems(), SaveMap16Expanded(), SaveMap16Tiles(), SaveMap32Expanded(), SaveMap32Tiles(), SaveMapOverlays(), SaveMusic(), SaveOverworldMaps(), and SaveOverworldTilesType().
| absl::Status yaze::zelda3::Overworld::SaveOverworldMaps | ( | ) |
Definition at line 792 of file overworld.cc.
References yaze::util::HexByte(), yaze::util::HexLong(), yaze::gfx::HyruleMagicCompress(), yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kOverworldCompressedMapPos, yaze::zelda3::kOverworldCompressedOverflowPos, yaze::zelda3::kOverworldMapDataOverflow, yaze::util::logf(), map_data_p1, map_data_p2, map_pointers1, map_pointers1_id, map_pointers2, map_pointers2_id, yaze::PcToSnes(), RETURN_IF_ERROR, rom(), SaveLargeMaps(), and tiles32_list_.
Referenced by yaze::test::RomDependentTestSuite::RunComprehensiveSaveTest(), yaze::editor::OverworldEditor::Save(), Save(), and yaze::test::TEST_F().
| absl::Status yaze::zelda3::Overworld::SaveLargeMaps | ( | ) |
Definition at line 930 of file overworld.cc.
References yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::kNumMapsPerWorld, yaze::zelda3::kOverworldMapParentId, yaze::zelda3::kOverworldMapSize, yaze::zelda3::kOverworldMapSizeHighByte, yaze::zelda3::kOverworldScreenSize, yaze::zelda3::kOverworldScreenSizeForLoading, yaze::zelda3::kOverworldScreenTileMapChangeByScreen1, yaze::zelda3::kOverworldScreenTileMapChangeByScreen2, yaze::zelda3::kOverworldScreenTileMapChangeByScreen3, yaze::zelda3::kOverworldScreenTileMapChangeByScreen4, yaze::zelda3::kOverworldTransitionPositionX, yaze::zelda3::kOverworldTransitionPositionY, yaze::zelda3::kSpecialWorldMapIdStart, yaze::zelda3::kTransitionTargetNorth, yaze::zelda3::kTransitionTargetWest, yaze::util::logf(), overworld_maps_, yaze::zelda3::OverworldCustomASMHasBeenApplied, RETURN_IF_ERROR, rom(), and SaveLargeMapsExpanded().
Referenced by SaveOverworldMaps().

| absl::Status yaze::zelda3::Overworld::SaveLargeMapsExpanded | ( | ) |
Definition at line 1802 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kOverworldMapParentIdExpanded, yaze::zelda3::kOverworldScreenTileMapChangeByScreen1Expanded, yaze::zelda3::kOverworldScreenTileMapChangeByScreen2Expanded, yaze::zelda3::kOverworldScreenTileMapChangeByScreen3Expanded, yaze::zelda3::kOverworldScreenTileMapChangeByScreen4Expanded, yaze::zelda3::kOverworldTransitionPositionXExpanded, yaze::zelda3::kOverworldTransitionPositionYExpanded, yaze::zelda3::LargeArea, yaze::util::logf(), overworld_maps_, RETURN_IF_ERROR, rom(), SaveLargeAreaTransitions(), SaveSmallAreaTransitions(), SaveTallAreaTransitions(), SaveWideAreaTransitions(), yaze::zelda3::SmallArea, yaze::zelda3::TallArea, yaze::zelda3::transition_target_northExpanded, yaze::zelda3::transition_target_westExpanded, and yaze::zelda3::WideArea.
Referenced by SaveLargeMaps().
| absl::Status yaze::zelda3::Overworld::SaveSmallAreaTransitions | ( | int | i, |
| int | parent_x_pos, | ||
| int | parent_y_pos, | ||
| int | transition_target_north, | ||
| int | transition_target_west, | ||
| int | transition_pos_x, | ||
| int | transition_pos_y, | ||
| int | screen_change_1, | ||
| int | screen_change_2, | ||
| int | screen_change_3, | ||
| int | screen_change_4 | ||
| ) |
Definition at line 1260 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LargeArea, overworld_maps_, RETURN_IF_ERROR, rom(), yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by SaveLargeMapsExpanded().

| absl::Status yaze::zelda3::Overworld::SaveLargeAreaTransitions | ( | int | i, |
| int | parent_x_pos, | ||
| int | parent_y_pos, | ||
| int | transition_target_north, | ||
| int | transition_target_west, | ||
| int | transition_pos_x, | ||
| int | transition_pos_y, | ||
| int | screen_change_1, | ||
| int | screen_change_2, | ||
| int | screen_change_3, | ||
| int | screen_change_4 | ||
| ) |
Definition at line 1369 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LargeArea, overworld_maps_, RETURN_IF_ERROR, rom(), yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by SaveLargeMapsExpanded().

| absl::Status yaze::zelda3::Overworld::SaveWideAreaTransitions | ( | int | i, |
| int | parent_x_pos, | ||
| int | parent_y_pos, | ||
| int | transition_target_north, | ||
| int | transition_target_west, | ||
| int | transition_pos_x, | ||
| int | transition_pos_y, | ||
| int | screen_change_1, | ||
| int | screen_change_2, | ||
| int | screen_change_3, | ||
| int | screen_change_4 | ||
| ) |
Definition at line 1525 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LargeArea, overworld_maps_, RETURN_IF_ERROR, rom(), yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by SaveLargeMapsExpanded().

| absl::Status yaze::zelda3::Overworld::SaveTallAreaTransitions | ( | int | i, |
| int | parent_x_pos, | ||
| int | parent_y_pos, | ||
| int | transition_target_north, | ||
| int | transition_target_west, | ||
| int | transition_pos_x, | ||
| int | transition_pos_y, | ||
| int | screen_change_1, | ||
| int | screen_change_2, | ||
| int | screen_change_3, | ||
| int | screen_change_4 | ||
| ) |
Definition at line 1665 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LargeArea, overworld_maps_, RETURN_IF_ERROR, rom(), yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by SaveLargeMapsExpanded().

| absl::Status yaze::zelda3::Overworld::SaveEntrances | ( | ) |
Definition at line 2404 of file overworld.cc.
References all_entrances_, all_holes_, expanded_entrances_, RETURN_IF_ERROR, rom_, yaze::zelda3::SaveEntrances(), and yaze::zelda3::SaveHoles().
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveExits | ( | ) |
Definition at line 2410 of file overworld.cc.
References all_exits_, RETURN_IF_ERROR, rom_, and yaze::zelda3::SaveExits().
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveItems | ( | ) |
Definition at line 2415 of file overworld.cc.
References all_items_, RETURN_IF_ERROR, rom_, and yaze::zelda3::SaveItems().
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveMapOverlays | ( | ) |
Definition at line 2420 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kOverlayCodeStart, yaze::util::logf(), overworld_maps_, yaze::PcToSnes(), RETURN_IF_ERROR, and rom().
Referenced by Save().

| absl::Status yaze::zelda3::Overworld::SaveOverworldTilesType | ( | ) |
Definition at line 2492 of file overworld.cc.
References all_tiles_types_, yaze::zelda3::kNumTileTypes, yaze::util::logf(), yaze::zelda3::overworldTilesType, RETURN_IF_ERROR, and rom().
Referenced by Save().

| absl::Status yaze::zelda3::Overworld::SaveCustomOverworldASM | ( | bool | enable_bg_color, |
| bool | enable_main_palette, | ||
| bool | enable_mosaic, | ||
| bool | enable_gfx_groups, | ||
| bool | enable_subscreen_overlay, | ||
| bool | enable_animated | ||
| ) |
Definition at line 2503 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::util::logf(), overworld_maps_, yaze::zelda3::OverworldCustomAnimatedGFXArray, yaze::zelda3::OverworldCustomAnimatedGFXEnabled, yaze::zelda3::OverworldCustomAreaSpecificBGEnabled, yaze::zelda3::OverworldCustomMainPaletteArray, yaze::zelda3::OverworldCustomMainPaletteEnabled, yaze::zelda3::OverworldCustomMosaicArray, yaze::zelda3::OverworldCustomMosaicEnabled, yaze::zelda3::OverworldCustomSubscreenOverlayArray, yaze::zelda3::OverworldCustomSubscreenOverlayEnabled, yaze::zelda3::OverworldCustomTileGFXGroupArray, yaze::zelda3::OverworldCustomTileGFXGroupEnabled, RETURN_IF_ERROR, and rom().

| absl::Status yaze::zelda3::Overworld::SaveAreaSpecificBGColors | ( | ) |
Definition at line 2575 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::util::logf(), overworld_maps_, yaze::zelda3::OverworldCustomAreaSpecificBGPalette, RETURN_IF_ERROR, and rom().
Referenced by Save().

| absl::Status yaze::zelda3::Overworld::CreateTile32Tilemap | ( | ) |
Definition at line 1930 of file overworld.cc.
References yaze::core::FeatureFlags::get(), yaze::gfx::Tile32::GetPackedValue(), yaze::zelda3::LimitOfMap32, map_tiles_, yaze::zelda3::NumberOfMap32, tiles32_list_, and tiles32_unique_.
Referenced by yaze::editor::OverworldEditor::Save().

| absl::Status yaze::zelda3::Overworld::SaveMap16Expanded | ( | ) |
Definition at line 2288 of file overworld.cc.
References yaze::zelda3::kMap16TilesExpanded, yaze::zelda3::NumberOfMap16Ex, yaze::PcToSnes(), RETURN_IF_ERROR, rom(), yaze::SnesToPc(), and tiles16_.
Referenced by Save().

| absl::Status yaze::zelda3::Overworld::SaveMap16Tiles | ( | ) |
Definition at line 2383 of file overworld.cc.
References yaze::zelda3::kMap16Tiles, yaze::util::logf(), yaze::zelda3::NumberOfMap16, RETURN_IF_ERROR, rom(), and tiles16_.
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveMap32Expanded | ( | ) |
Definition at line 1990 of file overworld.cc.
References yaze::zelda3::kMap32TileBLExpanded, yaze::zelda3::kMap32TileBRExpanded, yaze::zelda3::kMap32TileTRExpanded, yaze::PcToSnes(), RETURN_IF_ERROR, rom(), and tiles32_unique_.
Referenced by Save().

| absl::Status yaze::zelda3::Overworld::SaveMap32Tiles | ( | ) |
Definition at line 2159 of file overworld.cc.
References yaze::util::logf(), map32TilesBL, map32TilesBR, RETURN_IF_ERROR, rom(), and tiles32_unique_.
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveMapProperties | ( | ) |
Definition at line 2588 of file overworld.cc.
References yaze::zelda3::kAreaGfxIdPtr, yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::kOverworldMapPaletteIds, yaze::zelda3::kOverworldSpritePaletteIds, yaze::zelda3::kOverworldSpriteset, yaze::zelda3::kSpecialWorldMapIdStart, yaze::util::logf(), overworld_maps_, RETURN_IF_ERROR, and rom().
Referenced by yaze::test::RomDependentTestSuite::RunComprehensiveSaveTest(), yaze::editor::OverworldEditor::Save(), and yaze::test::TEST_F().

| absl::Status yaze::zelda3::Overworld::SaveMusic | ( | ) |
Definition at line 2639 of file overworld.cc.
References yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::kOverworldMusicAgahnim, yaze::zelda3::kOverworldMusicBeginning, yaze::zelda3::kOverworldMusicDarkWorld, yaze::zelda3::kOverworldMusicMasterSword, yaze::zelda3::kOverworldMusicZelda, yaze::zelda3::kSpecialWorldMapIdStart, yaze::util::logf(), overworld_maps_, RETURN_IF_ERROR, and rom().
Referenced by yaze::editor::OverworldEditor::Save(), and Save().

| absl::Status yaze::zelda3::Overworld::SaveAreaSizes | ( | ) |
Definition at line 2664 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kOverworldMessagesExpanded, yaze::zelda3::kOverworldScreenSize, yaze::util::logf(), overworld_maps_, yaze::zelda3::OverworldCustomASMHasBeenApplied, RETURN_IF_ERROR, and rom().
Referenced by Save().

| void yaze::zelda3::Overworld::AssignMapSizes | ( | std::vector< OverworldMap > & | maps | ) |
Loads all maps from ROM to see what size they are.
| maps | The maps to update (passed by reference) |
Definition at line 173 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::LargeArea, yaze::zelda3::SmallArea, yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by Load().
| absl::Status yaze::zelda3::Overworld::ConfigureMultiAreaMap | ( | int | parent_index, |
| AreaSizeEnum | size | ||
| ) |
Configure a multi-area map structure (Large/Wide/Tall)
| parent_index | The parent map index |
| size | The area size to configure |
Properly sets up sibling relationships and updates ROM data for v3+.
Definition at line 261 of file overworld.cc.
References yaze::zelda3::kNumOverworldMaps, yaze::zelda3::kOverworldMapParentId, yaze::zelda3::kOverworldMapParentIdExpanded, yaze::zelda3::kOverworldScreenSize, yaze::zelda3::LargeArea, LOG_DEBUG, overworld_maps_, yaze::zelda3::OverworldCustomASMHasBeenApplied, RETURN_IF_ERROR, rom(), yaze::zelda3::SmallArea, yaze::zelda3::TallArea, and yaze::zelda3::WideArea.
Referenced by yaze::editor::MapPropertiesSystem::DrawCustomFeaturesTab(), yaze::editor::MapPropertiesSystem::DrawPropertiesPopup(), and yaze::editor::MapPropertiesSystem::DrawSimplifiedMapSettings().

|
inline |
Definition at line 203 of file overworld.h.
References rom_.
Referenced by AssembleMap16Tiles(), AssembleMap32Tiles(), ConfigureMultiAreaMap(), DecompressAllMapTilesParallel(), GetTile16ForTile32(), Load(), LoadSpritesFromMap(), LoadTileTypes(), Save(), SaveAreaSizes(), SaveAreaSpecificBGColors(), SaveCustomOverworldASM(), SaveLargeAreaTransitions(), SaveLargeMaps(), SaveLargeMapsExpanded(), SaveMap16Expanded(), SaveMap16Tiles(), SaveMap32Expanded(), SaveMap32Tiles(), SaveMapOverlays(), SaveMapProperties(), SaveMusic(), SaveOverworldMaps(), SaveOverworldTilesType(), SaveSmallAreaTransitions(), SaveTallAreaTransitions(), and SaveWideAreaTransitions().
|
inline |
Definition at line 204 of file overworld.h.
References rom_.
|
inline |
Definition at line 206 of file overworld.h.
References all_entrances_, all_exits_, all_items_, all_sprites_, is_loaded_, overworld_maps_, sprites(), tiles16_, tiles32_, and tiles32_unique_.
Referenced by yaze::editor::OverworldEditor::Clear().

|
inline |
Definition at line 223 of file overworld.h.
References current_world_, yaze::zelda3::OverworldMapTiles::dark_world, yaze::zelda3::OverworldMapTiles::light_world, map_tiles_, and yaze::zelda3::OverworldMapTiles::special_world.
Referenced by yaze::editor::OverworldEditor::CheckForSelectRectangle(), and yaze::editor::OverworldEditor::SaveCurrentSelectionToScratch().
|
inline |
Definition at line 233 of file overworld.h.
References yaze::zelda3::OverworldMapTiles::dark_world, yaze::zelda3::OverworldMapTiles::light_world, map_tiles_, and yaze::zelda3::OverworldMapTiles::special_world.
Referenced by EnsureMapBuilt(), LoadOverworldMaps(), yaze::editor::OverworldEditor::RefreshChildMap(), yaze::editor::OverworldEditor::RefreshChildMapOnDemand(), and yaze::editor::OverworldEditor::RefreshMultiAreaMapsSafely().
|
inline |
Definition at line 246 of file overworld.h.
References overworld_maps_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteOverworldMapsData().
|
inline |
Definition at line 247 of file overworld.h.
References overworld_maps_.
Referenced by yaze::cli::overworld::BuildMapSummary(), yaze::editor::OverworldEditor::CheckForCurrentMap(), yaze::editor::MapPropertiesSystem::DrawCustomBackgroundColorEditor(), yaze::editor::MapPropertiesSystem::DrawCustomFeaturesTab(), yaze::editor::MapPropertiesSystem::DrawOverlayControls(), yaze::editor::MapPropertiesSystem::DrawOverlayEditor(), yaze::editor::MapPropertiesSystem::DrawOverlayPreviewOnMap(), yaze::editor::OverworldEditor::DrawOverworldProperties(), yaze::editor::MapPropertiesSystem::DrawPropertiesPopup(), yaze::editor::MapPropertiesSystem::DrawSimplifiedMapSettings(), yaze::editor::InsertEntrance(), yaze::editor::InsertExit(), yaze::editor::InsertItem(), yaze::editor::InsertSprite(), yaze::editor::OverworldEditor::RefreshMapPalette(), yaze::editor::OverworldEditor::RefreshTile16Blockset(), and yaze::test::TEST_F().
|
inline |
Definition at line 248 of file overworld.h.
References overworld_maps_.
Referenced by yaze::editor::MapPropertiesSystem::DrawBasicPropertiesTab(), yaze::editor::MapPropertiesSystem::DrawCustomBackgroundColorEditor(), yaze::editor::MapPropertiesSystem::DrawCustomFeaturesTab(), yaze::editor::MapPropertiesSystem::DrawGraphicsPopup(), yaze::editor::MapPropertiesSystem::DrawMosaicControls(), yaze::editor::MapPropertiesSystem::DrawMusicTab(), yaze::editor::MapPropertiesSystem::DrawOverlayControls(), yaze::editor::MapPropertiesSystem::DrawOverlayEditor(), yaze::editor::MapPropertiesSystem::DrawPalettesPopup(), yaze::editor::MapPropertiesSystem::DrawPropertiesPopup(), yaze::editor::MapPropertiesSystem::DrawSpritePropertiesTab(), yaze::editor::MapPropertiesSystem::DrawTileGraphicsTab(), yaze::editor::OverworldEditor::DrawToolset(), yaze::editor::OverworldEditor::RefreshChildMap(), yaze::editor::OverworldEditor::RefreshChildMapOnDemand(), yaze::editor::OverworldEditor::RefreshMapPalette(), yaze::editor::OverworldEditor::RefreshMapProperties(), yaze::editor::OverworldEditor::RefreshMultiAreaMapsSafely(), yaze::editor::MapPropertiesSystem::RefreshSiblingMapGraphics(), yaze::editor::OverworldEditor::RefreshSiblingMapGraphics(), yaze::test::RomDependentTestSuite::RunComprehensiveSaveTest(), and yaze::test::TEST_F().
|
inline |
Definition at line 249 of file overworld.h.
References all_exits_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteExitData().
|
inline |
Definition at line 250 of file overworld.h.
References all_exits_.
Referenced by yaze::editor::OverworldEntityRenderer::DrawExits(), and yaze::editor::InsertExit().
|
inline |
Definition at line 251 of file overworld.h.
References tiles16_.
Referenced by yaze::editor::OverworldEditor::RefreshChildMap(), yaze::editor::OverworldEditor::RefreshChildMapOnDemand(), yaze::editor::OverworldEditor::RefreshMultiAreaMapsSafely(), and OverworldGoldenDataExtractor::WriteTileData().
|
inline |
Definition at line 252 of file overworld.h.
References tiles32_unique_.
Referenced by OverworldGoldenDataExtractor::WriteTileData().
|
inline |
Definition at line 253 of file overworld.h.
References tiles16_.
Referenced by yaze::editor::OverworldEditor::RefreshChildMap(), yaze::editor::OverworldEditor::RefreshChildMapOnDemand(), and yaze::editor::OverworldEditor::RefreshMultiAreaMapsSafely().
|
inline |
Definition at line 254 of file overworld.h.
References all_sprites_.
Referenced by yaze::cli::overworld::CollectOverworldSprites(), and Destroy().
|
inline |
Definition at line 255 of file overworld.h.
References all_sprites_.
Referenced by yaze::editor::OverworldEntityRenderer::DrawSprites(), yaze::editor::InsertSprite(), and yaze::editor::OverworldEditor::LoadSpriteGraphics().
|
inline |
Definition at line 256 of file overworld.h.
References current_map_, and overworld_maps_.
|
inline |
Definition at line 259 of file overworld.h.
References all_entrances_.
Referenced by yaze::cli::overworld::CollectWarpEntries(), yaze::editor::OverworldEntityRenderer::DrawEntrances(), yaze::cli::overworld::GetEntranceDetails(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::test::TEST_F(), yaze::editor::OverworldEditor::UpdateUsageStats(), and OverworldGoldenDataExtractor::WriteEntranceData().
|
inline |
Definition at line 260 of file overworld.h.
References all_entrances_.
|
inline |
Definition at line 261 of file overworld.h.
References all_entrances_.
Referenced by yaze::editor::InsertEntrance().
|
inline |
Definition at line 262 of file overworld.h.
References all_holes_.
Referenced by yaze::cli::overworld::CollectWarpEntries(), yaze::editor::InsertEntrance(), yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteHoleData().
|
inline |
Definition at line 263 of file overworld.h.
References all_holes_.
|
inline |
Definition at line 264 of file overworld.h.
References all_holes_.
|
inline |
Definition at line 265 of file overworld.h.
References deleted_entrances_.
|
inline |
Definition at line 266 of file overworld.h.
References deleted_entrances_.
|
inline |
Definition at line 267 of file overworld.h.
References current_map_, and overworld_maps_.
Referenced by yaze::editor::OverworldEditor::DrawAreaGraphics(), yaze::editor::OverworldEditor::DrawScratchSpace(), yaze::editor::OverworldEditor::EnsureMapTexture(), yaze::editor::OverworldEditor::LoadGraphics(), yaze::editor::OverworldEditor::RefreshMapPalette(), yaze::editor::OverworldEditor::RefreshMultiAreaMapsSafely(), yaze::editor::OverworldEditor::RefreshTile16Blockset(), and yaze::editor::OverworldEditor::SaveCurrentSelectionToScratch().
|
inline |
Definition at line 270 of file overworld.h.
References current_map_, and overworld_maps_.
Referenced by yaze::editor::OverworldEditor::EnsureMapTexture(), and yaze::editor::OverworldEditor::LoadGraphics().
|
inline |
Definition at line 273 of file overworld.h.
References current_map_, and overworld_maps_.
Referenced by yaze::editor::OverworldEditor::LoadGraphics(), and yaze::editor::OverworldEditor::RefreshTile16Blockset().
|
inline |
Definition at line 276 of file overworld.h.
References is_loaded_.
Referenced by yaze::editor::OverworldEditor::AutomationGetTile(), yaze::editor::OverworldEditor::AutomationSetTile(), yaze::editor::OverworldEditor::DrawAreaGraphics(), yaze::editor::MapPropertiesSystem::DrawCustomBackgroundColorEditor(), yaze::editor::MapPropertiesSystem::DrawMapPropertiesPanel(), yaze::editor::MapPropertiesSystem::DrawOverlayEditor(), yaze::editor::OverworldEditor::DrawOverworldCanvas(), yaze::editor::OverworldEditor::HandleEntityInsertion(), yaze::editor::InsertEntrance(), yaze::editor::InsertExit(), yaze::editor::InsertItem(), yaze::editor::InsertSprite(), yaze::test::TEST_F(), yaze::test::TEST_F(), and yaze::editor::OverworldEditor::Update().
|
inline |
Definition at line 277 of file overworld.h.
References expanded_tile16_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteTileData().
|
inline |
Definition at line 278 of file overworld.h.
References expanded_tile32_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteTileData().
|
inline |
Definition at line 279 of file overworld.h.
References expanded_entrances_.
|
inline |
Definition at line 280 of file overworld.h.
References current_map_.
Referenced by yaze::editor::OverworldEditor::AutomationGetTile(), yaze::editor::OverworldEditor::AutomationSetTile(), yaze::editor::OverworldEditor::CheckForSelectRectangle(), yaze::editor::OverworldEditor::Copy(), yaze::editor::OverworldEditor::DrawAreaGraphics(), yaze::editor::OverworldEditor::EnsureMapTexture(), yaze::editor::OverworldEditor::LoadGraphics(), yaze::editor::OverworldEditor::RefreshTile16Blockset(), and yaze::editor::OverworldEditor::SaveCurrentSelectionToScratch().
|
inline |
Definition at line 281 of file overworld.h.
References current_world_.
Referenced by yaze::cli::Tile16ProposalGenerator::ApplyProposal(), yaze::editor::OverworldEditor::AutomationGetTile(), yaze::editor::OverworldEditor::AutomationSetTile(), yaze::editor::OverworldEditor::CheckForSelectRectangle(), yaze::editor::OverworldEditor::Copy(), yaze::cli::overworld::FindTileMatches(), yaze::cli::Tile16ProposalGenerator::GenerateDiff(), yaze::cli::HandleOverworldSetTileLegacy(), yaze::cli::Tile16ProposalGenerator::ParseReplaceTileCommand(), yaze::cli::Tile16ProposalGenerator::ParseSetAreaCommand(), yaze::cli::Tile16ProposalGenerator::ParseSetTileCommand(), and yaze::editor::OverworldEditor::SaveCurrentSelectionToScratch().
|
inline |
Definition at line 282 of file overworld.h.
References current_world_, yaze::zelda3::OverworldMapTiles::dark_world, yaze::zelda3::OverworldMapTiles::light_world, map_tiles_, and yaze::zelda3::OverworldMapTiles::special_world.
Referenced by yaze::editor::OverworldEditor::AutomationGetTile(), yaze::editor::OverworldEditor::Copy(), E2ETest_CanvasSelectionTest(), yaze::cli::overworld::FindTileMatches(), yaze::cli::Tile16ProposalGenerator::GenerateDiff(), yaze::cli::HandleOverworldGetTileLegacy(), yaze::cli::Tile16ProposalGenerator::ParseReplaceTileCommand(), yaze::cli::Tile16ProposalGenerator::ParseSetAreaCommand(), and yaze::cli::Tile16ProposalGenerator::ParseSetTileCommand().
|
inline |
Definition at line 291 of file overworld.h.
References current_world_, yaze::zelda3::OverworldMapTiles::dark_world, yaze::zelda3::OverworldMapTiles::light_world, map_tiles_, and yaze::zelda3::OverworldMapTiles::special_world.
Referenced by yaze::cli::Tile16ProposalGenerator::ApplyProposal(), yaze::editor::OverworldEditor::AutomationSetTile(), and yaze::cli::HandleOverworldSetTileLegacy().
|
inline |
Definition at line 300 of file overworld.h.
References map_tiles_.
Referenced by OverworldGoldenDataExtractor::WriteMapTilesData().
|
inline |
Definition at line 301 of file overworld.h.
References map_tiles_.
Referenced by yaze::editor::OverworldEditor::CheckForOverworldEdits(), yaze::editor::OverworldEditor::DrawDebugWindow(), yaze::editor::OverworldEditor::DrawOverworldEdits(), and yaze::editor::OverworldEditor::Paste().
|
inline |
Definition at line 302 of file overworld.h.
References all_items_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteItemData().
|
inline |
Definition at line 303 of file overworld.h.
References all_items_.
Referenced by yaze::editor::OverworldEntityRenderer::DrawItems(), and yaze::editor::InsertItem().
|
inline |
Definition at line 304 of file overworld.h.
References all_tiles_types_.
|
inline |
Definition at line 305 of file overworld.h.
References all_tiles_types_.
Referenced by yaze::editor::OverworldEditor::Load().
|
inline |
Definition at line 306 of file overworld.h.
References all_sprites_.
Referenced by yaze::test::TEST_F(), yaze::test::TEST_F(), and OverworldGoldenDataExtractor::WriteSpriteData().
|
private |
|
private |
Definition at line 399 of file overworld.cc.
References ASSIGN_OR_RETURN, and rom().
Referenced by AssembleMap32Tiles().

|
private |
Definition at line 410 of file overworld.cc.
References ASSIGN_OR_RETURN, yaze::zelda3::OverworldMapTiles::dark_world, expanded_tile32_, GetTile16ForTile32(), yaze::zelda3::kMap32ExpandedFlagPos, yaze::zelda3::kMap32TileBLExpanded, yaze::zelda3::kMap32TileBRExpanded, yaze::zelda3::kMap32TileCountExpanded, yaze::zelda3::kMap32TileTRExpanded, yaze::zelda3::OverworldMapTiles::light_world, yaze::util::logf(), map32TilesBL, map32TilesBR, map32TilesTL, map32TilesTR, map_tiles_, yaze::zelda3::OverworldCustomASMHasBeenApplied, rom(), yaze::zelda3::OverworldMapTiles::special_world, and tiles32_unique_.
Referenced by Load().

|
private |
Definition at line 470 of file overworld.cc.
References ASSIGN_OR_RETURN, expanded_tile16_, yaze::gfx::GetTilesInfo(), yaze::zelda3::kMap16ExpandedFlagPos, yaze::zelda3::kMap16Tiles, yaze::zelda3::kMap16TilesExpanded, yaze::zelda3::kNumTile16Individual, yaze::util::logf(), yaze::zelda3::NumberOfMap16Ex, yaze::zelda3::OverworldCustomASMHasBeenApplied, rom(), and tiles16_.
Referenced by Load().

|
private |
Definition at line 505 of file overworld.cc.
References tiles32_unique_.
Referenced by OrganizeMapTiles().
|
private |
Definition at line 517 of file overworld.cc.
References AssignWorldTiles(), yaze::zelda3::OverworldMapTiles::dark_world, yaze::zelda3::kDarkWorldMapIdStart, yaze::zelda3::OverworldMapTiles::light_world, map_tiles_, yaze::zelda3::OverworldMapTiles::special_world, and tiles32_unique_.
Referenced by DecompressAllMapTilesParallel().

|
private |
Definition at line 537 of file overworld.cc.
|
private |
Definition at line 543 of file overworld.cc.
References yaze::gfx::HyruleMagicDecompress(), yaze::zelda3::kNumOverworldMaps, yaze::util::logf(), OrganizeMapTiles(), rom(), and yaze::SnesToPc().
Referenced by Load().
|
private |
Definition at line 330 of file overworld.h.
Referenced by Load(), mutable_rom(), rom(), Save(), SaveEntrances(), SaveExits(), and SaveItems().
|
private |
Definition at line 332 of file overworld.h.
Referenced by Destroy(), is_loaded(), and Load().
|
private |
Definition at line 333 of file overworld.h.
Referenced by AssembleMap16Tiles(), expanded_tile16(), and Save().
|
private |
Definition at line 334 of file overworld.h.
Referenced by AssembleMap32Tiles(), expanded_tile32(), and Save().
|
private |
Definition at line 335 of file overworld.h.
Referenced by expanded_entrances(), and SaveEntrances().
|
private |
Definition at line 337 of file overworld.h.
Referenced by EnsureMapBuilt(), and LoadOverworldMaps().
|
private |
Definition at line 338 of file overworld.h.
Referenced by current_area_palette(), current_graphics(), current_map_bitmap_data(), set_current_map(), and tile16_blockset_data().
|
private |
Definition at line 339 of file overworld.h.
Referenced by GetTile(), GetTileFromPosition(), set_current_world(), and SetTile().
|
private |
Definition at line 341 of file overworld.h.
Referenced by AssembleMap32Tiles(), CreateTile32Tilemap(), GetMapTiles(), GetTile(), GetTileFromPosition(), map_tiles(), mutable_map_tiles(), OrganizeMapTiles(), and SetTile().
|
mutableprivate |
Definition at line 344 of file overworld.h.
|
private |
Definition at line 346 of file overworld.h.
Referenced by ConfigureMultiAreaMap(), current_area_palette(), current_graphics(), current_map_bitmap_data(), Destroy(), EnsureMapBuilt(), FetchLargeMaps(), Load(), LoadOverworldMaps(), LoadSpritesFromMap(), mutable_overworld_map(), overworld_map(), overworld_maps(), SaveAreaSizes(), SaveAreaSpecificBGColors(), SaveCustomOverworldASM(), SaveLargeAreaTransitions(), SaveLargeMaps(), SaveLargeMapsExpanded(), SaveMapOverlays(), SaveMapProperties(), SaveMusic(), SaveSmallAreaTransitions(), SaveTallAreaTransitions(), SaveWideAreaTransitions(), and tile16_blockset_data().
|
private |
Definition at line 347 of file overworld.h.
Referenced by Destroy(), entrances(), entrances(), Load(), mutable_entrances(), and SaveEntrances().
|
private |
Definition at line 348 of file overworld.h.
Referenced by holes(), holes(), Load(), mutable_holes(), and SaveEntrances().
|
private |
Definition at line 349 of file overworld.h.
Referenced by Destroy(), exits(), Load(), mutable_exits(), and SaveExits().
|
private |
Definition at line 350 of file overworld.h.
Referenced by all_items(), Destroy(), Load(), mutable_all_items(), and SaveItems().
|
private |
Definition at line 352 of file overworld.h.
Referenced by AssembleMap16Tiles(), Destroy(), EnsureMapBuilt(), LoadOverworldMaps(), mutable_tiles16(), SaveMap16Expanded(), SaveMap16Tiles(), and tiles16().
|
private |
Definition at line 353 of file overworld.h.
Referenced by Destroy().
|
private |
Definition at line 354 of file overworld.h.
Referenced by AssembleMap32Tiles(), AssignWorldTiles(), CreateTile32Tilemap(), Destroy(), OrganizeMapTiles(), SaveMap32Expanded(), SaveMap32Tiles(), and tiles32_unique().
|
private |
Definition at line 356 of file overworld.h.
Referenced by CreateTile32Tilemap(), and SaveOverworldMaps().
|
private |
Definition at line 357 of file overworld.h.
Referenced by deleted_entrances(), and mutable_deleted_entrances().
|
private |
Definition at line 359 of file overworld.h.
Referenced by Load(), and LoadSpritesFromMap().
|
private |
Definition at line 360 of file overworld.h.
Referenced by all_tiles_types(), LoadTileTypes(), mutable_all_tiles_types(), and SaveOverworldTilesType().
|
private |
Definition at line 361 of file overworld.h.
Referenced by all_sprites(), Destroy(), LoadSpritesFromMap(), mutable_sprites(), and sprites().
|
private |
Definition at line 362 of file overworld.h.
Referenced by SaveOverworldMaps().
|
private |
Definition at line 363 of file overworld.h.
Referenced by SaveOverworldMaps().
|
private |
Definition at line 364 of file overworld.h.
Referenced by SaveOverworldMaps().
|
private |
Definition at line 365 of file overworld.h.
Referenced by SaveOverworldMaps().
|
private |
Definition at line 366 of file overworld.h.
Referenced by SaveOverworldMaps().
|
private |
Definition at line 367 of file overworld.h.
Referenced by SaveOverworldMaps().