From 48b7f5f9e3859f62e7aeeecb185cc592ee629aad Mon Sep 17 00:00:00 2001 From: Luke Hubmayer-Werner Date: Sat, 6 Jul 2024 01:23:40 +0930 Subject: [PATCH] Revisiting WorldMap pathing Cleaning up some older debugging stuff --- 5/addresses_SNES_PSX.tsv | 2 +- 5/structs/SNES.tsv | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/5/addresses_SNES_PSX.tsv b/5/addresses_SNES_PSX.tsv index 6ab7f76..992af1b 100644 --- a/5/addresses_SNES_PSX.tsv +++ b/5/addresses_SNES_PSX.tsv @@ -50,7 +50,7 @@ ptrs_tile_properties 0x0FC540 23 of u16 tile_properties 0x0FC56E See above for offsets worldmap_minimap_border_tiles 0x0FD800 32 of TileSNES4bpp length 0x400 ptrs_worldmap_tilesets 0x0FE000 5 of 256 of u16 Every offset points to a horizontal line of 256 tiles stored in banks C7 and C8 -worldmap_block_properties 0x0FEA00 3 of 192 of u24 +worldmap_block_properties 0x0FEA00 3 of 192 of WorldMapBlockProperties worldmap_blocks 0x0FF0C0 /nar/ff5_binx.bin 0x040300 3 of 4 of 192 of u8 # Top-left corners, top-right corners, bottom-left corners, bottom-right corners worldmap_tiles.bias 0x0FF9C0 /nar/ff5_bin3.bin 0x03FB00 3 of 256 of u8 Add to each pixel of the mode7c tiles worldmap_palettes 0x0FFCC0 /nar/ff5_binx.bin 0x040000 3 of 128 of ColorBGR555 diff --git a/5/structs/SNES.tsv b/5/structs/SNES.tsv index ccb7032..739093a 100644 --- a/5/structs/SNES.tsv +++ b/5/structs/SNES.tsv @@ -204,3 +204,27 @@ u8 x u8 num_bytes u8 event_flag # Add 0x1D0 to this for actual event flag u16 ptr_bytes # Read num_bytes from this address (0xC0 bank implied, so just from the start of the ROM) + +struct WorldMapBlockProperties +u1 is_pathable_foot +u1 is_pathable_chocobo +u1 is_pathable_black_chocobo +u1 is_pathable_hiryuu +u1 is_pathable_submarine +u1 is_pathable_ship +u1 is_pathable_airship +u1 is_surfaceable +u1 unk0_east # ship related? mostly seaside edges=0 but sometimes not +u1 unk0_west # ship related? mostly seaside edges=0 but sometimes not +u1 unk0_south # ship related? mostly seaside edges=0 but sometimes not +u1 unk0_north # ship related? mostly seaside edges=0 but sometimes not +u1 isnt_landable_chocobo +u1 isnt_landable_black_chocobo +u1 isnt_landable_hiryuu +u1 isnt_landable_airship +u4 unk1 # Maybe battle bg? 0=plains/other, 1=forest, 2=desert, 3=sea, 5=swamp, no others spotted for these 4 bits +u1 unk21 # Mountains and Exdeath's Castle =1 +u1 unk22 # Forests have this =1, except the southernmost tiles of them +u1 unk23 # Most rivers have this +u1 unk24 # Most walkable/boatable tiles have this - possibly random encounters enabled? +