yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::editor::DungeonRoomLoader Class Reference

Manages loading and saving of dungeon room data. More...

#include <dungeon_room_loader.h>

Collaboration diagram for yaze::editor::DungeonRoomLoader:

Public Member Functions

 DungeonRoomLoader (Rom *rom)
 
absl::Status LoadRoom (int room_id, zelda3::Room &room)
 
absl::Status LoadAllRooms (std::array< zelda3::Room, 0x128 > &rooms)
 
absl::Status LoadRoomEntrances (std::array< zelda3::RoomEntrance, 0x8C > &entrances)
 
void LoadDungeonRoomSize ()
 
uint64_t GetTotalRoomSize () const
 
absl::Status LoadAndRenderRoomGraphics (zelda3::Room &room)
 
absl::Status ReloadAllRoomGraphics (std::array< zelda3::Room, 0x128 > &rooms)
 
const std::vector< int64_t > & GetRoomSizePointers () const
 
const std::vector< int64_t > & GetRoomSizes () const
 
const std::unordered_map< int, int > & GetRoomSizeAddresses () const
 
const std::unordered_map< int, ImVec4 > & GetRoomPalette () const
 

Private Attributes

Romrom_
 
std::vector< int64_t > room_size_pointers_
 
std::vector< int64_t > room_sizes_
 
std::unordered_map< int, int > room_size_addresses_
 
std::unordered_map< int, ImVec4 > room_palette_
 
uint64_t total_room_size_ = 0
 

Detailed Description

Manages loading and saving of dungeon room data.

This component handles all ROM-related operations for loading room data, calculating room sizes, and managing room graphics.

Definition at line 21 of file dungeon_room_loader.h.

Constructor & Destructor Documentation

◆ DungeonRoomLoader()

yaze::editor::DungeonRoomLoader::DungeonRoomLoader ( Rom rom)
inlineexplicit

Definition at line 23 of file dungeon_room_loader.h.

Member Function Documentation

◆ LoadRoom()

absl::Status yaze::editor::DungeonRoomLoader::LoadRoom ( int  room_id,
zelda3::Room room 
)

◆ LoadAllRooms()

◆ LoadRoomEntrances()

absl::Status yaze::editor::DungeonRoomLoader::LoadRoomEntrances ( std::array< zelda3::RoomEntrance, 0x8C > &  entrances)

Definition at line 128 of file dungeon_room_loader.cc.

References yaze::Rom::is_loaded(), and rom_.

Referenced by yaze::editor::DungeonEditorV2::Load().

Here is the call graph for this function:

◆ LoadDungeonRoomSize()

void yaze::editor::DungeonRoomLoader::LoadDungeonRoomSize ( )

Definition at line 145 of file dungeon_room_loader.cc.

References room_size_addresses_, room_sizes_, and total_room_size_.

Referenced by LoadAllRooms().

◆ GetTotalRoomSize()

uint64_t yaze::editor::DungeonRoomLoader::GetTotalRoomSize ( ) const
inline

Definition at line 32 of file dungeon_room_loader.h.

References total_room_size_.

◆ LoadAndRenderRoomGraphics()

absl::Status yaze::editor::DungeonRoomLoader::LoadAndRenderRoomGraphics ( zelda3::Room room)

◆ ReloadAllRoomGraphics()

absl::Status yaze::editor::DungeonRoomLoader::ReloadAllRoomGraphics ( std::array< zelda3::Room, 0x128 > &  rooms)

Definition at line 195 of file dungeon_room_loader.cc.

References yaze::Rom::is_loaded(), LoadAndRenderRoomGraphics(), and rom_.

Here is the call graph for this function:

◆ GetRoomSizePointers()

const std::vector< int64_t > & yaze::editor::DungeonRoomLoader::GetRoomSizePointers ( ) const
inline

Definition at line 39 of file dungeon_room_loader.h.

References room_size_pointers_.

◆ GetRoomSizes()

const std::vector< int64_t > & yaze::editor::DungeonRoomLoader::GetRoomSizes ( ) const
inline

Definition at line 40 of file dungeon_room_loader.h.

References room_sizes_.

◆ GetRoomSizeAddresses()

const std::unordered_map< int, int > & yaze::editor::DungeonRoomLoader::GetRoomSizeAddresses ( ) const
inline

Definition at line 41 of file dungeon_room_loader.h.

References room_size_addresses_.

◆ GetRoomPalette()

const std::unordered_map< int, ImVec4 > & yaze::editor::DungeonRoomLoader::GetRoomPalette ( ) const
inline

Definition at line 42 of file dungeon_room_loader.h.

References room_palette_.

Member Data Documentation

◆ rom_

Rom* yaze::editor::DungeonRoomLoader::rom_
private

◆ room_size_pointers_

std::vector<int64_t> yaze::editor::DungeonRoomLoader::room_size_pointers_
private

Definition at line 47 of file dungeon_room_loader.h.

Referenced by GetRoomSizePointers(), and LoadAllRooms().

◆ room_sizes_

std::vector<int64_t> yaze::editor::DungeonRoomLoader::room_sizes_
private

Definition at line 48 of file dungeon_room_loader.h.

Referenced by GetRoomSizes(), LoadAllRooms(), and LoadDungeonRoomSize().

◆ room_size_addresses_

std::unordered_map<int, int> yaze::editor::DungeonRoomLoader::room_size_addresses_
private

Definition at line 49 of file dungeon_room_loader.h.

Referenced by GetRoomSizeAddresses(), LoadAllRooms(), and LoadDungeonRoomSize().

◆ room_palette_

std::unordered_map<int, ImVec4> yaze::editor::DungeonRoomLoader::room_palette_
private

Definition at line 50 of file dungeon_room_loader.h.

Referenced by GetRoomPalette(), and LoadAllRooms().

◆ total_room_size_

uint64_t yaze::editor::DungeonRoomLoader::total_room_size_ = 0
private

Definition at line 51 of file dungeon_room_loader.h.

Referenced by GetTotalRoomSize(), and LoadDungeonRoomSize().


The documentation for this class was generated from the following files: