feat: Enhance Dungeon Rendering with Size Adjustments and Testing Initialization

- Added InitializeForTesting method in Rom class to facilitate testing setup.
- Updated DungeonCanvasViewer to adjust object and sprite sizes from 16x16 to 8x8, improving rendering accuracy.
- Modified rendering logic for various dungeon objects (chests, doors, walls, pots) to reflect new size calculations.
- Adjusted object position calculations in ObjectRenderer to align with the new size metrics, ensuring consistent rendering across the application.
- Updated integration tests to verify the new initialization method for ROM objects.
This commit is contained in:
scawful
2025-10-05 17:27:32 -04:00
parent c1d93ce0d2
commit b21aeeb663
6 changed files with 61 additions and 66 deletions

View File

@@ -88,6 +88,11 @@ class Rom {
absl::Status LoadZelda3(const RomLoadOptions& options);
absl::Status LoadGfxGroups();
absl::Status InitializeForTesting() {
RETURN_IF_ERROR(LoadZelda3(RomLoadOptions::AppDefaults()));
return absl::OkStatus();
}
absl::Status SaveGfxGroups();
absl::Status SaveToFile(const SaveSettings& settings);
absl::Status SavePalette(int index, const std::string& group_name,