Not Working Imagemaps in Preferences

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
mapletaffy
Regular
Posts: 96
Joined: Sat Apr 30, 2011 10:54 pm
Contact:

Not Working Imagemaps in Preferences

#1 Post by mapletaffy » Sun Feb 05, 2012 1:43 am

Hello.
I tried using the layout.imagemap_preferences that I found in the renpy wiki. I did not got any error message or anything. The game started okay. The yesno prompt and the main menu are working. However, the preferences screen is not. I can't click any buttons, the slidders are not functioning, even the navigation in the side is unclickable. I really don't know where I went wrong ~(T.T)~

This is the code inside my options.rpy

Code: Select all

init -2 python:
    
    layout.imagemap_preferences("settings_ground.png", "settings_idle.png", "settings_hover.png", "settings_selected_idle.png", "settings_selected_hover.png", [
    (350,83,447,127, "Window"),
    (465,81,554,125, "Fullscreen"),
    
    (355, 188, 86, 32, "Window"),
    (460, 185, 108, 34, "Fullscreen"),
    (359, 219, 83, 29, "All"),
    (464, 218, 85, 31, "None"),
    (360, 277, 125, 29, "Seen Messages"),
    (489, 276, 127, 29, "All Messages"),
    (358, 306, 131, 29, "Stop Skipping"),
    (491, 307, 126, 28, "Keep Skipping"),
            
    (360, 375, 161, 12, "Music Volume"),
    (360, 401, 161, 14, "Sound Volume"),
    (360, 257, 125, 29, "Text Speed"),
    (385, 346, 162, 13, "Auto-Forward Time"),
            ])
            
            
            
    layout.imagemap_navigation(
        "mm_ground.jpg",
        "mm_idle.jpg",
        "mm_hover.jpg",
        "mm_selectedidle.jpg",
        "mm_selectedhover",
        [
    
            (667, 225, 68, 28,  "Return"),
            (667, 263, 100, 29, "Save Game"),
            (667, 303, 101, 29, "Load Game"),
            (667, 343, 80, 31, "Preferences"),
            (669, 383, 96, 29, "Main Menu"),
            (667, 421, 50, 33, "Quit"),
            ])
    

User avatar
Mild Curry
Regular
Posts: 107
Joined: Fri Jul 02, 2010 3:03 pm
Projects: That's The Way The Cookie Crumbles
Organization: TwinTurtle Games
Contact:

Re: Not Working Imagemaps in Preferences

#2 Post by Mild Curry » Mon Feb 06, 2012 11:04 pm

The only thing I can think of is that your hotspot coordinates are off.

If you press Shift+d to open the developer menu, then click on 'Image Location Picker', you can use it to easily find coordinates for imagemaps.

mapletaffy
Regular
Posts: 96
Joined: Sat Apr 30, 2011 10:54 pm
Contact:

Re: Not Working Imagemaps in Preferences

#3 Post by mapletaffy » Thu Feb 09, 2012 9:55 am

Thanks for the reply, Mild Curry~ \(^____^)/
My hotspot coordinates are okay. I just changed the codes because I think the latest version of renpy has new codes regarding to imagemaps (i'm not really sure about this >.<) But it's working now. . . although there are errors still. . .) But it's working now~

Post Reply

Who is online

Users browsing this forum: Bing [Bot], Google [Bot]