I am a newcomer to renpy, so my solution may not be the best, but efficient to me.
Actually, I came across the same problem as well long time ago. Then I posted my problem here and got reply from some hero.
viewtopic.php?t=55531
I read his reply and reviewed the documentation of renpy several times, and finally improved the solution.
It seems that renpy engine will refresh some button if something in the same screen is hidden. We both use the "if" statement to hide the imagebutton, which forced the engine to refresh every button in the screen. As the hover image is applied, the image is shown and hidden in a short time, which looks like a blink.
If there is no hover image, there is no blink.
And the blink is displayed in a certain order. (I will not post it here, as it seldom matters the prolem.)
It may not be a bug, but has something to do will the logical issue of the engine.
If I only modify the button itself, not the whole screen, then other imagebuttons will not be refreshed, and there will be no blinks.
So here is the solution.
Code: Select all
screen vedma:
add "Backgrounds/gorod_psiha/vedma/vedma_day.jpg"
add "Backgrounds/gorod_psiha/vedma/vedma_idle.png" xalign 0.08 yalign 0.09
imagebutton:
auto "Backgrounds/gorod_psiha/vedma/vedma_%s.png"
align (0.08,0.09)
action Jump ("start")
imagebutton:
sensitive tikva_1_acquired==False
insensitive Null()
idle "Backgrounds/gorod_psiha/vedma/halloween/tikva_1_idle.png"
hover "Backgrounds/gorod_psiha/vedma/halloween/tikva_1_idle.png" # this line can be deleted, only keep the idle line.
align (0.981,0.47)
action SetVariable("tikva_1", True)
Here, by applying the "sensitive" and "insensitive" statements, we can only modify the sensibility of the button itself without affecting others.
You can try this.