Rename world_index_ to main_gfx_id_

This commit is contained in:
scawful
2024-05-24 20:29:18 -04:00
parent 63b7e48950
commit cb309743ea
2 changed files with 8 additions and 8 deletions

View File

@@ -146,13 +146,13 @@ void OverworldMap::LoadAreaInfo() {
// ============================================================================
void OverworldMap::LoadWorldIndex() {
void OverworldMap::LoadMainBlocksetId() {
if (parent_ < 0x40) {
world_index_ = 0x20;
main_gfx_id_ = 0x20;
} else if (parent_ >= 0x40 && parent_ < 0x80) {
world_index_ = 0x21;
main_gfx_id_ = 0x21;
} else if (parent_ == 0x88) {
world_index_ = 0x24;
main_gfx_id_ = 0x24;
}
}
@@ -174,7 +174,7 @@ void OverworldMap::LoadSpritesBlocksets() {
void OverworldMap::LoadMainBlocksets() {
for (int i = 0; i < 8; i++) {
static_graphics_[i] = rom_[rom_.version_constants().kOverworldGfxGroups2 +
(world_index_ * 8) + i];
(main_gfx_id_ * 8) + i];
}
}
@@ -221,7 +221,7 @@ void OverworldMap::LoadDeathMountainGFX() {
}
void OverworldMap::LoadAreaGraphics() {
LoadWorldIndex();
LoadMainBlocksetId();
LoadSpritesBlocksets();
LoadMainBlocksets();
LoadAreaGraphicsBlocksets();