Translation "broke" game
Hello,
Describe the bug I've found that on some games, translation leads to game breakage. It's not on all games, but some
To Reproduce Steps to reproduce the behavior: 1 - Use One Key Translate (with or without changing the font) 2 - Run the Game & begin the story 3 - Right Click to see the save place - Here maybe the game is "broken" 4 - If not, save and, quit, run the game again, load the game - Here the game is definitively "broken" 5 - Another way to "broke" the game is to save via the quick menu
Version 2.5.7 - RenpyTranslator-Win.Nuitka.Build I don't know why Windows 8 is noted in the log (if it's for the game developer or for me), so I'll specify here that I don't use it, I'm on Windows 11.
This is the log I had when the game is "broken"
[code] I'm sorry, but an uncaught exception occurred.
While running game code: File "game/screens.rpy", line 604, in execute screen save(): File "game/screens.rpy", line 604, in execute screen save(): File "game/screens.rpy", line 608, in execute use file_slots(("Save")) File "game/screens.rpy", line 618, in execute screen file_slots(title): File "game/screens.rpy", line 618, in execute screen file_slots(title): File "game/screens.rpy", line 622, in execute use game_menu(title): File "game/screens.rpy", line 434, in execute screen game_menu(title, scroll=None, yinitial=0.0): File "game/screens.rpy", line 434, in execute screen game_menu(title, scroll=None, yinitial=0.0): File "game/screens.rpy", line 443, in execute frame: File "game/screens.rpy", line 446, in execute hbox: File "game/screens.rpy", line 452, in execute frame: File "game/screens.rpy", line 455, in execute if scroll == "viewport": File "game/screens.rpy", line 486, in execute transclude File "game/screens.rpy", line 622, in execute use game_menu(title): File "game/screens.rpy", line 624, in execute fixed: File "game/screens.rpy", line 643, in execute grid gui.file_slot_cols gui.file_slot_rows: File "game/screens.rpy", line 651, in execute for i in range(gui.file_slot_cols * gui.file_slot_rows): File "game/screens.rpy", line 655, in execute button: File "game/screens.rpy", line 658, in execute has vbox File "game/screens.rpy", line 662, in execute text FileTime(slot, format=("{#file_time}%A, %B %d %Y, %H:%M"), empty=_("empty slot")): File "renpy/common/00action_file.rpy", line 259, in FileTime return _strftime(format, time.localtime(mtime)) File "renpy/common/00action_file.rpy", line 95, in _strftime rv = time.strftime(rv.encode("utf-8"), t).decode("utf-8") ValueError: Invalid format string
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "renpy/common/layout/screen_load_save.rpym", line 35, in script
$ ui.interact()
File "C:\HG\FootOfTheMountains-V12-pc\FootOfTheMountains-V12-pc\renpy\ast.py", line 896, in execute
renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
File "C:\HG\FootOfTheMountains-V12-pc\FootOfTheMountains-V12-pc\renpy\python.py", line 1929, in py_exec_bytecode
exec bytecode in globals, locals
File "renpy/common/layout/screen_load_save.rpym", line 35, in
Windows-8-6.2.9200 Ren'Py 7.2.1.457 Foot Of The Mountains V12 Tue Feb 11 14:16:07 2025 [/code]
Edit; My mistake, I mixed up Part 2 with Part 1. But even with part 1 I don't get this error.
I used the following options in Renpy Translator : ( Tested with both Gameversions ( Part 1 & Part 2 ) )
- Unpack Game package
- Runtime Extraction
- Official Extraction
- Add Changer Language Entrance
- set default Language at statup
- Translate
- Error Repair
Try changing line 662 in screens.rpy. This is probably the problem. The character string in the file format may be incorrect.
Search for the line text FileTime(slot, format=("{#file_time}%A, %B %d %Y, %H:%M"), empty=_("empty slot")):
and change to >
text FileTime(slot, format=_("{#file_time}%A, %B %d %Y, %H:%M"), empty=_("empty slot")):
Then create a new translation . I hope it works for you.
I did several tests
1 - Change translation target language - Same behavior
2 - Just change line 662 - Same behavior
3 - Start from scratch, translate exactly as you said (one key translate without extraction, without change font), change line 662, re-translate - Same behavior for the game, but I get a long renpy-translator error log when I don't use extraction
Log Format UnicodeEncodeError! Log ClearedException in thread Thread-58: Traceback (most recent call last): File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connection.py", line 199, in _new_conn File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 85, in create_connection File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 73, in create_connection Exception in thread Thread-56: Traceback (most recent call last): File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connection.py", line 199, in _new_conn TimeoutError: [WinError 10060] Une tentative de connexion a échoué car le parti connecté n’a pas répondu convenablement au-delà d’une certaine durée ou une connexion établie a échoué car l’hôte de connexion n’a pas répondu
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connectionpool.py", line 789, in urlopen Exception in thread Thread-57: Traceback (most recent call last): File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connection.py", line 199, in _new_conn File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 85, in create_connection File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connectionpool.py", line 466, in _make_request File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 85, in create_connection File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 73, in create_connection File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connectionpool.py", line 1095, in _validate_conn File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\util\connection.py", line 73, in create_connection TimeoutError: [WinError 10060] Une tentative de connexion a échoué car le parti connecté n’a pas répondu convenablement au-delà d’une certaine durée ou une connexion établie a échoué car l’hôte de connexion n’a pas répondu
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connectionpool.py", line 789, in urlopen File "C:\HG-\RENPYT~1.BUI\MAIN~1.DIS\urllib3\connection.py", line 693, in connect TimeoutError: [WinError 10060] Une tentative de connexion a échoué car le parti connecté n’a pas répondu convenablement au-delà d’une certaine durée ou une connexion établie a échoué car l’hôte de connexion n’a pas répondu
// more in the attach file //
Looks like network problems. TimeoutError: [WinError 10060]: This is the most prominent and repeated error. It's a Windows-specific error code indicating that a connection attempt failed because the connected party (in this case, translate.google.com) didn't respond within a certain time limit. This can be caused by several things: Google Translate Server Issues, Internet Connectivity Issues, Heavy network traffic etc.
I understand, now, i don't why i have this this connection error without extraction and don't have the error with. And the result is, finaly the same, the game is translated but when I load a save, it's broken
I tried several things, Without "skip extract the contents witch include underline" it didn't change anything
Where it gets interesting is when I try to change translation services. Basically, I use Google(Free) I've tried YouDao and ModernMT, and I get a different result.
The game no longer has any problems, but even if I don't get any errors in either case (and the service can be reached), the game remains in its original language.