Repository navigation
Slim iOS build: selected DLC reaches the game folder and the app finds it - #212
Merged
Merged
Conversation
…s it Symptom: with the slim IPA, selected DLC was in neither the IPA nor games/<id>/, so saves that need it could not load (#202). Cause: the launcher copied <work>/aoc to games/<id>/aoc only in the success callback of the folder-packing process. The stamp reuse, image reuse and image copy branches returned before it. And main.m set DM_AOC_DIR only from <App>/aoc, which a slim IPA does not have. Fix: one placeAddOnContent step, called from all four ways the archive step ends. main.m (patch 0003) points DM_AOC_DIR at Documents/games/<id>/aoc when the per-game folder is in use and has one, before <App>/aoc and never over an explicit value. The layout is the one hle_fs.c aoc_dir reads (<index>.img). Compatible with seedds/nxnative#486 (Documents/aoc). Checks: swift build and swift test (361 tests), compile_check.py for 010015100B514000, patches.py check, scripts/tests, dm/ios/tests. Not tested on a device. Fixes #202
Collaborator
Author
|
@LNPANDY merged as a fix. A note for the release notes, since it changes what the iOS app does: patch 0003 now points |
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Fixes #202. Thank you, @imlfl, for the precise trace. Every claim in it held up in the code.
Symptom: with the default slim IPA, selected DLC was in neither the IPA nor
games/<id>/, so saves that need it could not load.Cause, two parts:
<work>/aocwas copied togames/<id>/aoconly in the success callback of the folder-packing process. The stamp reuse, image reuse and image copy branches returned before it.main.msetDM_AOC_DIRonly from<App>/aoc, which a slim IPA does not have. The per-game folder was never looked at.Fix:
ContentView.swift: oneplaceAddOnContentstep, called from all four ways the archive step can end.main.m): when the per-game folder is in use and has anaoc/,DM_AOC_DIRpoints there. It is set before the<App>/aocfallback and never over an explicitDM_AOC_DIR. The layout is whathle_fs.caoc_dir()reads (<index>.img), which is what the launcher writes (aoc/2.img).build_ipa.shis unchanged. This part relates to iOS: find a game's DLC (aoc/) in Documents before the app bundle seedds/nxnative#486 (DLC fromDocuments/aoc): the two stay compatible, because ours only fillsDM_AOC_DIRwhen it is not set. The patch's Reason says so.Checked
swift build -c releaseandswift test(361 tests, newAddOnContentCopyTests),patches.py check,scripts/tests,dm/ios/tests(new check intest_romfs_startup.py),compile_check.pyfor 010015100B514000.Scope
patches.py checkpassespending), and the aoc line goes with it