Tool Ren'Py UnRen.bat v1.0.11d - RPA Extractor, RPYC Decompiler, Console/Developer Menu Enabler

5.00 star(s) 9 Votes

DuDraig

Well-Known Member
Oct 6, 2017
1,258
429
Can anyone help me with this error? unren is unable to extract rpyc files.

(The "importerror: No module named decompiler" problem)

View attachment 877985
I know it's been awhile since this was asked but I just recently ran into it with Tales From The Unending Void and the poor poster never got an answer to their question.

When run on Windows, the decompiler module is created by unren as a temporary folder that is removed along with the other temporary files when decompilation is done. The reason the temporary rpyc decompiler python file can not find the module folder is because python does not like some character in the folder path; probably the parenthesis in the game folder name ("TFTUV-0.8-Extra Scenes Edition (PC)").

Renaming the game folder without the parenthesis is what worked for me using unren 0.91. Hopefully, this will help other people with the same problem with other games.
 
Last edited:

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
I know it's been awhile since this was asked but I just recently ran into it with Tales From The Unending Void and the poor poster never got an answer to their question.

When run on Windows, the decompiler module is created by unren as a temporary folder that is removed along with the other temporary files when decompilation is done. The reason the temporary rpyc decompiler python file can not find the module folder is because python does not like some character in the folder path; probably the parenthesis in the game folder name ("TFTUV-0.8-Extra Scenes Edition (PC)").

Renaming the game folder without the parenthesis is what worked for me using unren 0.91. Hopefully, this will help other people with the same problem with other games.
And in general, this is a rule of good taste: rename the folder so that there is nothing superfluous in the name, but it is clear what is in it. (y)
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
A small update. As you can see from the screenshot #1, the top menu and the lone TextEdit at the bottom were added. The latter is added so that you can track the path to the folder with the game or with games. The first menu item contains only the exit button. The second menu item is setting up work with one or more games. If the check mark is opposite One, then the program will work with a single game(see screenshot #2), if opposite Many, then you are a rich daddy(or mommy) and everything works for you as usual. From invisible - added functions for working with the settings file. Now, whatever settings you choose in the application(including working with one or more files), it will remember them(Until someone's playful hands want to delete the ini file with the settings). Do you think it's better to save automatically or ask the user every time?
1617646985838.png 1617647944048.png
 
  • Like
Reactions: yoyomistro

Madeddy

Active Member
Dec 17, 2017
835
484
Can anyone help me with this error? unren is unable to extract rpyc files.

View attachment 877985
....and the poor poster never got an answer to their question.
...
Clearly a wrong statement.
He got three answers and the last did explain whats the problem. post-4452620

...
The reason the temporary rpyc decompiler python file can not find the module folder is because python does not like some character in the folder path; probably the parenthesis in the game folder name ("TFTUV-0.8-Extra Scenes Edition (PC)").
...
Has nothing to do with UnRen. Its a old Batch problem and well known not to use parens in paths. Such problems where the reason why they did develop powershell back there and i guess also in the last years the new Windows Terminal.

Just to be clear: It's good general advise from you to people to hold their paths clean from parens (and other trash) but wasn't the problem of Sky12. I always advocate the use of underline and hyphen chars to put some naming separation in, but never whitespace. Also to note, a leading dot should not be used as it gives us a hidden file in *nix type OS.

In his screenshot is also to see he has no special stuff in the path beside the annoying(imo) white-space.

Greets

Btw: unrpyc v1.1.6 was released.
 
Last edited:

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
Btw: unrpyc v1.1.6 was released.
1. I moved the new version to python 3.:WeSmart:
2. I shouldn't have gotten into this. It was harder than I expected.:WutFace:
3. There are really a lot of additions in the code.:PogChamp:
4. Tested on our favorite game Mythos, everything works like clockwork. (y)
 

Madeddy

Active Member
Dec 17, 2017
835
484
2. I shouldn't have gotten into this. It was harder than I expected.:WutFace:
Hm. Hard is good in some cases i'd say. Others need Viagra. :sneaky: And if you dont like coding hard you should really not playing porn games before work.
3. There are really a lot of additions in the code.:PogChamp:
In what? In the update or in the py3 port?
v1.1.6 has just a few fixes:
1. Some small errors they fixed in the deobfuscate.py which i noticed last month.
2. The fix for the bug in Mythos you found in Feb: https://f95zone.to/threads/unren-ba...sole-developer-menu-enabler.3083/post-5150185
3. A workaround for missing multiprocessing in some python install i made in January already.

