Ren'Py - Modifications directly in NSP files / repack

darkangel5000

Well-Known Member
OP
Member
Joined
Apr 26, 2008
Messages
394
Trophies
1
Age
33
Location
Unna, ~Dortmund :3
XP
1,244
Country
Germany
Hey there.
After I've succesfully used LayeredFS to mod Artemis Engine visual novels back to their "original" state, it looks like I've run into a brick wall when it comes to Ren'Py-games.

One example of this would be the VN Summer Days, which comes with the same renpygame\game\main\story\script_main.rpyc file as the uncensored PC version.
The problem lies within the fact that the romFS includes another renpygame\game\tl\clean\main\story\script_main.rpyc-file, which is used to remove certain text passages on the Switch version.
If I use atmosphere's LayeredFS to replace that second script_main.rpyc with another valid .rpyc from the Switch version, the game won't boot. If I replace it with an empty file, it won't boot.

After some extensive testing I suspect that the modification could work, if the second script_main.rpyc wouldn't exist in the first place.
If this approach is falsified, it would at least lead to two possible outcomes:
a) Open another possibility of working with the decrypted .rpy-files
b) Give me peace of mind, knowing that it's not possible to do for me, with my current skillset.
And option a) would again require me to delete the original .rpyc-files, before they are loaded automatically.

I've looked at a great bunch of documentation in the past few days, I have at least the slightest of ideas of how to build an NSP out of .cert, .tik and .nca files - but I can't seem to get to the point, where I could build an NSP either out of the raw romFS/exeFS folders OR at least how to repack the romFS folder to an NCA file.

So, Is there any feasible way to do this or am I just building castles in the sky?
 

masagrator

The patches guy
Developer
Joined
Oct 14, 2018
Messages
6,312
Trophies
3
XP
12,108
Country
Poland
so tl;dr you want from game to not detect that this second file exists at all?
if this path is hardcoded into executable, you can make exefs patch. If not, you can make skyline plugin and hook nn::fs::openfile to throw "file not detected" on this path.

If you can upload "main" file from exefs here, I can look at that.
Hopefully game doesn't use NROs
 

Impossible_Igntiz

Well-Known Member
Member
Joined
Nov 16, 2018
Messages
422
Trophies
0
Location
Bonerville
XP
1,181
Country
United States
Hey there.
After I've succesfully used LayeredFS to mod Artemis Engine visual novels back to their "original" state, it looks like I've run into a brick wall when it comes to Ren'Py-games.

One example of this would be the VN Summer Days, which comes with the same renpygame\game\main\story\script_main.rpyc file as the uncensored PC version.
The problem lies within the fact that the romFS includes another renpygame\game\tl\clean\main\story\script_main.rpyc-file, which is used to remove certain text passages on the Switch version.
If I use atmosphere's LayeredFS to replace that second script_main.rpyc with another valid .rpyc from the Switch version, the game won't boot. If I replace it with an empty file, it won't boot.

After some extensive testing I suspect that the modification could work, if the second script_main.rpyc wouldn't exist in the first place.
If this approach is falsified, it would at least lead to two possible outcomes:
a) Open another possibility of working with the decrypted .rpy-files
b) Give me peace of mind, knowing that it's not possible to do for me, with my current skillset.
And option a) would again require me to delete the original .rpyc-files, before they are loaded automatically.

I've looked at a great bunch of documentation in the past few days, I have at least the slightest of ideas of how to build an NSP out of .cert, .tik and .nca files - but I can't seem to get to the point, where I could build an NSP either out of the raw romFS/exeFS folders OR at least how to repack the romFS folder to an NCA file.

So, Is there any feasible way to do this or am I just building castles in the sky?
Hi, i was looking into making an uncensored mod for Summer Days and was wondering if you how to decrypt or in this re-encrypt the un-readable .png files the game uses on the Switch port?
 

darkangel5000

Well-Known Member
OP
Member
Joined
Apr 26, 2008
Messages
394
Trophies
1
Age
33
Location
Unna, ~Dortmund :3
XP
1,244
Country
Germany
so tl;dr you want from game to not detect that this second file exists at all?
if this path is hardcoded into executable, you can make exefs patch. If not, you can make skyline plugin and hook nn::fs::openfile to throw "file not detected" on this path.

