diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/constants/region_map_sections.h | 97 | ||||
-rw-r--r-- | include/constants/species.h | 6 | ||||
-rw-r--r-- | include/graphics.h | 3 | ||||
-rw-r--r-- | include/region_map.h | 16 | ||||
-rw-r--r-- | include/region_map_sections.h | 60 | ||||
-rw-r--r-- | include/roamer.h | 2 |
6 files changed, 121 insertions, 63 deletions
diff --git a/include/constants/region_map_sections.h b/include/constants/region_map_sections.h new file mode 100644 index 000000000..38ca06e1b --- /dev/null +++ b/include/constants/region_map_sections.h @@ -0,0 +1,97 @@ +#ifndef GUARD_REGIONMAPSEC_H +#define GUARD_REGIONMAPSEC_H + +enum +{ + MAPSEC_LITTLEROOT_TOWN, // 0x00 + MAPSEC_OLDALE_TOWN, // 0x01 + MAPSEC_DEWFORD_TOWN, // 0x02 + MAPSEC_LAVARIDGE_TOWN, // 0x03 + MAPSEC_FALLARBOR_TOWN, // 0x04 + MAPSEC_VERDANTURF_TOWN, // 0x05 + MAPSEC_PACIFIDLOG_TOWN, // 0x06 + MAPSEC_PETALBURG_CITY, // 0x07 + MAPSEC_SLATEPORT_CITY, // 0x08 + MAPSEC_MAUVILLE_CITY, // 0x09 + MAPSEC_RUSTBORO_CITY, // 0x0A + MAPSEC_FORTREE_CITY, // 0x0B + MAPSEC_LILYCOVE_CITY, // 0x0C + MAPSEC_MOSSDEEP_CITY, // 0x0D + MAPSEC_SOOTOPOLIS_CITY, // 0x0E + MAPSEC_EVER_GRANDE_CITY, // 0x0F + MAPSEC_ROUTE_101, // 0x10 + MAPSEC_ROUTE_102, // 0x11 + MAPSEC_ROUTE_103, // 0x12 + MAPSEC_ROUTE_104, // 0x13 + MAPSEC_ROUTE_105, // 0x14 + MAPSEC_ROUTE_106, // 0x15 + MAPSEC_ROUTE_107, // 0x16 + MAPSEC_ROUTE_108, // 0x17 + MAPSEC_ROUTE_109, // 0x18 + MAPSEC_ROUTE_110, // 0x19 + MAPSEC_ROUTE_111, // 0x1A + MAPSEC_ROUTE_112, // 0x1B + MAPSEC_ROUTE_113, // 0x1C + MAPSEC_ROUTE_114, // 0x1D + MAPSEC_ROUTE_115, // 0x1E + MAPSEC_ROUTE_116, // 0x1F + MAPSEC_ROUTE_117, // 0x20 + MAPSEC_ROUTE_118, // 0x21 + MAPSEC_ROUTE_119, // 0x22 + MAPSEC_ROUTE_120, // 0x23 + MAPSEC_ROUTE_121, // 0x24 + MAPSEC_ROUTE_122, // 0x25 + MAPSEC_ROUTE_123, // 0x26 + MAPSEC_ROUTE_124, // 0x27 + MAPSEC_ROUTE_125, // 0x28 + MAPSEC_ROUTE_126, // 0x29 + MAPSEC_ROUTE_127, // 0x2A + MAPSEC_ROUTE_128, // 0x2B + MAPSEC_ROUTE_129, // 0x2C + MAPSEC_ROUTE_130, // 0x2D + MAPSEC_ROUTE_131, // 0x2E + MAPSEC_ROUTE_132, // 0x2F + MAPSEC_ROUTE_133, // 0x30 + MAPSEC_ROUTE_134, // 0x31 + MAPSEC_UNDERWATER_124, // 0x32 + MAPSEC_UNDERWATER_125, // 0x33 + MAPSEC_UNDERWATER_126, // 0x34 + MAPSEC_UNDERWATER_127, // 0x35 + MAPSEC_UNDERWATER_SOOTOPOLIS, // 0x36 + MAPSEC_GRANITE_CAVE, // 0x37 + MAPSEC_MT_CHIMNEY, // 0x38 + MAPSEC_SAFARI_ZONE, // 0x39 + MAPSEC_BATTLE_TOWER, // 0x3A + MAPSEC_PETALBURG_WOODS, // 0x3B + MAPSEC_RUSTURF_TUNNEL, // 0x3C + MAPSEC_ABANDONED_SHIP, // 0x3D + MAPSEC_NEW_MAUVILLE, // 0x3E + MAPSEC_METEOR_FALLS, // 0x3F + MAPSEC_METEOR_FALLS_2, // 0x40 + MAPSEC_MT_PYRE, // 0x41 + MAPSEC_EVIL_TEAM_HIDEOUT, // 0x42 + MAPSEC_SHOAL_CAVE, // 0x43 + MAPSEC_SEAFLOOR_CAVERN, // 0x44 + MAPSEC_UNDERWATER_128, // 0x45 + MAPSEC_VICTORY_ROAD, // 0x46 + MAPSEC_MIRAGE_ISLAND, // 0x47 + MAPSEC_CAVE_OF_ORIGIN, // 0x48 + MAPSEC_SOUTHERN_ISLAND, // 0x49 + MAPSEC_FIERY_PATH, // 0x4A + MAPSEC_FIERY_PATH_2, // 0x4B + MAPSEC_JAGGED_PASS, // 0x4C + MAPSEC_JAGGED_PASS_2, // 0x4D + MAPSEC_SEALED_CHAMBER, // 0x4E + MAPSEC_UNDERWATER_SEALED_CHAMBER, // 0x4F + MAPSEC_SCORCHED_SLAB, // 0x50 + MAPSEC_ISLAND_CAVE, // 0x51 + MAPSEC_DESERT_RUINS, // 0x52 + MAPSEC_ANCIENT_TOMB, // 0x53 + MAPSEC_INSIDE_OF_TRUCK, // 0x54 + MAPSEC_SKY_PILLAR, // 0x55 + MAPSEC_SECRET_BASE, // 0x56 + MAPSEC_DYNAMIC, // 0x57 + MAPSEC_NOTHING // 0x58 +}; + +#endif // GUARD_REGIONMAPSEC_H diff --git a/include/constants/species.h b/include/constants/species.h index f698ada14..dc9856081 100644 --- a/include/constants/species.h +++ b/include/constants/species.h @@ -447,4 +447,10 @@ #define NUM_SPECIES SPECIES_EGG +#ifdef SAPPHIRE +#define ROAMER_SPECIES SPECIES_LATIAS +#else +#define ROAMER_SPECIES SPECIES_LATIOS +#endif + #endif // GUARD_CONSTANTS_SPECIES_H diff --git a/include/graphics.h b/include/graphics.h index d70aefac6..8e95d100d 100644 --- a/include/graphics.h +++ b/include/graphics.h @@ -3415,4 +3415,7 @@ extern const u16 gUnknown_08D1212C[]; extern const u16 gUnknown_08D1214C[]; extern const u8 Tiles_D129AC[]; +extern const u8 gAreaUnknownTiles[]; +extern const u16 gAreaUnknownPalette[]; + #endif // GUARD_GRAPHICS_H diff --git a/include/region_map.h b/include/region_map.h index 89a47cd05..4c10d84cb 100644 --- a/include/region_map.h +++ b/include/region_map.h @@ -1,6 +1,13 @@ #ifndef GUARD_REGION_MAP_H #define GUARD_REGION_MAP_H +struct RegionMapLocation +{ + u8 x, y; + u8 width, height; + const u8 *regionMapSectionId; +}; + struct RegionMap { u8 mapSectionName[20]; @@ -51,7 +58,7 @@ struct RegionMap /*0x080*/ u8 filler80[0x100]; /*0x180*/ u8 cursorSmallImage[0x100]; /*0x280*/ u8 cursorLargeImage[0x600]; -}; +}; // size: 0x880 void InitRegionMap(struct RegionMap *regionMap, bool8 zoomed); void sub_80FA904(struct RegionMap *regionMap, bool8 zoomed); @@ -61,8 +68,8 @@ u8 sub_80FAB60(void); void sub_80FAEC4(void); u8 sub_80FAFC0(void); void UpdateRegionMapVideoRegs(void); -void sub_80FB2A4(s16, s16); -u16 sub_80FBA04(u16 mapSectionId); +void RegionMapDefaultZoomOffsetPlayerSprite(s16, s16); +u16 GetOverworldMapFromUnderwaterMap(u16 mapSectionId); void CreateRegionMapCursor(u16, u16); void CreateRegionMapPlayerIcon(u16, u16); const u8 *GetMapSectionName(u8 *dest, u16 mapSectionId, u16 length); @@ -70,5 +77,8 @@ const u8 *CopyMapName(u8 *dest, u16 b); const u8 *CopyLocationName(u8 *dest, u16 b); void CB2_InitFlyRegionMap(void); void debug_sub_8110F28(void); +u16 GetRegionMapSectionAt_(u16 x, u16 y); + +extern const struct RegionMapLocation gRegionMapLocations[]; #endif // GUARD_REGION_MAP_H diff --git a/include/region_map_sections.h b/include/region_map_sections.h deleted file mode 100644 index a3bd60b59..000000000 --- a/include/region_map_sections.h +++ /dev/null @@ -1,60 +0,0 @@ -#ifndef GUARD_REGIONMAPSEC_H -#define GUARD_REGIONMAPSEC_H - -enum -{ - MAPSEC_LittlerootTown, // 0x00 - MAPSEC_OldaleTown, // 0x01 - MAPSEC_DewfordTown, // 0x02 - MAPSEC_LavaridgeTown, // 0x03 - MAPSEC_FallarborTown, // 0x04 - MAPSEC_VerdanturfTown, // 0x05 - MAPSEC_PacifidlogTown, // 0x06 - MAPSEC_PetalburgCity, // 0x07 - MAPSEC_SlateportCity, // 0x08 - MAPSEC_MauvilleCity, // 0x09 - MAPSEC_RustboroCity, // 0x0A - MAPSEC_FortreeCity, // 0x0B - MAPSEC_LilycoveCity, // 0x0C - MAPSEC_MossdeepCity, // 0x0D - MAPSEC_SootopolisCity, // 0x0E - MAPSEC_EverGrandeCity, // 0x0F - MAPSEC_Route101, // 0x10 - MAPSEC_Route102, // 0x11 - MAPSEC_Route103, // 0x12 - MAPSEC_Route104, // 0x13 - MAPSEC_Route105, // 0x14 - MAPSEC_Route106, // 0x15 - MAPSEC_Route107, // 0x16 - MAPSEC_Route108, // 0x17 - MAPSEC_Route109, // 0x18 - MAPSEC_Route110, // 0x19 - MAPSEC_Route111, // 0x1A - MAPSEC_Route112, // 0x1B - MAPSEC_Route113, // 0x1C - MAPSEC_Route114, // 0x1D - MAPSEC_Route115, // 0x1E - MAPSEC_Route116, // 0x1F - MAPSEC_Route117, // 0x20 - MAPSEC_Route118, // 0x21 - MAPSEC_Route119, // 0x22 - MAPSEC_Route120, // 0x23 - MAPSEC_Route121, // 0x24 - MAPSEC_Route122, // 0x25 - MAPSEC_Route123, // 0x26 - MAPSEC_Route124, // 0x27 - MAPSEC_Route125, // 0x28 - MAPSEC_Route126, // 0x29 - MAPSEC_Route127, // 0x2A - MAPSEC_Route128, // 0x2B - MAPSEC_Route129, // 0x2C - MAPSEC_Route130, // 0x2D - MAPSEC_Route131, // 0x2E - MAPSEC_Route132, // 0x2F - MAPSEC_Route133, // 0x30 - MAPSEC_Route134, // 0x31 - MAPSEC_MtChimney = 0x38, // 0x38 - MAPSEC_Nothing = 0x58, // 0x58 -}; - -#endif // GUARD_REGIONMAPSEC_H diff --git a/include/roamer.h b/include/roamer.h index 6f0813eb8..18cb0b4e4 100644 --- a/include/roamer.h +++ b/include/roamer.h @@ -15,4 +15,6 @@ void Debug_CreateRoamer(void); void Debug_GetRoamerLocation(u8 *); #endif // DEBUG +void GetRoamerLocation(u8 *mapGroup, u8 *mapNum); + #endif // GUARD_ROAMER_H |