Tutorial  Updated

How to use LayeredFS for Backup Loading + What Games Work/Don't

This thread is outdated
A lot of information in this thread is heavilly out of date.
If you have time, and have Staff permission, feel free to edit this thread and remove this statement once necessary.

Some information that needs to be addressed:
  • SX OS and Atmosphere now supports proper LayeredFS, instructions for using it has changed since this tutorial was made
  • Supported Firmware information is out of date
  • LFSKit needs to be updated to properly support non 5.x.x firmware
  • Compatability chart needs to be re-made
-PRAGMA


WARNING
  • DO NOT GO ONLINE WHEN DOING THIS (YOU WILL BE BANNED)


How to use LayeredFS for Backup Loading

Firmware Supported: ONLY 5.x.x
Use the PRAGMA LFS Kit below.

PRAGMA's LFS Kit

DOWNLOAD
SOURCE

  • Go from NOTHING in your SD Card to playing a game backup in a few clicks!
  • Decrypt .XCI -> romfs/exefs folder with main.nmpd auto edited aswell as folder's name auto renamed to donor titleid
  • Download NOTHING except LFSKit!
ENJOY!

yyTJ8rr.gif


Picking a Donor Title and getting Donor TitleIDRunning Game Backups!


    1. A donor title is the application we will run to open the backup.
      Pick a game you don't care about (Download a Demo or a free game from eShop, for example Octopath Demo)
      saves are something no one knows much about, we don't fully know where or how they are stored.
      They might overwrite the donor titles save, so seriously pick a game you DONT care about, not a game you rarely play.

    2. I also recommend picking a donor title/game combo that has been tested and reported working just so you know if YOU did something wrong or not.
    3. Find the TitleID of the donor title you chose from http://nswdb.com or http://switchbrew.org/index.php?title=Title_list/Games
      Region must be the same, choose the TitleID for the base-game NOT for the update title, even if your updated.

    1. Once again, boot into Hekate-IPL (Step 1).
    2. Enter "Launch firmware" and select "RomFS".
    3. Your now in your system's home menu.
    4. Open the Donor Title you set the TitleID of on that folder and .npmd file earlier.
    5. The game will load up flawlessly.
      If you opened the Title lets say, Fortnite, and Fortnite booted, the titleid of the folder in sd:/atmosphere/titles/{fortnitetitleid} doesnt exist, or doesnt start with 0100.
      If it gives you an error screen, either you didnt edit the main.npmd properly, or its an incompatible title/donor combo.
    To see which games work and which dont using which donor titles, look below.
    If you notice that you used a combination of Game and Donor title that isnt in the list below, post in the thread and I will add it. (look under to see what I need to add to chart).


Troubleshooting

  • Black Screen/Infinitely Loading
    Leave it for around 5 minutes then press the home button and go back into the game without closing it. Often this can do the job.
  • Freeze when Loading
    Close the game and try again, its a common occurence, you may have to try up to 4-5 times before getting it to work, sometimes you may even have to reboot between retries.
 
Last edited by PRAGMA,

PRAGMA

