Tool Ren'Py UnRenGUI, UnRen-forall(v9.4), UnRen-Powershell-forall(v9.4), UnRen-old

5.00 star(s) 3 Votes

"CJ"

Conversation Conqueror
Mar 6, 2021
6,629
70,171
Huh, I didn't know that the script_version.txt file doesn't get replaced, that's probably a bug.

It definitely gets replaced when I rebuild. I just did an Ecchi Sensi week 1 build and that file now says 7.5.0 instead of the original 7.2.0.
It seems that the new versions 7.5.0+ and 8.0.0+ replace the file but the older versions up to 7.4.11 don't, so for the new versions it's safe but for the older versions I'd advise to double check with "renpy/__init__.py" or "game/log.txt" (you have to start the game once for that file to be created/updated).
 

gnadudu

Well-Known Member
Aug 31, 2018
1,895
2,798
Okay, I'll see what's up with the other games. At the expense of the header, I also already thought that the variable name seemed to have been different earlier. I'll add an existence check later. As for other problems, I'll have to download the games first. If it's not difficult, can you throw me the archives with the code so that all the games don't download?
Both <class 'renpy.ast.PostUserStatement'> and <class 'renpy.display.transform.Transform'> where easy fixes. PostUserStatement is some internal thing renpy adds when a UserStatement is used (like renpy.ast.EndTranslate), so a simple pass is enough on the "decomp front" and for transform.Transform I just had to add a displayable_name after importing it...
You can find the changed files attached. Didn't have time to look into the headers, but I guess you handle that yourself? :)
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
Both <class 'renpy.ast.PostUserStatement'> and <class 'renpy.display.transform.Transform'> where easy fixes. PostUserStatement is some internal thing renpy adds when a UserStatement is used (like renpy.ast.EndTranslate), so a simple pass is enough on the "decomp front" and for transform.Transform I just had to add a displayable_name after importing it...
You can find the changed files attached. Didn't have time to look into the headers, but I guess you handle that yourself? :)
I really coped with the transfor easily. But PostUserStatement made me tinker. Interestingly, this module was still in the 4.7.10 engine. I also left this class without decompilation, but I wasn't sure if this was the right solution. Although the game started and worked without problems.
 

gnadudu

Well-Known Member
Aug 31, 2018
1,895
2,798
I really coped with the transfor easily. But PostUserStatement made me tinker. Interestingly, this module was still in the 4.7.10 engine. I also left this class without decompilation, but I wasn't sure if this was the right solution. Although the game started and worked without problems.
Yeah, it's kind of an "end label" which gets automatically added by renpy if a user statement is used. (After recompiling it showed up the same way it did before in the dump...)
 

-CookieMonster666-

Devoted Member
Nov 20, 2018
11,852
17,566
UnRen (at least v8.0.0v2) has trouble with some special characters in the folder path. For instance, I had used the em dash character (Alt + 151) and it wouldn't unpack anything (option 1); it kept saying that there was no such file. However, if I went up the folder chain to one where the name had the em dash, I could change that to a hyphen character instead and get UnRen successfully to unpack the archive. So maybe the path environment variable that you mentioned earlier would be helpful after all.
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
UnRen (at least v8.0.0v2) has trouble with some special characters in the folder path. For instance, I had used the em dash character (Alt + 151) and it wouldn't unpack anything (option 1); it kept saying that there was no such file. However, if I went up the folder chain to one where the name had the em dash, I could change that to a hyphen character instead and get UnRen successfully to unpack the archive. So maybe the path environment variable that you mentioned earlier would be helpful after all.
Which PATH variable are we talking about? We kind of only had problems with decompilation so far. This is the first time I've heard about unpacking and the problem with the PATH variable. And you can show the image of the symbol, I have this code gives a letter of the Russian alphabet.
Just in case, I duplicated information about non-ASCII characters.
 

gnadudu

Well-Known Member
Aug 31, 2018
1,895
2,798
Which PATH variable are we talking about? We kind of only had problems with decompilation so far. This is the first time I've heard about unpacking and the problem with the PATH variable. And you can show the image of the symbol, I have this code gives a letter of the Russian alphabet.
Just in case, I duplicated information about non-ASCII characters.
Should be this character:
The problem is python replaces it with \xf9 (which is of course bad in a windows environment...^^), but I think there's nothing you can do in Unren.bat itself about it. (The problem is that python itself can't set the path, it already happens when you start the python.exe in the lib directory...)
1658840415003.png
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
Should be this character:
The problem is python replaces it with \xf9 (which is of course bad in a windows environment...^^), but I think there's nothing you can do in Unren.bat itself about it. (The problem is that python itself can't set the path, it already happens when you start the python.exe in the lib directory...)
View attachment 1947485
Okay, then I won't even try. I decided to test the latest changes in the decompiler on Obscure Affairs. And I have already faced the problem of unpacking. Another obstacle for me.:BootyTime: Fortunately, unpacking is easier for me than decompilation. If I can figure out this game and everything goes fine, then I will update the tool.
Edit: False alarm:LUL:, even though the loader file is identical, using an unsuitable version of the engine can lead to sad consequences. I just changed the folders "renpy" and "lib" to the ones that were in the game and everything worked.
 
