-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Qt: Allow loading custom pnach patches and bundled patches simultaneously #10322
Qt: Allow loading custom pnach patches and bundled patches simultaneously #10322
Conversation
Currently if one has patches from the patch folder, no bundled patches from the .zip file will be displayed. This changes it so that we can display both the folder patches AND the .zip bundled patches as long as their names don't collide. If there's a collision, the folder patch will override the bundled patch. Also, if an unlabeled patch is loaded from the folder then all bundled patches will be hidden (like they did prior) since we can't guarantee there's no collision.
Bundled patches don't display when unlabeled patches are loaded (since we can't guarantee they don't collide). This warns the user that bundled patches are hidden when unlabeled patches are loaded. (The warning hides when no unlabeled patches are loaded)
Fixes syntax error with console write format to display warning when bundled patches are hidden due to unlabeled patches being loaded.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The idea looks good, just leaving notes about some stylistic details. Untested.
Co-authored-by: Silent <[email protected]>
….com/Daniel-McCarthy/pcsx2 into AllowCustomPatchesWithDefaultPatches
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just two more comments, the implementation looks optimal.
Adds a better worded log statement for informing the user that a patch with a duplicate name was found and not loaded to avoid conflict. The common expected reason this can happen is a bundled patch having the same name as a /patches/ pnach patch having the same name. By default it will prioritize the folder patch over the bundled patch. Makes it more clear/less confusing in phrasing.
Addresses feedback to use consistent naming conventions as most variables are using snake_case. Also no longer passes string_view by reference as per feedback.
Fixed unintentionally non-sensical wording in log warning to inform the user that a patch was skipped over since a patch with the same name had already been loaded.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Untested on my end, but your testing steps sound reasonable to me.
Description of Changes
Implements #10242
Allow loading patch files from
/patches
folder and the bundledpatches.zip
file simultaneously./patches
folder and thepatches.zip
have the same name, it loads the/patches
folder version instead./patches
folder is loaded, no bundled patches will be loaded. (Since we can't guarantee they won't collide with a bundled patch)Also, updates the patches UI to display a warning when unlabeled patches are loaded and causing the bundled patches to not display in the Patches Settings window.
Rationale behind Changes
To allow users to use the bundled no-interlacing & widescreen patches with their custom patches. As long as there's no collisions, there's no need to stop them from using both.
Suggested Testing Steps
/patches
patch is shown in Patch Settings window.description=Should override bundled patch
field to the patch).In my case, I tested this in GTA 3 with this pnach file: