Repository navigation
feat: add read-only My Pokemon Ranch extraction - #71
Open
NewBarkTownKris wants to merge 1 commit into
Open
NewBarkTownKris wants to merge 1 commit into
NewBarkTownKris wants to merge 1 commit into
Conversation
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.
Open original Diamond/Pearl My Pokémon Ranch saves as read-only storage: browse the actual capacity, copy Pokémon to the Bank, and export native RK4 records. The existing generic reader path does not validate Ranch's SHA-1 or safely distinguish this source from writable saves.
Validate the checksum, header, block bounds, object arrays, capacity, and ownership types before invoking the pinned reader. Expose a read-only capability through Domain, enforce it in engine mutations and the safe writer (including restores and risk overrides), and hide source edit/deposit/withdraw actions while keeping copy/export available. Ranch has no party; its last page exposes only real slots. Serialization preserves the original bytes. Other formats keep their existing defaults and write pipeline.
Dolphin discovery recognizes the USA Ranch main
savedata.bin, excludes its backup, and handles both title-ID folder layouts and Android document-provider paths. A format-conversion warning explains loss of Ranch ownership metadata. No new navigation screen, dependencies, assets, or submodule changes are introduced.Scope: original DP-format Ranch, verified with USA saves. The unverified Platinum revision is refused; this PR does not add Ranch write support. Native Bank-copy editing is handled by the separate companion fix, #70; merging that fix first avoids losing Ranch-only metadata when subsequently editing a copied record. Both branches start from
devand merge together cleanly.Verification:
.local-testdata/and are not required in CI.Format evidence: existing pinned SAV4Ranch reader and RK4 definition, cross-checked with private original-revision saves and synthetic fixtures. No ROMs, saves, APKs, or private logs are included. Branched from and targeting
dev, following the contribution instructions.