If you added to the new v1.1.6 all the py3 port changes then you did it the long way i'd say. :KEK: Adding just the bugfix changes to the 3port is faster i think. :LOL:
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
Hm. Hard is good in some cases i'd say. Others need Viagra. :sneaky: And if you dont like coding hard you should really not playing porn games before work.
In what? In the update or in the py3 port?
v1.1.6 has just a few fixes:
1. Some small errors they fixed in the deobfuscate.py which i noticed last month.
2. The fix for the bug in Mythos you found in Feb: https://f95zone.to/threads/unren-ba...sole-developer-menu-enabler.3083/post-5150185
3. A workaround for missing multiprocessing in some python install i made in January already.

If you added to the new v1.1.6 all the py3 port changes then you did it the long way i'd say. :KEK: Adding just the bugfix changes to the 3port is faster i think. :LOL:
It would be easier if I had a normal comparison tool, but, unfortunately, I have not yet got one(and the ones that are, I am not satisfied). As for the new code, well, at least that's how it felt when I trans the code for python 3. It feels like there are more places with problems than there were before. :unsure:
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
You know this? And if you need more options to knock your self out:
Strange. This hasnt changed id say.
Yes, I have already checked, indeed, the changed places are quite a bit. But, until I checked the versions through the tool, it seemed that there were more such places. I have already done my research on these tools and chose WinMerge. But I would like something built into the development environment or editor with the appropriate functionality, so as not to run +100500 programs to improve the quality of life of the programmer.:HideThePain:
 

yoyomistro

Engaged Member
Jan 15, 2017
2,927
3,930
You know this? And if you need more options to knock your self out:
Strange. This hasnt changed id say.
I'm partial to WinMerge, never heard of Meld, but they look like they do the exact same thing. WinMerge looks nicer and is extremely robust. Looks like the GIT-Tower blog you listed has a bunch of resources for different things, I might have to check some of those tools out. I also use an open source GREP tool for windows with regex search capabilities . Between those two I can mod most Ren'Py games pretty easily and carry over changes between versions.
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
I'm partial to WinMerge, never heard of Meld, but they look like they do the exact same thing. WinMerge looks nicer and is extremely robust. Looks like the GIT-Tower blog you listed has a bunch of resources for different things, I might have to check some of those tools out. I also use an open source GREP tool for windows with regex search capabilities . Between those two I can mod most Ren'Py games pretty easily and carry over changes between versions.
Something is a complicated and incomprehensible thing. Why do you need see changes between different versions of RenPy games? Do you write mods or something similar? :unsure:
 

yoyomistro

Engaged Member
Jan 15, 2017
2,927
3,930
Something is a complicated and incomprehensible thing. Why do you need see changes between different versions of RenPy games? Do you write mods or something similar? :unsure:
I make extensive changes to games sometimes, like if they are really grindy, put in no rollback statements before every dialogue block, have annoying resource systems, have a lot of "pathing" for things I want to see without replaying the game or doing label jumps, have typos that I find annoying, or are developed by people who make simple scripting mistakes often and they carry over between versions. Sometimes I post the changes I make if it's not going to take much maintenance/something game breaking that I can fix easily for a lot of people, but usually I just change things to suit my tastes/playstyle.

So if I download a new version of the game, I want to be able to transfer in the changes I've made without messing up any new scripts/overwriting modified scripts, and WinMerge makes it easy and fast to copy changes over.

EDIT: Sometimes I use GREP to make replacements between versions, like for a no rollback block or a consistently mispelled word, since it's faster/easier. I also use GREP for RPGM games, then find the files I'm looking for in the engine, it's a really great tool.
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
I make extensive changes to games sometimes, like if they are really grindy, put in no rollback statements before every dialogue block, have annoying resource systems, have a lot of "pathing" for things I want to see without replaying the game or doing label jumps, have typos that I find annoying, or are developed by people who make simple scripting mistakes often and they carry over between versions. Sometimes I post the changes I make if it's not going to take much maintenance/something game breaking that I can fix easily for a lot of people, but usually I just change things to suit my tastes/playstyle.

So if I download a new version of the game, I want to be able to transfer in the changes I've made without messing up any new scripts/overwriting modified scripts, and WinMerge makes it easy and fast to copy changes over.

EDIT: Sometimes I use GREP to make replacements between versions, like for a no rollback block or a consistently mispelled word, since it's faster/easier. I also use GREP for RPGM games, then find the files I'm looking for in the engine, it's a really great tool.
I understood about WinMerge, the question was just about GREP. I understood about the games with the grind. However, I do not bother with such things myself. Either I miss such titles altogether, or I stupidly hack saves and don't worry.
 
  • Like
Reactions: yoyomistro

yoyomistro

