Refactor Room and RoomObject classes to remove inheritance from SharedRom, enhancing code clarity and maintainability. Introduce ROM pointer management in both classes for improved functionality. Update LoadRoomFromRom to accommodate new constructor signature.
This commit is contained in:
@@ -75,7 +75,7 @@ RoomSize CalculateRoomSize(Rom *rom, int room_id) {
|
||||
}
|
||||
|
||||
Room LoadRoomFromRom(Rom *rom, int room_id) {
|
||||
Room room(room_id);
|
||||
Room room(room_id, rom);
|
||||
|
||||
int header_pointer = (rom->data()[kRoomHeaderPointer + 2] << 16) +
|
||||
(rom->data()[kRoomHeaderPointer + 1] << 8) +
|
||||
|
||||
Reference in New Issue
Block a user