Quick/Auto saves page's labels ignore translation files
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Quick/Auto saves page's labels ignore translation files
Hello, I have a bit of a problem with translating labels for auto and quick saves pages. Translation files work everywhere else (characters, menu options, save dates, etc), except for these two labels.
I found the strings under tl/screens.rpy and double-checked their updated values. I also tried to change the original names, generate new translation strings for them - didn't help at all. I see the fresh translation strings, fix them with the new language and still have English text in labels.
Is it a bug or am I doing something wrong?
Ren'Py version 6.99.12.4.2187 - updated to the last version after encountering this strange behavior. Tried to generate fresh translation strings after installing, but it didn't help.
I found the strings under tl/screens.rpy and double-checked their updated values. I also tried to change the original names, generate new translation strings for them - didn't help at all. I see the fresh translation strings, fix them with the new language and still have English text in labels.
Is it a bug or am I doing something wrong?
Ren'Py version 6.99.12.4.2187 - updated to the last version after encountering this strange behavior. Tried to generate fresh translation strings after installing, but it didn't help.
Re: Quick/Auto saves page's labels ignore translation files
Double checked everything, still can’t find a solution for this. So, I just leave all the relevant info here in hopes, that someone will help me.
One more time, Ren’Py ignores part of the translation config. Apart from two labels (quick and auto save screens) everything else works fine. Characters, menu buttons, dates, options, etc. I think the problem is based on this line of code from screens.rpy (I’m about zero level in coding, so pardon me, if this is not the case):
All three values are marked for translation and they could be found inside game/tl/language/screens.rpy. After translating all of them, I started the project to see how the new text looks. Pages label counter for regular saves was correctly translated and showed the new value. Quick and auto saves (accessed by clicking Q and A in the load/save menu) still held their original values.
I checked the screens.rpy inside the tl folder and found the untranslated bits inside:
Tried different combinations of translations for these strings: shorter versions, longer versions, 1 word, 2 words, numbers. In all of these cases, the config was ignored and the game displayed default English values. I tried changing up the default name of the label inside the original screens.rpy (accessed directly from the Ren’Py launcher) and generating strings for it, like this:
The default label changed to a new value (from Automatic saves to Auto saves), but the translation is not displayed after switching the language. I use the standard language buttons from Lemma how-to’s:
Aside from this snippet, I changed the color of in-game choice’s menu. Doubt it has any effect on the translation. All other changes were strictly for the script.rpy – the dialogues and so on.
Any thoughts? I’ve hit a brick wall and I can’t figure out a workaround :<
One more time, Ren’Py ignores part of the translation config. Apart from two labels (quick and auto save screens) everything else works fine. Characters, menu buttons, dates, options, etc. I think the problem is based on this line of code from screens.rpy (I’m about zero level in coding, so pardon me, if this is not the case):
Code: Select all
screen file_slots(title):
default page_name_value = FilePageNameInputValue(pattern=_("Page {}"), auto=_("Automatic saves"), quick=_("Quick saves"))
I checked the screens.rpy inside the tl folder and found the untranslated bits inside:
Code: Select all
# screens.rpy:597
old "Automatic saves"
new "X"
# screens.rpy:597
old "Quick saves"
new "Y"
Code: Select all
# screens.rpy:597
old "Auto saves"
new "X"
Code: Select all
label _("Language")
hbox:
textbutton "English" action Language(None)
textbutton "Test" action Language("test")
Any thoughts? I’ve hit a brick wall and I can’t figure out a workaround :<
- Ocelot
- Eileen-Class Veteran
- Posts: 1883
- Joined: Tue Aug 23, 2016 10:35 am
- Github: MiiNiPaa
- Discord: MiiNiPaa#4384
- Contact:
Re: Quick/Auto saves page's labels ignore translation files
Please, show translate statements before those lines. It should be something like translate strings
< < insert Rick Cook quote here > >
Re: Quick/Auto saves page's labels ignore translation files
Here's the full segment with my last try to translate. If you require full screens.rpy from the second language - I'll send it via attachment. Don't mind the "russian" instead of test, I switched the second language during the translation progress, and it's listed as russian both in Ren'Py config and translation folder.Ocelot wrote:Please, show translate statements before those lines. It should be something like translate strings
Code: Select all
# TODO: Translation updated at 2017-03-15 13:50
translate russian strings:
# screens.rpy:597
old "Auto saves"
new "Авто сохранения"
- IrinaLazareva
- Veteran
- Posts: 399
- Joined: Wed Jun 08, 2016 1:49 pm
- Projects: Legacy
- Organization: SunShI
- Location: St.Petersburg, Russia
- Contact:
Re: Quick/Auto saves page's labels ignore translation files
I am not sure that it is...correct solution. But it seems works.
Code: Select all
translate russian python:
config.translations['Automatic saves'] = u'Автоматические сохранения'
config.translations['Quick saves'] = u'Быстрые сохранения'
translate None python:
config.translations['Automatic saves'] = 'Automatic saves'
config.translations['Quick saves'] = 'Quick saves'Re: Quick/Auto saves page's labels ignore translation files
Thank you very much! I don't really care about the "correct" coding as long as it works for me :>IrinaLazareva wrote:I am not sure that it is...correct solution. But it seems works.
Code: Select all
translate russian python: config.translations['Automatic saves'] = u'Автоматические сохранения' config.translations['Quick saves'] = u'Быстрые сохранения' translate None python: config.translations['Automatic saves'] = 'Automatic saves' config.translations['Quick saves'] = 'Quick saves'
Who is online
Users browsing this forum: Bing [Bot], Google [Bot], span4ev