Customizing buttons

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
isobellesophia
Miko-Class Veteran
Posts: 713
Joined: Mon Jan 07, 2019 2:55 am
Projects: Maddox's Everyday Talk! (13+ Unreal version), Maddox Everyday Talk! (3+ Real-Friendly version)(Upcoming 2020)
Organization: Friendly Teachers series
itch: .......
Location: Philippines, Mindanao
Contact:

Customizing buttons

#1 Post by isobellesophia » Mon Nov 11, 2019 5:25 am

Hello again everyone.

I am working currently on my game GUI's, and i had an idea which is i don't know how to solve it..

So in the main menu, there are obviously buttons for what you wanted to press, what i want is.. there is an image icon next to the main menu button text.
sketch-1573464322967.png
Thanks for who could help.
I am a friendly user, please respect and have a good day..


Working on a talking simulation game for everyone, except children.

Maddox Everyday Talk!
Is my very very main project, not contain 13 below.

Main project here viewtopic.php?f=43&t=56564
Image

User avatar
deltadidirac
Regular
Posts: 115
Joined: Fri Nov 30, 2018 5:00 am
Projects: Slip Over Time
Tumblr: deltadidirac
Deviantart: Deltadidirac67
Location: Europe
Contact:

Re: Customizing buttons

#2 Post by deltadidirac » Mon Nov 11, 2019 6:38 am

isobellesophia wrote:
Mon Nov 11, 2019 5:25 am
Hello again everyone.

I am working currently on my game GUI's, and i had an idea which is i don't know how to solve it..

So in the main menu, there are obviously buttons for what you wanted to press, what i want is.. there is an image icon next to the main menu button text.

sketch-1573464322967.png

Thanks for who could help.
I think that the more simple thing you can do is to open your software editing for image (photoshop or another is the same...)
in the game/gui/button folder you will find the idle-hover "navigation button", open these two last image with your software and re-draw it as you want (in this case you can simply add your heart) and save all exactly with the same name and dimension reslution etc... Done!

after you will check and set correctly all the texts of the buttons to not over-write your "heart"
(these texts you would find or in the gui script, or in the screen script.)

bye

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 2726
Joined: Mon Dec 14, 2015 5:05 am
Location: Your monitor
Contact:

Re: Customizing buttons

#3 Post by Imperf3kt » Mon Nov 11, 2019 6:45 am

If you want to do this with textbuttons, just add the image tag within the button text.

Code: Select all

textbutton _("Some button {image='images/some_image.png'}") action NullAction()
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Twitter

User avatar
isobellesophia
Miko-Class Veteran
Posts: 713
Joined: Mon Jan 07, 2019 2:55 am
Projects: Maddox's Everyday Talk! (13+ Unreal version), Maddox Everyday Talk! (3+ Real-Friendly version)(Upcoming 2020)
Organization: Friendly Teachers series
itch: .......
Location: Philippines, Mindanao
Contact:

Re: Customizing buttons

#4 Post by isobellesophia » Mon Nov 11, 2019 7:22 am

Oops, didnt know that i found this one of the threads, thanks for the help!
I am a friendly user, please respect and have a good day..


Working on a talking simulation game for everyone, except children.

Maddox Everyday Talk!
Is my very very main project, not contain 13 below.

Main project here viewtopic.php?f=43&t=56564
Image

Post Reply

Who is online

Users browsing this forum: Google [Bot]