Page 1 of 1

[Solved] Regards Changing Background Scene Using Python

Posted: Wed Jul 28, 2021 8:44 am
by andriodmactemporary
We could change the background scene with Renpy by using "scene bg image", but how to attain this functionality using Python?

Thanks in Advance.

Re: Regards Changing Background Scene Using Python

Posted: Wed Jul 28, 2021 9:08 am
by hell_oh_world

Re: Regards Changing Background Scene Using Python

Posted: Thu Jul 29, 2021 9:07 am
by andriodmactemporary
Thanks for the reply, but how can I achieve renpy.show(filename) instead of defining "image bg image"

Re: Regards Changing Background Scene Using Python

Posted: Thu Jul 29, 2021 3:29 pm
by hell_oh_world
i'm pretty sure that you can do that exactly like that, but you need to use absolute path starting from the game/project folder.
i'm might be wrong though.

Re: Regards Changing Background Scene Using Python

Posted: Sun Aug 01, 2021 12:52 pm
by andriodmactemporary
No, it is not working. I have image "Pic.jpg" in game/images folder I have tried renpy.show("game/images/Pic.jpg"), renpy.show("images/Pic.jpg"), and renpy.show("Pic.jpg") with renpy.scene() before this statement, but it is not showing the image it is only showing the path I entered in renpy.show() function.

Re: Regards Changing Background Scene Using Python

Posted: Sun Aug 01, 2021 2:17 pm
by bonnie_641
andriodmactemporary wrote: Sun Aug 01, 2021 12:52 pm No, it is not working. I have image "Pic.jpg" in game/images folder I have tried renpy.show("game/images/Pic.jpg"), renpy.show("images/Pic.jpg"), and renpy.show("Pic.jpg") with renpy.scene() before this statement, but it is not showing the image it is only showing the path I entered in renpy.show() function.

Code: Select all

label start:
    $ renpy.show ("pic")
    "Test 'renpy.show'"
    return

Re: Regards Changing Background Scene Using Python

Posted: Mon Aug 02, 2021 6:02 am
by andriodmactemporary
Thanks it worked