If you can upload "main" file from exefs here, I can look at that.
Hopefully game doesn't use NROs
Yup, that's exactly what I want. So thanks, I'll take a look into Skyline, as theoretically Ren'Py should just dynamically load rpyc files it finds in the \game directory
Regarding the file I'll shoot you a DM when I get home.

Hi, i was looking into making an uncensored mod for Summer Days and was wondering if you how to decrypt or in this re-encrypt the un-readable .png files the game uses on the Switch port?
There's zero need to work with the scrambled .pngs, as Ren'Py on Switch works just fine with regular .png files.
I.e. you can just use UnRen to unpack the main.rpa from the PC version and use those assets via LayeredFS.
 
Last edited by darkangel5000,

Impossible_Igntiz

Well-Known Member
Member
Joined
Nov 16, 2018
Messages
422
Trophies
0
Location
Bonerville
XP
1,181
Country
United States
Yup, that's exactly what I want. So thanks, I'll take a look into Skyline, as theoretically Ren'Py should just dynamically load rpyc files it finds in the \game directory
Regarding the file I'll shoot you a DM when I get home.


There's zero need to work with the scrambled .pngs, as Ren'Py on Switch works just fine with regular .png files.
I.e. you can just use UnRen to unpack the main.rpa from the PC version and use those assets via LayeredFS.
Really? everytime i tried doing that, it never worked with me.... is there a directory folder or files i'm missing to do so?

Edit: YO!!!!!! That method you told me actually worked!!!!! Thank you very much!!!! :D
 
Last edited by Impossible_Igntiz,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • Xdqwerty @ Xdqwerty:
    @The Real Jdbye, and the HD collections released for 7th gen consoles too
  • The Real Jdbye @ The Real Jdbye:
    but they don't seem to have done any of those for the switch yet and maybe never will
  • ColdBlitz @ ColdBlitz:
    I think we all forgot breath of the wild released for the wii u tbh
    +1
  • Xdqwerty @ Xdqwerty:
    @The Real Jdbye, tbh the HD collections are more justified since they include more than just 1 game per copy
  • Xdqwerty @ Xdqwerty:
    @SylverReZ I read that non-binary people identify as a blend of male and female. The point is i think i'm a blend of those and thus non binary
  • SylverReZ @ SylverReZ:
    @Xdqwerty, Non-binary people are those who don't identify themselves exclusively as male or female.
  • cearp @ cearp:
    I don't identify as anything, unless I need to get on a plane then I show ID
    +3
  • AncientBoi @ AncientBoi:
    👈 [homo, queer, fag, coksuqr, etc......]
    +3
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, I meant that I read that they can also identify as what i mentioned
    +2
  • BigOnYa @ BigOnYa:
    I identify as Long Rod Johnson, cause a cat called me that once.
    +2
  • AncientBoi @ AncientBoi:
    [takes a 👀 in your pants] Liar :angry:
    +3
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, and thus that would make me non binary since i feel like a blend of both male and female
    +1
  • AncientBoi @ AncientBoi:
    @Xdqwerty only time will tell, what/whom you are. At 14, its a bit early to "Define" yourself. :)
    +3
  • Psionic Roshambo @ Psionic Roshambo:
    I only recently have learned who I am and how much I am capable of and I'm 50 lol
    +3
  • Psionic Roshambo @ Psionic Roshambo:
    A thousand epiphanies and unbelievable pain and growth.
    +2
  • Psionic Roshambo @ Psionic Roshambo:
    I wish I could sum it up for children to understand but it truly takes living a lifetime of learning
    +2
  • Psionic Roshambo @ Psionic Roshambo:
    It's more than knowledge it's understanding
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    Both are required
  • Xdqwerty @ Xdqwerty:
    @Psionic Roshambo, ask chatgpt or Google gémini to summarize it
  • Psionic Roshambo @ Psionic Roshambo:
    Lol summarize life's lessons
  • BigOnYa @ BigOnYa:
    My wifey tells me all the time "You need to grow the fuck up." Which I don't understand, cause I'm full grown already.
    +2
  • Xdqwerty @ Xdqwerty:
    @BigOnYa, she means grow more
    +1
  • Xdqwerty @ Xdqwerty:
    Yawn
  • AncientBoi @ AncientBoi:
    farrrrrrrrrrrt
    +1
    AncientBoi @ AncientBoi: farrrrrrrrrrrt +1