RELEASE NSC_Builder. Nintendo Switch Cleaner and Builder. (Game+updates+dlc in a single xci)

Discussion in 'Switch - ROM Hacking, Saves, Translations & Tools' started by JRoad, Nov 4, 2018.

  1. WiiUAre

    WiiUAre Member

    Newcomer
    2
    Oct 10, 2014
    Netherlands
    Rijnsburg
    is there a difference between update mode (option 4) and multipack mode I you want to convert and update a game.nsp + update.nsp to game .xci
     
  2. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    If you use the beta the multipack mode there can do both things create and update and it'll give it a better naming. Also update mode was updated so it can create the files the first time.
     
  3. 18Phoenix

    18Phoenix GBAtemp Regular

    Member
    5
    Nov 21, 2005
    Germany
    Hi :)
    Is it already corrected ?
     
  4. KhenemetHeru

    KhenemetHeru Advanced Member

    Newcomer
    3
    Apr 22, 2015
    United States
    New Britain, CT
    Did a clean installation after using 0.79 for the longest time, and when I run 0.82 beta I get this error right away (and after every operation):
    File "c:\NSCB\ztools\squirrel.exe", line 1
    SyntaxError: Non-UTF-8 code starting with '\x90' in file C:\NSCB\ztools\squirrel.exe on line 1, but no encoding declared; see hxxx://python.org/dev/peps/pep-0263/ for details
    and then it quits. But if I use STABLE it works fine...

    also, can I convert an update NSP to standard crypto using this?
     
    Last edited by KhenemetHeru, Apr 19, 2019
  5. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    Did you use the one in releases or the one in the master? I'm asking because i saw that error before and it came down to github corrupting the exe files when downloading from the master, that's the reason i started zipping those in the master but i've got reports of people still getting corrupted files.
    The error only happened with the exes not the python version if you don't mind installing the dependencies. Still if you got it downloading from the master it should fix itself if you download from releases.
    No, i took a little break being eastern and all and didn't have time to touch things.
     
    Last edited by JRoad, Apr 19, 2019
  6. KhenemetHeru

    KhenemetHeru Advanced Member

    Newcomer
    3
    Apr 22, 2015
    United States
    New Britain, CT
    I got it from the zip file in releases. The python one didn't work for me the first time either, was looking for some old files, but a fresh download and clean install again fixed that apparently as the python beta is working smooth now.
     
  7. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    Hmm weird it happened that to you. Everytime i saw that error was a corrupt download from github. Maybe i'll start doing mediafire mirrors too just in case from next release, i don't know why it corrupt sometimes the exes.
     
    KhenemetHeru likes this.
  8. mathew77

    mathew77 Member

    Newcomer
    2
    Jan 19, 2019
    Norway
    .del.
     
    Last edited by mathew77, Apr 19, 2019
  9. KhenemetHeru

    KhenemetHeru Advanced Member

    Newcomer
    3
    Apr 22, 2015
    United States
    New Britain, CT
    Also can't seem to build a combined xci+update for MK11, it goes through the process successfully but the xci is bad, no info or icon.
     
  10. Tere Valentin

    Tere Valentin GBAtemp Fan

    Member
    4
    Nov 21, 2015
    United States
    First time using NSC Builder.

    Wanted to fused an xci MK11 with its update.

    Originally, the xci and nsp update separately was a total of 22.8gb.
    But when NSC finished, the new xci is 6.53gb in size.
    Is this normal?

    Edit: Noticed that during the fusing process, an error appears saying "failed to execute script squirrel" and stopped the process halfway.
    Is there a solution?
     
    Last edited by Tere Valentin, Apr 19, 2019
    leonmagnus99 likes this.
  11. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    Works fine for me, just tried.
    Pretty sure is because the update needs master_key_07 to rebuild the header and you don't have it in your keys.txt
    If i'm wrong and you have it check your keys file with this function (number 3):

    verify2.PNG
     
  12. KhenemetHeru

    KhenemetHeru Advanced Member

    Newcomer
    3
    Apr 22, 2015
    United States
    New Britain, CT
    It's in there, and it verified all ok.
     
  13. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    That was actually my answer to the other user. Yours doesn't seem the same error, i don't know if it can be due to your files or other thing but in my case i was able to build a working xci.
     
  14. huma_dawii

    huma_dawii GBAtemp Psycho!

    Member
    10
    Apr 3, 2014
    United States
    Planet Earth
    Is there a way to know If a XCI has any kind of tickets inside?
     
  15. masagrator

    masagrator File digger

    Member
    5
    Oct 14, 2018
    Poland
    Is it possible to write some documentation about squirrel.exe? Because I see it handles well last updates in contrast to hactool and I would like to use it to unpack NCAs.
     
  16. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    5- FILE-INFO mode -> 1.-FILE LIST of the xci\nsp is the cleanest way to see the files though nut info also gives you that.
    The main reason of squirrel not having it's own repo is that it's code is still dirty, since it has many methods ta¡hat do mostly the same.
    I can give you the functions either way, depending on what you need. What you want to do is just to extract the ncas from the nsp? because you'll still need hactool to merge the update nca + basegame nca, didn't add nca extraction to squirrel yet.
     
  17. masagrator

    masagrator File digger

    Member
    5
    Oct 14, 2018
    Poland
    Only what I want is extracting NCAs from NSP. Hactool shows PFS0 is broken, but it still handles unpacking NCA.
     
  18. markmcrobie

    markmcrobie GBAtemp Advanced Fan

    Member
    5
    May 24, 2008
    @JRoad here's an error I've not had before:

    Code:
    Calculating final content:
    Filename: Sports Party [0100DE9005170000] [v262144] (1G+1U)[nscb].xci
    Exception: local variable 'docheck' referenced before assignment
    Traceback (most recent call last):
      File "squirrel.py", line 3103, in <module>
      File "lib\sq_tools.py", line 908, in get_xciheader
      File "Fs\Hfs0.py", line 525, in gen_rhfs0_head
    IndexError: list index out of range
    [216] Failed to execute script squirrel
     
  19. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    Seems i'm using that variable before declaration (docheck), that seems like a bug on my part. Yeah I see where the issue is, my virtualbox machine got messed up and is what i use for the exe builds but i'll try to reinstall and issue a fix later.
     
  20. JRoad
    OP

    JRoad GBAtemp Advanced Fan

    Member
    6
    May 18, 2018
    Spain
    squirrel.exe --NSP_copy_nca "nsp file" for nca files
    squirrel.exe --NSP_copy_ticket "nsp file" for ticket
    squirrel.exe --NSP_other "nsp file" for other files (cert, xmls, jpgs,...)
    squirrel.exe --XCI_copy_nca_secure "xci file" for nca files in secure partition for xci

    Then if you need a specific output folder:
    squirrel.exe -o "output folder" --NSP_copy_nca "nsp file"
     
    masagrator likes this.
Loading...