pythongame-developmentrenpy

How do I translate an image / scene with Ren'Py?


I need a certain picture to appear in the game when a certain language is enabled. I assume I'd need to write something like the following to do that:

if game.Language("english"):
    scene warning1b
else:
    scene warning1

How do I write this correctly? and is it possible?


Solution

  • According to the Ren'Py Preference Variables documentation, this can be done in the following manner:

    if preferences.language == "english":
        scene warning1b
    else:
        scene warning1