Ren'Py main menu icon

Black Ram oss

Black Ram
Game Developer
May 10, 2018
582
1,564
Hi I'm editing the main menu. but I can do 3 things:
  1. how do i get the patreon icon in the top right with a certain distance between the edges?
  2. how do i add the other icons exactly below the patreon icon inwards to the right?
  3. can you recommend a hover effect?
Annotazione 2020-04-24 120823.png
 

Black Ram oss

Black Ram
Game Developer
May 10, 2018
582
1,564
I solved the part of placing the icons myself, but I would still like to have some advice for the havoc effect (when the mouse is over the icon) and i don't like the fact that i set the icon size
Python:
        vbox:
            anchor (1.0, 1.0)
            pos (0.999, 0.15) # setting both to 1.0 will put the all logos on the very edge
            xsize 430 # X patreon icon
            spacing 5

            imagebutton:
                idle Frame("gui/logos/patreon.png", xfill=True, yfill=True)
                action OpenURL("https://www.patreon.com/")
                ysize 120 # Y patreon icon
                xalign 0.5

            hbox:
                xalign 1.0
                spacing 5

                imagebutton:
                    idle Frame("gui/logos/github.png", xfill=True, yfill=True)
                    action OpenURL("https://github.com/")
                    xsize 80
                    ysize 80
                    xalign 1.0
                imagebutton:
                    idle Frame("gui/logos/discord.png", xfill=True, yfill=True)
                    action OpenURL("https://discord.gg/")
                    xsize 80
                    ysize 80
                    xalign 1.0
 
Last edited:

osanaiko

Engaged Member
Modder
Jul 4, 2017
2,547
4,625
You make another image for HOVER state and add to the imagebutton like this:

Python:
             imagebutton:
                idle Frame("gui/logos/patreon.png", xfill=True, yfill=True)
                hover Frame("gui/logos/patreon_hover.png", xfill=True, yfill=True)
                action OpenURL("https://www.patreon.com/")
                ysize 120 # Y patreon icon
                xalign 0.5
Be careful to make your hover image at least a few pixels larger than the idle image (it can have transparent border if you don't want it to appear to "pop" in size). This is to avoid the rapid flickering between idle and hover view when your mouse is exactly on the border of the button.
 

Black Ram oss

Black Ram
Game Developer
May 10, 2018
582
1,564
thanks but I solved:
 
Last edited: