Ren'Py Click image to make image full screen

elcapizo

Member
Game Developer
Jun 7, 2017
106
194
Hello, how do i make like if i click on the image that is on the phone i get the fullsize of the image.
I did something like that
Auditoriumcellsms1.png

screen sisbig():
imagemap:
ground "auditorium/Auditoriumcellsms1.png"
hover "auditorium/Auditoriumcellsms1.png"
hotspot(1032, 360, 231, 163) clicked Jump ("bigsis")

if i call i cant proceed without click on it, and if i show no other image appear.
Im sorry my bad english
 

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Donor
Respected User
Jun 10, 2017
10,957
16,190
screen sisbig():
imagemap:
ground "auditorium/Auditoriumcellsms1.png"
hover "auditorium/Auditoriumcellsms1.png"
hotspot(1032, 360, 231, 163) clicked Jump ("bigsis")
Alright, firstly I recommend you to find another sources for Ren'py snippets, because this one is very old ; the clicked property was replaced by action almost ten years ago. As for , it was depreciated when the imagebutton screen statement appeared, a long time ago here again.

Now, for the problem itself, there's many way to do it, among them, this one :
Code:
screen whatever():
    imagemap:
        ground "auditorium/Auditoriumcellsms1.png"
        hover "auditorium/Auditoriumcellsms1.png"
        hotspot(1032, 360, 231, 163):
            # Show the displaying screen, passing it the image to display
            action Show( "zoomPicture", "images/phone pictures/this picture.jpg" )

[...]
screen zoomPicture( target ):

    # Prevent click outside of the defined buttons.
    modal True

    # Display a button...
    imagebutton:
        # that will show the asked image...
        idle target   
        # centered...
        xalign 0.5
        yalign 0.5
        # and will hide the screen when clicked.
        action Hide( "zoomPicture" )