Ren'Py Camera Movements

Insanepenguin91

Member
Game Developer
May 18, 2017
401
3,434
Hello Guys,

Im trying to get the camera effect that shows and image from top to bottom, im rendering images that are 1920x1080 but i want to show an image in the game that is 1920x2160, so the effect that i want is. Move the camera from bottom to top and vice versa in renpy. trying to get the effect ive seen in other games but im having some difficulties getting results. i looked at the tutorial and the renpy website but havent gotten the answer - below is the code im trying to do.

show image (1920x2160) with dissolve
yalign 0.0
linear yalign 1.0
show image ( 1920x1080) with dissolve


any help is greatly appreciated

thanks
 

Porcus Dev

Engaged Member
Game Developer
Oct 12, 2017
2,582
4,681
Try this:
Code:
scene nameofyourimage:
        subpixel True
        yalign 0.0
        pause 1.0
        linear 10.0 yalign 1.0
pause 12.0

You can use "scene" or "show" in the first line, just as you can use effects at the end of the line, for example:
Code:
show nameofyourimage with dissolve:
.......

If instead of top to bottom you want bottom to top, just swap the "yalign" numbers:
(Maybe some image is not framed right where you want... if you need it, use another numbering between 1.0 and 0.0)
Code:
scene nameofyourimage:
        subpixel True
        yalign 1.0
        pause 1.0
        linear 10.0 yalign 0.1
pause 12.0

The "linear" command indicates the time it takes to make the move (the last line with "pause" must have at least the same value, or higher).
You can also force the pause so that the image cannot be skipped until the movement ends:
Code:
scene nameofyourimage:
        subpixel True
        yalign 0.0
        pause 1.0
        linear 10.0 yalign 1.0
$ renpy.pause(12.0, hard=True)

If you need more help don't hesitate to ask ;)
 

Insanepenguin91

Member
Game Developer
May 18, 2017
401
3,434
Try this:
Code:
scene nameofyourimage:
        subpixel True
        yalign 0.0
        pause 1.0
        linear 10.0 yalign 1.0
pause 12.0

You can use "scene" or "show" in the first line, just as you can use effects at the end of the line, for example:
Code:
show nameofyourimage with dissolve:
.......

If instead of top to bottom you want bottom to top, just swap the "yalign" numbers:
(Maybe some image is not framed right where you want... if you need it, use another numbering between 1.0 and 0.0)
Code:
scene nameofyourimage:
        subpixel True
        yalign 1.0
        pause 1.0
        linear 10.0 yalign 0.1
pause 12.0

The "linear" command indicates the time it takes to make the move (the last line with "pause" must have at least the same value, or higher).
You can also force the pause so that the image cannot be skipped until the movement ends:
Code:
scene nameofyourimage:
        subpixel True
        yalign 0.0
        pause 1.0
        linear 10.0 yalign 1.0
$ renpy.pause(12.0, hard=True)

If you need more help don't hesitate to ask ;)

It worked!!! thanks for your help!!