Engaged Member
Jan 15, 2017
2,927
3,930
I understood about WinMerge, the question was just about GREP. I understood about the games with the grind. However, I do not bother with such things myself. Either I miss such titles altogether, or I stupidly hack saves and don't worry.
Oh got it. Regex searches are really powerful, like for finding all instances of a word, and then a bunch of words in between with another word at the end if you need to find a phrase that has minor changes. Or not using regex, just for games where the dev makes a different script file for each scene or something and you're not sure where a label or a line of dialogue is. Saves me a ton of time.

EDIT: Another thing Regex search with GREP is great for is to search for a word or phrase, but only when it's said by a certain character. That's such a huge time saver.
 
Last edited:

HillDweller

Member
Mar 31, 2020
176
363
Nice we have some movement. :)

Lets see:
It would be new to me that after the number 9 the 91 comes. :rolleyes: (0.9-dev -> 0.91) [Yes, that's me being pedantic...]
- IF we have a slight change, then it would be 0.9.1. Means basically just a bugfix.
- In this case however we have the changes for python 64bit windows lib's and a important tool update.
So please go with version 0.10 or better with v0.11, because i used v0.10 already a ~year ago for a short lived unren update(Some RenPy changes did kill it).

More gruesome code stuff in "mod 5 0.91":
  • Nobody noticed i guess: In the line set "version=... the last number (191007) is just the release date of v0.9-dev. -> Invalid here.
  • Ever case of set "renpydir=%... is unneeded in UnRen. The var was and is never used.
  • There are two checks for the "python.exe" now.
  • Same for the other directory check "sets"(base & game dir)
Just saying. Works so far. For now...

Don't know if Sam anything mentioned. We talked winter/spring '20 a few times about a pure python rewrite of UnRen. Problem we got where all the changes in RenPy, the still missing py3 support and the from this resulting insecurity for any development.
I did anyway then in spring go ahead and did most of the rewrite but from Sam nothing anymore since then. A few contact trys in discord got nothing. Guess his interest/focus/free-time is still elsewhere. Who knows.

A version for py 2.7 is basically ready for tests. py 3 version also, but makes little sense to work with because unrpyc supports no py3 for now, so its missing in this version. Oh, there was something:



Anyone who wants to look and test -> attachment. Needs py27 installed and in windows colorama if working console colors are wanted. Report errors please.
Thank for this, it works great!
Though I did have to remove the lines related to this mysterious _ur_vers package (the import and the __version__ assignment). What exactly is it?
 

Madeddy

Active Member
Dec 17, 2017
835
484
Thank for this, it works great!
Though I did have to remove the lines related to this mysterious _ur_vers package (the import and the __version__ assignment). What exactly is it?
Yes. A little bug. Leftover code to import the version number in a different way while i tested, which was replaced later. Fun fact: I could'n notice this because im my dev folder the target of the import '_ur_vers' mechanic existed.
The attached version is a bit newer. Tell if you find something.

Hm... perhaps i need to rename the py version or people get really confused with all the unren variants floating around now. Opinions?
 
Last edited:

coretex

Active Member
Jun 15, 2017
604
517
Did notice that the new .91 does not find rpyc's to decompile that are not directly in the \game folder, and doesnt seem to search subfolders (no funky chars) at all.
The .9-dev one does, as it seems to parse all subfolders as well.

I know the .91 says "in game folder" on purpose, but I would think it would include subfolders of \game as well?
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
Did notice that the new .91 does not find rpyc's to decompile that are not directly in the \game folder, and doesnt seem to search subfolders (no funky chars) at all.
The .9-dev one does, as it seems to parse all subfolders as well.

I know the .91 says "in game folder" on purpose, but I would think it would include subfolders of \game as well?
I wrote about this literally on the last page. The alternative is only my or Madeddy modifications of this program that can be found earlier.
 

coretex

Active Member
Jun 15, 2017
604
517
Ah.. i read through part of the last page, but I saw what I thought was more pathing errors, not just "no rpyc in game folder" which is what the new one says as its "error". I still have the .9-dev file which I used, but if the .91 can be modded, il check that out.
I was looking at the file in notepad++ just.. wasnt sure what path variables to toy with.
Thanks.

--Edit.
found it.. its a simple check to see if there was even any rpyc's just in the root. but i REM'd that out and it works and parses the entire tree. So.. il keep that in mind ;)
 
Last edited:

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,383
Listen, has anyone tried decompiling the latest unrpyc via Python from RenPy? Something here I have on unknown encode cp866 swears, which got out of nowhere. The game is everyone's favorite (for problems with decompiling) SummertimeSaga. :BootyTime:
 
5.00 star(s) 9 Votes