Save/Load screen using imagemap [SOLVED]

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
User avatar
Ormgair
Newbie
Posts: 18
Joined: Sat Dec 27, 2014 9:42 am
Location: Saint-Petersburg,Russia
Contact:

Save/Load screen using imagemap [SOLVED]

#1 Post by Ormgair »

Hi there! I am almost made Save/Load menu with imagemap,but there is one trouble i have. Screenshots in save cells are very-very small (~70x50),but i need 200x150 screenshot. How can i do this?

Code: Select all

screen save:
    tag menu

    imagemap:
                ground "Images/cabin.jpg"
                hover "Images/cabin1.jpg"
                cache False
                hotspot (250,15,300,50)
                hotspot (735, 65, 45, 45) action Return()
                hotspot (750,75,50,140) clicked FilePage(1) 
                hotspot (750,200,50,140) clicked FilePage(2) 
                hotspot (750,325,50,140) clicked FilePage(3) 
                hotspot (750,450,50,140) clicked FilePage(4) 
        
                hotspot (50,75,200,150) clicked FileSave(1):
                    use load_save_slot(number=1)
                hotspot (320,75,200,150) clicked FileSave(2):
                    use load_save_slot(number=2)
                hotspot (50,375,200,150) clicked FileSave(3):
                    use load_save_slot(number=3)
                hotspot (320,375,200,150) clicked FileSave(4):
                    use load_save_slot(number=4)
                hotspot (285,225,200,150) clicked FileSave(5):
                    use load_save_slot(number=5)    
        
screen load:
    tag menu

    imagemap:
                ground "Images/cabin.jpg"
                hover "Images/cabin1.jpg"
                cache False
                hotspot (250,15,300,50)
                hotspot (735, 65, 45, 45) action Return()
                hotspot (750,75,50,140) clicked FilePage(1) 
                hotspot (750,200,50,140) clicked FilePage(2) 
                hotspot (750,325,50,140) clicked FilePage(3) 
                hotspot (750,450,50,140) clicked FilePage(4) 
        
                hotspot (50,75,200,150) clicked FileLoad(1):
                    use load_save_slot(number=1)
                hotspot (320,75,200,150) clicked FileLoad(2):
                    use load_save_slot(number=2)
                hotspot (50,375,200,150) clicked FileLoad(3):
                    use load_save_slot(number=3)
                hotspot (320,375,200,150) clicked FileLoad(4):
                    use load_save_slot(number=4)
                hotspot (285,225,200,150) clicked FileLoad(5):
                    use load_save_slot(number=5) 

screen load_save_slot:
    add FileScreenshot(number)  
    
init -2 python: 
    config.thumbnail_width = 200 
    config.thumbnail_height = 150
Last edited by Ormgair on Fri Jan 02, 2015 3:32 pm, edited 1 time in total.

User avatar
PyTom
Ren'Py Creator
Posts: 16097
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Save/Load screen using imagemap

#2 Post by PyTom »

You should be good. The thumbnail sizes are set on save, not load - so if you load and save again, you'll get correct thumbnails.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

User avatar
Ormgair
Newbie
Posts: 18
Joined: Sat Dec 27, 2014 9:42 am
Location: Saint-Petersburg,Russia
Contact:

Re: Save/Load screen using imagemap

#3 Post by Ormgair »

PyTom wrote:You should be good. The thumbnail sizes are set on save, not load - so if you load and save again, you'll get correct thumbnails.
Thanks a lot! :)

Post Reply

Who is online

Users browsing this forum: No registered users