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.
I'm just a little stuck and was hoping someone might be able to point me in the right direction.
I'm trying to create a UI which has custom buttons which are highlighted when you mouse over them, i used the following to do this
label convoa:
$ ui.at(tl)
$ ui.imagebutton('chat/tl.png', 'chat/tla.png', clicked= ui.jumps('answera'), image_style='image_button_image')
$ ui.at(tr)
$ ui.imagebutton('chat/tr.png', 'chat/tra.png', clicked= ui.jumps('answerb'), image_style='image_button_image')
show text 'talk about this' at tl
show text 'talk about that' at tr
$ renpy.pause(180.00)
jump convo
the problem is the text i want on the buttons appears behind them instead of on top.
While i would normally just put the desired text on the png itself i want to be able to re-use the UI with different text later.
Any help would be appreciated.
Mmmmmm.... I *think* there's a way.
It would involve using the ui.button (I'm pretty sure there's an object which is a container and makes anything inside it count as part of the whole button)... and then put the image + text inside. You may also need to place the image and text in an absolute way (no hbox or grid).
Well i spent the last couple of days trying to work this out using the ui.button reference page with no luck at all, guess i'll have to just make an image file for each button.
Thanks for the help anyway though.