[SOLVED] Animated image acting weirdly when hovered
Posted: Tue Nov 14, 2023 7:13 pm
Hello everybody !
I apologize for this noob question, as I see where the problem is but I have no idea how to fix it, but I have a few animated imagebuttons in my game, some used as unclickable background fluff, some clickable and leading to labels.
Problem is, they all act weird when you hover the mouse on them. Like the animation was resetting ?
![Image](https://s5.gifyu.com/images/SRLQs.gif)
Here's the code used :
I suppose I have to put something on "hover" but I tried some stuff and it doesn't work. So if you have any idea. :/
I apologize for this noob question, as I see where the problem is but I have no idea how to fix it, but I have a few animated imagebuttons in my game, some used as unclickable background fluff, some clickable and leading to labels.
Problem is, they all act weird when you hover the mouse on them. Like the animation was resetting ?
![Image](https://s5.gifyu.com/images/SRLQs.gif)
Here's the code used :
Code: Select all
screen forest_mermen_lair():
imagebutton:
focus_mask True
xpos 200
ypos 80
idle "animated_fishes"
action NullAction()
...
image animated_fishes:
animation
"images/imagebuttons/fishes_1.png"
0.4
"images/imagebuttons/fishes_2.png"
0.4
"images/imagebuttons/fishes_3.png"
0.4
"images/imagebuttons/fishes_4.png"
0.4
repeat