Translation issue
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.
- Donmai
- Eileen-Class Veteran
- Posts: 1919
- Joined: Sun Jun 10, 2012 1:45 am
- Completed: Toire No Hanako, Li'l Red [NaNoRenO 2013], The One in LOVE [NaNoRenO 2014], Running Blade [NaNoRenO 2016], The Other Question, To The Girl With Sunflowers
- Projects: Slumberland
- Location: Brazil
- Contact:
Re: Translation issue
Hmm, maybe it would be useful to remember that strings must be tagged with _() in order to be translated. See also the example in the documentation about translating string substitutions: https://www.renpy.org/doc/html/translat ... stitutions
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
TOIRE NO HANAKO (A Story About Fear)
- Matalla
- Veteran
- Posts: 202
- Joined: Wed Mar 06, 2019 6:22 pm
- Completed: The Lost Smile
- itch: matalla-interactive
- Location: Spain
- Contact:
Re: Translation issue
I have been fighting a little with this. I understand that you're using this, right?
viewtopic.php?f=51&t=22481#p283922
The problem is that, as you said, the text is passed around. After a lot of tries, mixing all the combinations I could imagine, I finally managed to make it work. Some of the modifications that make it work have some logic, like using variables for the translatables strings. Others, like the way of defining the images are just weird.
I'm sure that there are better ways of doing this. If someone has a better method, please post it. I'm really interested in understanding how this freaking thing works.
viewtopic.php?f=51&t=22481#p283922
The problem is that, as you said, the text is passed around. After a lot of tries, mixing all the combinations I could imagine, I finally managed to make it work. Some of the modifications that make it work have some logic, like using variables for the translatables strings. Others, like the way of defining the images are just weird.
Code: Select all
init python:
titlecredits = __("Credits") # must use double underscore
titlewriting = __("Writting")
titleart = __("Art")
credits = ('[titlewriting!t]', 'arty'), ('[titleart!t]', 'arty') # must use !t
credits_s = '{size=40}'+ '[titlecredits!t]' +'\n\n'
c1 = ''
for c in credits:
if not c1==c[0]:
credits_s += "\n{size=30}" + c[0] + "\n"
credits_s += "{size=24}" + c[1] + "\n"
c1=c[0]
Code: Select all
image cred: # must define the image this way, no freaking clue why
Text(credits_s, text_align=0.5)
Who is online
Users browsing this forum: No registered users
