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.
Ravsii
Newbie
Posts: 2 Joined: Thu May 14, 2015 7:54 am
Contact:
#1
Post
by Ravsii » Thu May 14, 2015 7:58 am
I have a simple imagemap and i need to change my variable when user hover on hotspot. Is it possible at all?
This code doesnt work.
Code: Select all
imagemap:
ground transparent
hover transparent
hotspot ((0, 0, 627, 1080)):
hovered (bg = "default")
Alera
Miko-Class Veteran
Posts: 651 Joined: Sun Mar 21, 2010 3:20 am
Completed: Tortichki // Zayay // Hero's Spirit
Deviantart: psyalera
itch: psyalera
Location: UK
Contact:
#2
Post
by Alera » Thu May 14, 2015 8:54 am
The correct way would be to use SetVariable I think.
http://www.renpy.org/doc/html/screen_actions.html
Code: Select all
SetVariable(variable, value)
Causes variable to be set to value.
Something like that:
Code: Select all
hovered SetVariable('bg', "default")
Games:
Zayay [Otome?][BxPlayer][NaNo 2013]
Tortichki [Drag&Drop mini game]
Other games I've worked on:
● M y H e a r t ' s F l a m e ● E m i s s a r y o f S t a r l i g h t ● F r e e d o m F r o m S i l e n c e ● S i c k n e s s
A n d m a n y m o r e u n a n n o u n c e d / s e c r e t p r o j e c t s . ╮ ( . ❛ ᴗ ❛ . ) ╭
Ravsii
Newbie
Posts: 2 Joined: Thu May 14, 2015 7:54 am
Contact:
#3
Post
by Ravsii » Thu May 14, 2015 9:04 am
Oh, thanks a lot.
Users browsing this forum: Google [Bot]