Last edited:

SvenVlad

Well-Known Member
Modder
Aug 11, 2017
1,888
8,988
I got this error when trying to extract the last update of Family Affairs Week 3

Code:
Remove RPA archives after extraction?
    Enter (y/n): n
  + RPA archives won't be deleted

  Searching for RPA packages
   + Unpacking "archive.rpa" - 392008391 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)
 
  Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x00004920 (most recent call first):
<no Python frame>
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
I got this error when trying to extract the last update of Family Affairs Week 3

Code:
Remove RPA archives after extraction?
    Enter (y/n): n
  + RPA archives won't be deleted

  Searching for RPA packages
   + Unpacking "archive.rpa" - 392008391 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)

  Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x00004920 (most recent call first):
<no Python frame>
I received it, I'll download it later and check what's wrong.
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
I got this error when trying to extract the last update of Family Affairs Week 3

Code:
Remove RPA archives after extraction?
    Enter (y/n): n
  + RPA archives won't be deleted

  Searching for RPA packages
   + Unpacking "archive.rpa" - 392008391 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)

  Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x00004920 (most recent call first):
<no Python frame>
Are you trying to unpack in the right version of the tool? UnRen v8.0.0 quietly unpacks the game.
 

SvenVlad

Well-Known Member
Modder
Aug 11, 2017
1,888
8,988
Are you trying to unpack in the right version of the tool? UnRen v8.0.0 quietly unpacks the game.
Yes, the v8.0.0 is the only that gives this error. The others all give this one

Code:
Error: Cannot locate python directory, unable to continue.
            Are you sure we're in the game's root directory?
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
Yes, the v8.0.0 is the only that gives this error. The others all give this one

Code:
Error: Cannot locate python directory, unable to continue.
            Are you sure we're in the game's root directory?
Yes, the v8.0.0 is the only that gives this error. The others all give this one

Code:
Error: Cannot locate python directory, unable to continue.
            Are you sure we're in the game's root directory?
And what version of the game did you download? Regular, separate 32-bit or compressed? Because I just downloaded the Win/Linux version from Mega yesterday and everything unpacked without any problems. If this is not some separate version, then most likely the problem isn system. :unsure:
 

SvenVlad

Well-Known Member
Modder
Aug 11, 2017
1,888
8,988
And what version of the game did you download? Regular, separate 32-bit or compressed? Because I just downloaded the Win/Linux version from Mega yesterday and everything unpacked without any problems. If this is not some separate version, then most likely the problem isn system. :unsure:
I tried with the compressed and 64-bit versions. Both give the same error for me.

Could this be a reason?

Code:
   + Unpacking "archive.rpa" - 693470431 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)
:unsure:
 

gnadudu

Well-Known Member
Aug 31, 2018
1,895
2,798
I tried with the compressed and 64-bit versions. Both give the same error for me.

Could this be a reason?

Code:
   + Unpacking "archive.rpa" - 693470431 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)
:unsure:
Do you have any special characters in your path or is your path maybe too long? (You could try if something like D:\FamilyAffairs works)
You're starting the Unren.bat from inside the FamilyAffairs folder not the game folder?
 

VepsrP

Well-Known Member
Modder
Dec 13, 2017
1,387
1,384
I tried with the compressed and 64-bit versions. Both give the same error for me.

Could this be a reason?

Code:
   + Unpacking "archive.rpa" - 693470431 bytes
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python path configuration:
  PYTHONHOME = (not set)
:unsure:
I just checked on the compressed version. I even unpacked it into a separate folder with all the characters in the folder name saved. Everything unpacked without any problems. There's really something on your side. It is quite possible that the
gnadudu remark about the presence of unorthodox special characters in the full path to the folder with the game is really truthful.
 
  • Like
Reactions: Knight of the Dawn

SvenVlad

Well-Known Member
Modder
Aug 11, 2017
1,888
8,988
I just checked on the compressed version. I even unpacked it into a separate folder with all the characters in the folder name saved. Everything unpacked without any problems. There's really something on your side. It is quite possible that the
gnadudu remark about the presence of unorthodox special characters in the full path to the folder with the game is really truthful.
Could be. There's a ~ in the path to the folder. :unsure:
It's just strange. It's only happening with the v8
 
5.00 star(s) 3 Votes