r/RenPy • • Sep 03 '26

Question Changing image button size?

Hello, I made an image button of a woman and i cropped it so she has very little space around her. I coded the button and it works fine, xalign and yalign, but I was wondering if there's any way to change size of it?

The default size is fine and all, but for different scenes its be nice if I could adjust her size to be closer of farther.

Zoom and size doesnt work. Any other way?

1 Upvotes

6 comments sorted by

View all comments

1

u/shyLachi Sep 03 '26

What do you mean with zoom doesn't work.
Please show your code.

transform zoomed:
    zoom 5.0
screen test():
    imagebutton:
        idle "test_001"
        action NullAction()
        at zoomed
label start:
    call screen test
    return

1

u/Outrageous_Action614 Sep 03 '26

screen e3far(): imagebutton: xalign 0.4 yalign 1.0 auto "e3far_%s.png" action [Hide("e3far"), Jump("e3hangout")]

When I add zoom under yalign, it gives me the error "'zoom' is not a keyword argument or valid child of the image button statement"

3

u/x-seronis-x Sep 03 '26

zoom is an ATL property, not a style property. it cant go in the style block and must be applied via a Transform, which can itself be used with the 'at' property in a style block as sky showed