Skip to content

Conversation

@WorstAquaPlayer
Copy link

@WorstAquaPlayer WorstAquaPlayer commented Jan 7, 2022

  • Updated projects to .NET 6. This was required to use the latest version of Lemon.
  • Removed XdeltaSharp.dll and added XdeltaSharp NuGet package.
  • Implemented 3DS .CIA patching. This can be done in two ways:
    Generic: Extracts the binaries of the content to patch (RomFS or ExeFS for example), patch them as-is, and then re-pack it into a new .CIA
    Specific: Extracts the contents to patch and its containers, patch the specific files, and then re-pack the container to be able to make a new .CIA (Only RomFS and ExeFS are supported in specific patching).
  • The way the patch .json is generated makes possible patching other content such as the manual.
  • Slight changes to the tester, allowing to test processes that have a file input and output.
  • Added an argument to ApplyXdelta to allow it to use only FileStreams instead of using a MemoryStream.

Sample .json lines for Generic patching:

    "ListOriFiles": [
      "manual\\rom",
      "program\\rom"
      "program\\system"
    ],
    "ListXdeltaFiles": [
      "manual\\rom.xdelta",
      "program\\rom.xdelta"
      "program\\system.xdelta"
    ]

Sample .json lines for Specific patching:

    "ListOriFiles": [
      "manual\\rom\\Manual.bcma"
      "program\\rom\\archive\\chr201_eng.arc"
      "program\\system\\.code",
    ],
    "ListXdeltaFiles": [
      "manual\\rom\\Manual.bcma.xdelta"
      "program\\rom\\archive\\chr201_eng.arc.xdelta"
      "program\\system\\.code.xdelta",
    ]

Also removed XdeltaSharp.dll and added the XdeltaSharp Nuget.
To do this, the directory checking at the start was slightly modified since the 3DS relies on an input and output .cia file.
@Darkmet98 Darkmet98 self-requested a review January 7, 2022 22:28
@Darkmet98 Darkmet98 self-assigned this Jan 7, 2022
Turns out there was an NodeContainer to ExeFS binary converter in Lemon, I just didn't see it. Also, made some small fixes to the tester.
Some small fixes to the tester as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants