diff options
author | Morph <39850852+Morph1984@users.noreply.github.com> | 2021-06-28 16:07:40 +0200 |
---|---|---|
committer | Morph <39850852+Morph1984@users.noreply.github.com> | 2021-06-28 16:14:36 +0200 |
commit | 511ee03a21f0f47c46afe51125aad7b9b8c980c8 (patch) | |
tree | 6ec03bc6e2fdaa3d9919e32c2e7d5b9ae736a6f7 /src | |
parent | filesystem: Open a read-only directory for SDMC mods (diff) | |
download | yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar.gz yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar.bz2 yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar.lz yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar.xz yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.tar.zst yuzu-511ee03a21f0f47c46afe51125aad7b9b8c980c8.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/core/file_sys/patch_manager.cpp | 6 | ||||
-rw-r--r-- | src/core/file_sys/patch_manager.h | 3 | ||||
-rw-r--r-- | src/yuzu/main.cpp | 3 |
3 files changed, 8 insertions, 4 deletions
diff --git a/src/core/file_sys/patch_manager.cpp b/src/core/file_sys/patch_manager.cpp index 13d294ad8..7c0950bb0 100644 --- a/src/core/file_sys/patch_manager.cpp +++ b/src/core/file_sys/patch_manager.cpp @@ -407,7 +407,7 @@ static void ApplyLayeredFS(VirtualFile& romfs, u64 title_id, ContentRecordType t } VirtualFile PatchManager::PatchRomFS(VirtualFile romfs, u64 ivfc_offset, ContentRecordType type, - VirtualFile update_raw) const { + VirtualFile update_raw, bool apply_layeredfs) const { const auto log_string = fmt::format("Patching RomFS for title_id={:016X}, type={:02X}", title_id, static_cast<u8>(type)); @@ -447,7 +447,9 @@ VirtualFile PatchManager::PatchRomFS(VirtualFile romfs, u64 ivfc_offset, Content } // LayeredFS - ApplyLayeredFS(romfs, title_id, type, fs_controller); + if (apply_layeredfs) { + ApplyLayeredFS(romfs, title_id, type, fs_controller); + } return romfs; } diff --git a/src/core/file_sys/patch_manager.h b/src/core/file_sys/patch_manager.h index fb1853035..3be871f35 100644 --- a/src/core/file_sys/patch_manager.h +++ b/src/core/file_sys/patch_manager.h @@ -64,7 +64,8 @@ public: // - LayeredFS [[nodiscard]] VirtualFile PatchRomFS(VirtualFile base, u64 ivfc_offset, ContentRecordType type = ContentRecordType::Program, - VirtualFile update_raw = nullptr) const; + VirtualFile update_raw = nullptr, + bool apply_layeredfs = true) const; // Returns a vector of pairs between patch names and patch versions. // i.e. Update 3.2.2 will return {"Update", "3.2.2"} diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp index 08128effb..ece169a38 100644 --- a/src/yuzu/main.cpp +++ b/src/yuzu/main.cpp @@ -1922,7 +1922,8 @@ void GMainWindow::OnGameListDumpRomFS(u64 program_id, const std::string& game_pa if (*romfs_title_id == program_id) { const u64 ivfc_offset = loader->ReadRomFSIVFCOffset(); const FileSys::PatchManager pm{program_id, system.GetFileSystemController(), installed}; - romfs = pm.PatchRomFS(file, ivfc_offset, FileSys::ContentRecordType::Program); + romfs = + pm.PatchRomFS(file, ivfc_offset, FileSys::ContentRecordType::Program, nullptr, false); } else { romfs = installed.GetEntry(*romfs_title_id, FileSys::ContentRecordType::Data)->GetRomFS(); } |