mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 05:09:34 -06:00
DiscIO/Riivolution: Add dolphin-specific extensions "dolphin_sys_file" and "dolphin_sys_folder" to patch sys files like you would patch regular files.
This commit is contained in:
@ -458,15 +458,20 @@ static void ApplyFolderPatchToFST(const Patch& patch, const Folder& folder,
|
||||
ApplyFolderPatchToFST(patch, folder, fst, dol_node, folder.m_disc, folder.m_external);
|
||||
}
|
||||
|
||||
void ApplyPatchesToFiles(const std::vector<Patch>& patches,
|
||||
void ApplyPatchesToFiles(const std::vector<Patch>& patches, PatchIndex index,
|
||||
std::vector<DiscIO::FSTBuilderNode>* fst, DiscIO::FSTBuilderNode* dol_node)
|
||||
{
|
||||
for (const auto& patch : patches)
|
||||
{
|
||||
for (const auto& file : patch.m_file_patches)
|
||||
const auto& file_patches =
|
||||
index == PatchIndex::DolphinSysFiles ? patch.m_sys_file_patches : patch.m_file_patches;
|
||||
const auto& folder_patches =
|
||||
index == PatchIndex::DolphinSysFiles ? patch.m_sys_folder_patches : patch.m_folder_patches;
|
||||
|
||||
for (const auto& file : file_patches)
|
||||
ApplyFilePatchToFST(patch, file, fst, dol_node);
|
||||
|
||||
for (const auto& folder : patch.m_folder_patches)
|
||||
for (const auto& folder : folder_patches)
|
||||
ApplyFolderPatchToFST(patch, folder, fst, dol_node);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user