Buttons for RPG styled VN

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
Neeka
Veteran
Posts: 359
Joined: Fri Jun 03, 2016 6:06 pm
Completed: Hearts & Hexes; Winter Flower
Projects: Hearts and Hexes; Our Mountain; The Last Clan: Tale of Oni
Organization: Ostrich Burger Productions
IRC Nick: Neeka
itch: neeka-of-obp
Contact:

Buttons for RPG styled VN

#1 Post by Neeka » Mon Aug 29, 2016 5:13 pm

Hello I was wondering if there was a way to have a clickable button. EX: After a fight, clickable items will drop. If you click the coin, money will increase, the heart, hp, and so on. I have seen this done on cloudnovel and flash games but was wondering if it was possible in Ren'Py. Thanks!

kivik
Miko-Class Veteran
Posts: 786
Joined: Fri Jun 24, 2016 5:58 pm
Contact:

Re: Buttons for RPG styled VN

#2 Post by kivik » Mon Aug 29, 2016 6:13 pm

Do you want a button to appear in the graphics layer or do you want to have a window pop up with things that can be picked up?

If you want something like coins to drop, you need to look at Imagebutton: https://www.renpy.org/doc/html/screens.html#imagebutton

I'm not sure if you can animate it though if you wanted to do coin drop animations - but you can always do an animation on an image first, and once the animation stops, display the Imagebutton.


If you just want a window to pop up with the option to collect the coins, you can either do it via a menu or a screen with textbutton: https://www.renpy.org/doc/html/screens.html#textbutton

If you give clearer examples, it'll be easier to pin point which method and how to do it :)

User avatar
Neeka
Veteran
Posts: 359
Joined: Fri Jun 03, 2016 6:06 pm
Completed: Hearts & Hexes; Winter Flower
Projects: Hearts and Hexes; Our Mountain; The Last Clan: Tale of Oni
Organization: Ostrich Burger Productions
IRC Nick: Neeka
itch: neeka-of-obp
Contact:

Re: Buttons for RPG styled VN

#3 Post by Neeka » Mon Aug 29, 2016 6:18 pm

It looks like the Imagebuttons will work. I do have a Starburst effect that I could layer over dropped items. I also wanted to include the option to use potions on you/other member of your party or buy/sell items and I think creating a menu will help. Thanks a lot, I really appreciate it. I'll study the links you provided. :)

Post Reply

Who is online

Users browsing this forum: Bing [Bot], Ocelot, Sergei Falcon