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.
-
henvu50
- Veteran
- Posts: 322
- Joined: Wed Aug 22, 2018 1:22 am
-
Contact:
#1
Post
by henvu50 » Mon Jun 21, 2021 8:22 pm
I want to set a textbutton to selected = true if it's hovered, is this possible?
something like this:
Code: Select all
textbutton:
selected trueIf(self.hovered)
# OR
hover self.selected = True
Last edited by
henvu50 on Mon Jun 21, 2021 10:06 pm, edited 1 time in total.
-
emz911
- Regular
- Posts: 103
- Joined: Fri Jun 23, 2017 2:23 pm
-
Contact:
#2
Post
by emz911 » Mon Jun 21, 2021 9:34 pm
Code: Select all
hovered SetVariable("self.selected", True)
-
henvu50
- Veteran
- Posts: 322
- Joined: Wed Aug 22, 2018 1:22 am
-
Contact:
#3
Post
by henvu50 » Mon Jun 21, 2021 10:06 pm
emz911 wrote: ↑Mon Jun 21, 2021 9:34 pm
Code: Select all
hovered SetVariable("self.selected", True)
That's so useful, thanks.
Users browsing this forum: No registered users