Panning the scene

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
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.
Post Reply
Message
Author
kampmichi
Newbie
Posts: 6
Joined: Mon Mar 14, 2016 2:57 pm
Contact:

Panning the scene

#1 Post by kampmichi »

I want to make a panning shot of my background right now I am using :

Code: Select all

show Class_Lena turned:
            yalign 0.0
            
            on woop:
                linear 3.0 xalign 0.0 ypos 0 
        with dissolve
        
        show class_day:
            xanchor 0.0 yanchor 0.0
            linear 3.0 xalign 0.5 ypos 0
            event woop
to pan into the middle.

The problem is that I have a character standing in the room that stays on their position of the screen.
And I want to have the character move at the same time the screen does to make it look like the only thing moving is the "camera".

The example above doesn't work for solving the problem since the event doesn't leave the alt block so woop in Class_Lena turned never triggers.

Any ideas how I can make it work so that I can move Lena to the left while moving the classroom bg to the right (at the same time)?

kivik
Miko-Class Veteran
Posts: 786
Joined: Fri Jun 24, 2016 5:58 pm
Contact:

Re: Panning the scene

#2 Post by kivik »

I'm a bit confused by the last bit re: Lena moving to the left when bg moves to the right - I thought you want them to move in the same direction to create the camera move effect?

If you wanted to do a camera pan effect with the background and the character lined up together, the easiest thing is probably to do a composite:

https://www.renpy.org/doc/html/displaya ... .Composite

You'd have to cheat a little to temporary hide the character and swap the background image with the composite, pan the composite, then replace the character and background without transitions.

Hope that's what you're looking for, I may have misunderstood the question!

kampmichi
Newbie
Posts: 6
Joined: Mon Mar 14, 2016 2:57 pm
Contact:

Re: Panning the scene

#3 Post by kampmichi »

Thanks!
A composite does work.

And yeah I want to do a camera move effect.

Post Reply

Who is online

Users browsing this forum: Google [Bot]