Well-Known Member
OP
Member
Joined
Dec 29, 2015
Messages
2,258
Trophies
1
Location
Ireland
Website
github.com
XP
5,039
Country
Ireland
Hey, just adding a few precisions there.
You don't need to use copyrighted stuff for layeredfs, you can patch your own kernel.
Here's the source code for it (the full one, credits to Scires and Reswitched for fusee-secondary): kernelpatcher.zip, you need VS2017.
Thanks again to someone for sharing the binary without my permission and not sharing the full code with it, especially on Simon's server.
The real binary: kernelpatches.exe (others may be virus'd, we never know).
Just put a 5.x kernel.bin in the directory, you can get it with hactool and your package2 (remove the leading 0s with a hex editor).
For kernal.bin, where do we get that, you say package2, so eMMC SYS in Hekate? And its then the file named "SYSTEM"?
 

thomasnet

Well-Known Member
Member
Joined
Mar 6, 2016
Messages
175
Trophies
0
XP
579
Country
France
For kernal.bin, where do we get that, you say package2, so eMMC SYS in Hekate? And its then the file named "SYSTEM"?
If you have a full NAND dump, use HacDiskMount to dump the first Bcpkg2 (no need to put BIS keys in).
Open up a hex editor, remove the leading 0s.
Then use the resulting bin with hactool -tpk21 --outdir DIRECTORY PACKAGE2BIN and you have your Kernel.bin.
 

PRAGMA

Well-Known Member
OP
Member
Joined
Dec 29, 2015
Messages
2,258
Trophies
1
Location
Ireland
Website
github.com
XP
5,039
Country
Ireland
If you have a full NAND dump, use HacDiskMount to dump the first Bcpkg2 (no need to put BIS keys in).
Open up a hex editor, remove the leading 0s.
Then use the resulting bin with hactool -tpk21 --outdir DIRECTORY PACKAGE2BIN and you have your Kernel.bin.
With CTCaers eMMC Sys it dumps only BCPKG2 files. But which one do we need exactly? 1-Normal-Main?
And do you need -k keys.x for the hactool for pkg2bin?


Nice!
I got it,
3FaPJbc.png
 
Last edited by PRAGMA,

thomasnet

Well-Known Member
Member
Joined
Mar 6, 2016
Messages
175
Trophies
0
XP
579
Country
France
With CTCaers eMMC Sys it dumps only BCPKG2 files. But which one do we need exactly? 1-Normal-Main?
And do you need -k keys.x for the hactool for pkg2bin?
Yep, it's 1-Normal-Main. And you do need the keys, I just didn't specify the options because I put them in ~/.switch/prod.keys.
 
  • Like
Reactions: PRAGMA

Hodorian

Well-Known Member
Newcomer
Joined
May 23, 2018
Messages
59
Trophies
0
Age
31
XP
350
Country
Germany
if someone is interested in a python script to change the title Id:
here https://pastebin.com/qpcEiBzf

and if you add
Code:
python mainRenamer.py "xciDecrypted\exefs\main.npdm" 010025400AECE000
rename xciDecrypted 010025400AECE000

to the "Decrypt-XCI-v2.1.bat", you have a full auto fortnite patch generator
 

jakkal

Well-Known Member
Member
Joined
Apr 27, 2018
Messages
2,303
Trophies
1
Age
44
XP
3,982
Country
United States
can someone link me to the hekate mod that has the romfs feature
because the latest release i found on github doesnt have that option listed

edit: figured it out
 
Last edited by jakkal,

Dekirai

Well-Known Member
Member
Joined
Jun 21, 2016
Messages
1,050
Trophies
0
XP
2,625
Country
Germany
Update on Hyrule Warriors with Fallout


Injected Game: Hyrule Warriors Definitive Edition
Donor Game: Fallout Shelter
Firmware: 5.1.0
Boots: Yes > Crashes after the first campaign map, maybe includes more crashes
Saves: Yes
 
  • Like
Reactions: rainbowkittypaw

hoangsonx

New Member
Newbie
Joined
Jun 16, 2018
Messages
1
Trophies
0
Age
33
XP
63
Country
Vietnam
My list: running and save OK.

Donor game first

Axiom Verge / Kirby star allies
Has-Been Heroes / Bayonetta 2
Double Dragon 4 / Ben 10
Death Squared / Fire Emblem Warriors
Stardew Valley / Battle Chasers - Nightwar

.........
 

KevinX8

Proud user of The Dark Theme
Member
Joined
May 12, 2016
Messages
960
Trophies
0
Age
33
Location
Down there
XP
1,013
Country
I also have a theory on why some games work but others don't. if you looks at the exefs of a game it's identical for every game (in terms of files, not sizes) apart from the files labeled "subsdk(X)". Some games have only 1 (X=0) and others have multiple. As layered fs just replaces files (it's original purpose is modding afterall) and the donor rom has > of these files than target game they won't all be replaced and the switch will attempt to load the remaining files. This probably causes the bootloops and infinite loads. So according to my theory fortnite should be one of those games with only one of these files if it is correct, someone should dump to check :D
 
Last edited by KevinX8,

skydancer93

Well-Known Member
Member
Joined
Mar 16, 2015
Messages
585
Trophies
0
Age
30
XP
1,982
Country
United States
Here’s my findings as I decided to try it out:

All work on 5.1.0 except where noted

Ittle Dew 2 = Fortnite

Tiny Barbarian DX = Fallout Shelter

Wild Guns Reloaded = Pokemon Quest

Azure Striker Gunvolt Deluxe Pack = Octopath Demo(NOT WORKING)

The Longest Five Minutes = Octopath Demo

Penny Punching Princess = Pinball FX3
 

TotalJustice

Well-Known Member
Member
Joined
Jan 28, 2017
Messages
445
Trophies
0
Age
26
XP
2,621
Country
United Kingdom
game: megaman collection
donor: Octopath demo
boot: YES (read notes)
save: YES
note: the switch intro logo will stick, press home and to get rid of it. Also game crashes first ever time loading.

game: mk8
donor: voez demo
boot: nah
save: nada
 
  • Like
Reactions: hippy dave and Ty_

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: Creamy milk